Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Form::open_secure is missing #1714

Closed
thestepafter opened this issue Jun 21, 2013 · 6 comments
Closed

Form::open_secure is missing #1714

thestepafter opened this issue Jun 21, 2013 · 6 comments

Comments

@thestepafter
Copy link

L3 has the Form::open_secure functionality so that when you are posting to a form while on https the URL that is generated from Form::open_secure is also https. In L4 there is no open_secure (or openSecure) so when you are on https all forms are posting to http instead of https. I tried putting 'secure' => true in the array but it only creates an attribute in the opening form tag.

@jrahmy
Copy link

jrahmy commented Jun 21, 2013

Why wouldn't you just pass the action as a secure URL?

@thestepafter
Copy link
Author

This is what I have now:

Form::open(array('action' => 'Controller@method'))

How would I pass the action as a secure URL?

@jrahmy
Copy link

jrahmy commented Jun 22, 2013

http://laravel.com/docs/helpers#urls

Most of the helpers have a third parameter to make them secure URLs, or a separate helper entirely. I would just ask for that functionality for the action helper instead.

@taylorotwell
Copy link
Member

When you declare your route to the controller, make it have the https attribute.

@radum
Copy link

radum commented Jan 16, 2015

I know it is closed and old but if I have

Route::controller('users', 'UsersController');

How would I make it have the https attr?

@ctf0
Copy link

ctf0 commented Feb 6, 2015

i was searchin for the same today and here is what i found
@radum

Route::controller('users', [
'https' => true
'uses' => 'UsersController'
]);

or

Route::group(['https'], function()
{
    Route::controller('users', 'UsersController');
});

check http://laravel.io/forum/12-26-2014-routing-with-https & #578 for more info.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants