Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Improving "The Quick Tour" tutorial#3562

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Closed
javiereguiluz wants to merge31 commits intosymfony:masterfromjaviereguiluz:revamped_quick_tour
Closed

Improving "The Quick Tour" tutorial#3562

javiereguiluz wants to merge31 commits intosymfony:masterfromjaviereguiluz:revamped_quick_tour

Conversation

javiereguiluz
Copy link
Member

QA
Doc fix?no
New docs?yes
Applies to2.4+
Fixed tickets

This pull request tries to improve the currentQuick Tour tutorial. Instead of updating its contents, this is a complete revamp of the original tutorial:

  • Some sections have been drastically simplified (e.g. the installation section)
  • A few sections have been completely removed (e.g. the security section)
  • Most of the notes and tips about advanced features have been removed

Before adding comments and corrections for this proposal, please keep in mind that this tutorial is forthe absolute Symfony beginner and that it should provide just a brief tour of the most important Symfony features.

added a section about displaying error pages
@wouterj
Copy link
Member

You should resize the images to make them width 600px, otherwise there are rendering issues on symfony.com and in the pdf

And you are missing the PR format in your PR description :)

web/
app.php
...
$ composer create-project symfony/framework-standard-edition myproject/ ~2.4
Copy link
Member

Choose a reason for hiding this comment

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

I prefer to remove the trailing slash.

Copy link
MemberAuthor

Choose a reason for hiding this comment

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

My reasoning for this:myproject can be a file name, a dir name, a configuration option name, etc. Butmyproject/ is easily understood as a dir path.

Copy link
Member

Choose a reason for hiding this comment

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

In the paragraph before this code, you already say "the following command to install the latest version of Symfony2 in themyproject/ directory" (I would also vote to remove it there). As there is only one occurence of "myproject" in the command, it's already very clear that it's the directory name

Copy link
Member

Choose a reason for hiding this comment

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

I would keep it ,:-)

Copy link
Member

Choose a reason for hiding this comment

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

I like using the slash too in this way :)

controller if a variable is type hinted with
`Symfony\Component\HttpFoundation\Request`::
Symfony automatically injects the ``Request`` object when the controller defines
a variable type hinted with `Symfony\Component\HttpFoundation\Request`::
Copy link
Member

Choose a reason for hiding this comment

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

I think this sounds a little friendlier:

... ``Request`` object when the controller has an argument that's type hinted with ...

@weaverryan
Copy link
Member

