Skip to content

Reworded the article about slashes in routing placeholders #8020

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

Merged
merged 2 commits into from
Jun 18, 2017

Conversation

javiereguiluz
Copy link
Member

I don't like the original article because the example is not realistic (names can't contain /).

I also propose to add a note at the end ... but maybe it's unnecessary because all this is too obvious?


.. configuration-block::

.. code-block:: php-annotations

use Sensio\Bundle\FrameworkExtraBundle\Configuration\Route;

class DemoController
class DefaultController
Copy link
Member

Choose a reason for hiding this comment

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

maybe use something like TokenController then

Copy link
Member Author

Choose a reason for hiding this comment

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

Not sure about that. Imagine that this action is for sharing files/folders in Dropbox or sharing photo albums in Google ... and you need the token (hash) of the thing you are sharing. We probably wouldn't call that controller TokenController, but ShareController, FileController, PhotoAlbumController, etc. In these cases, I prefer to keep the neutral DefaultController name to not overcomplicate the examples ... but I'd love to read more opinions about this. Thanks!

@xabbuh xabbuh added this to the 2.7 milestone Jun 18, 2017
@xabbuh
Copy link
Member

xabbuh commented Jun 18, 2017

Thank you Javier.

@xabbuh xabbuh merged commit 71aceb2 into symfony:2.7 Jun 18, 2017
xabbuh added a commit that referenced this pull request Jun 18, 2017
…s (javiereguiluz, weaverryan)

This PR was merged into the 2.7 branch.

Discussion
----------

Reworded the article about slashes in routing placeholders

I don't like the original article because the example is not realistic (names can't contain `/`).

I also propose to add a note at the end ... but maybe it's unnecessary because all this is too obvious?

Commits
-------

71aceb2 minor tweak
ec9816b Reworded the article about slashes in routing placeholders
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