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

Replaced old way of specifying http method by the new one #4131

Closed
wants to merge 2 commits into from

Conversation

Baptouuuu
Copy link
Contributor

Q A
Doc fix? yes
New docs? no
Applies to 2.5+
Fixed tickets

@Baptouuuu
Copy link
Contributor Author

Oops, the target branch should be 2.5 not master.

@Baptouuuu Baptouuuu changed the title [WCM] replaced old way of specifying http method by the new one Replaced old way of specifying http method by the new one Aug 16, 2014
@@ -53,7 +53,7 @@ system, as explained below:
<route id="remove_trailing_slash" path="/{url}">
<default key="_controller">AcmeDemoBundle:Redirecting:removeTrailingSlash</default>
<requirement key="url">.*/$</requirement>
<requirement key="_method">GET</requirement>
<method>GET</method>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is no method element. In XML, you have to use the methods attribute instead.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So it would look like: <route methods="GET">...</route>? I was not sure about the xml version.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Indeed, you can see an example as a reference here.

@xabbuh
Copy link
Member

xabbuh commented Aug 16, 2014

And actually, this was introduced in Symfony 2.2. So, it should be merged into the 2.3 branch.

@weaverryan
Copy link
Member

Great fix - thanks Baptiste!

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

Successfully merging this pull request may close these issues.

4 participants