@javiereguiluz I just added a few more comments (I hadn't read through everything yet) - but it's fantastic! Definitely a great facelift! After those few small changes, I'll merge this in :).

Thanks!

@javiereguiluz
Copy link
MemberAuthor

@weaverryan and@wouterj thank you very much for your reviews!

The controller first bootstraps the application using a kernel class (``AppKernel``
in this case). Then, it creates the ``Request`` object using the PHP's global
variables and passes it to the kernel. The last step is to send back to the user
the response contents returned by the kernel.
Copy link
Member

Choose a reason for hiding this comment

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

I feel thatThe last step is to send the response contents returned by the kernel back to the user.

@javiereguiluz
Copy link
MemberAuthor

@xabbuh thanks for your fixes!

@@ -119,14 +112,14 @@ a single ``Bundle`` class that describes it::

In addition to the AcmeDemoBundle that was already talked about, notice
that the kernel also enables other bundles such as the FrameworkBundle,
DoctrineBundle, SwiftmailerBundle, and AsseticBundle bundle.
They are all part of the core framework.
DoctrineBundle, SwiftmailerBundle, and AsseticBundle bundle. They are all part
Copy link
Member

Choose a reason for hiding this comment

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

The comma after SwiftmailerBundle should be removed.

@@ -268,7 +261,7 @@ Extending Bundles

If you follow these conventions, then you can use :doc:`bundle inheritance</cookbook/bundles/inheritance>`
to "override" files, controllers or templates. For example, you can create
a bundle -``AcmeNewBundle`` - and specify that it overrides AcmeDemoBundle.
a bundle - AcmeNewBundle - and specify that it overrides AcmeDemoBundle.
Copy link
Member

Choose a reason for hiding this comment

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

Maybe we shouldn't say that a bundles overrides another bundle but instead extends a parent bundle?

Copy link
Member

Choose a reason for hiding this comment

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

No, we have explicitely changed this from parent to override (one of my first doc contributions) as there is no parent/child relation, the getParent method is confusing and only there as it means a big BC change.

More information insymfony/symfony#4347 and the related doc PR and fabian's commit

Copy link
Member

Choose a reason for hiding this comment

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

Ah, thanks for the clarification.

@weaverryan
Copy link
Member

This is definitely ready to go - but we need to merge it into the 2.3 branch (especially since it's a LTS release) - I've rebased and opened up#3613 for that. I don't think we need any tweaks - I'll just leave it up briefly before merging for a sanity check.

Closing this in favor of that PR.

Thanks!

weaverryan added a commit that referenced this pull requestFeb 27, 2014
This PR was merged into the 2.3 branch.Discussion----------Javiereguiluz revamped quick tourHey guys!See#3562 - this is the same, but rebased against the 2.3 branch.| Q             | A| ------------- | ---| Doc fix?      | no| New docs?     | yes| Applies to    | 2.3+| Fixed tickets |Off of the top of my head (but I could be wrong), the only thing that was 2.4 specific is the version number used in the composer.phar create-project command. We could fix this in 2 different ways:1) Don't fix it - just always keep that number updated to the latest released version. We do this similarly in other places2) Use "@stable" as the version constraint. I don't know of any drawbacks.Thanks!Commits-------1e36cfa [quick_tour] rewording and grammar fixes noted by@xabbuh69fdff1 [quick_tour] removed an unneeded comma30624eb [quick_tour] more rewording and grammar fixes0f13ce9 [quick_tour] rewording and grammar fixes suggested by@weaverryan7c0037e Restored all the original introductions for each tutorial partcb98a6c Restored the original line that explained how a routing file is imported from a bundlefdc755e Grammar fixes proposed by@weaverryan and@wouterjeca1e73 Added a more useful message for users that don't have PHP 5.4 and try to execute the server:run commanda013b11 Removed the animated GIF showing how to install Symfony985c68f Replaced "variable" by "placeholder" when using {_format} inside a route42bd69f Fixed the capitalization of a section heading75be815 Minor rewordingc1ad15d Added a new headline to better structure the documentationb16c3a2 Capitalized some sentences that come after a colon2fdcffd When using server:run command, it's not necessary to add the `app_dev.php` controller6afc80b Removed a wrongly inserted commae004661 Bundle names should not be placed in literals38b1292 [quick_tour] removed inline links81d6e20 [quick_tour] replaced "chapter" by "part" in some tutorial parts50e136c [quick_tour] second pass to "the architecture" chaptercdb7064 [quick_tour] second pass to "the controller" chapter and added a section about displaying error pages2cd3bab [quick tour] second pass to "the view" chapter4ad3c44 [quick_tour] second pass to the "big picture" chaptere7dfc8b [quick_tour] simplified "the architecture" chaptereb3fe4c [quick tour] simplified "the controller" chapterdbbc8c2 [quick_tour] updated "the view" chapter5b3a572 [quick_tour] finished the review of "The Big Picture" chapterf24eabc [quick_tour] updated some screenshots20e9fb0 [quick_tour] updated the "Controllers" section29992cd [quick_tour] simplified the "routing" sectiona84a556 [quick_tour] simplified drastically the first two sections of "The Big Picture" chapter
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers
No reviews
Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

5 participants
@javiereguiluz@wouterj@weaverryan@lyrixx@xabbuh

[8]ページ先頭

©2009-2025 Movatter.jp