Skip to content

Commit 473e072

Browse files
committed
replaced PHP built-in server with the Symfony CLI one
1 parent 0255293 commit 473e072

File tree

3 files changed

+13
-12
lines changed

3 files changed

+13
-12
lines changed

Diff for: configuration/micro_kernel_trait.rst

+6-4
Original file line numberDiff line numberDiff line change
@@ -74,11 +74,12 @@ Next, create an ``index.php`` file that creates a kernel class and executes it::
7474
$response->send();
7575
$kernel->terminate($request, $response);
7676

77-
That's it! To test it, you can start the built-in web server:
77+
That's it! To test it, start the :doc:`Symfony Local Web Server
78+
</setup/symfony_server>`:
7879

7980
.. code-block:: terminal
8081
81-
$ php -S localhost:8000
82+
$ symfony server:start
8283
8384
Then see the JSON response in your browser:
8485

@@ -335,12 +336,13 @@ this:
335336
├─ composer.json
336337
└─ composer.lock
337338
338-
As before you can use PHP built-in server:
339+
As before you can use the :doc:`Symfony Local Web Server
340+
</setup/symfony_server>`:
339341

340342
.. code-block:: terminal
341343
342344
cd web/
343-
$ php -S localhost:8000
345+
$ symfony server:start
344346
345347
Then see webpage in browser:
346348

Diff for: create_framework/front_controller.rst

+3-3
Original file line numberDiff line numberDiff line change
@@ -153,12 +153,12 @@ web root directory:
153153
Now, configure your web server root directory to point to ``web/`` and all
154154
other files won't be accessible from the client anymore.
155155

156-
To test your changes in a browser (``http://localhost:4321/hello?name=Fabien``), run
157-
the PHP built-in server:
156+
To test your changes in a browser (``http://localhost:4321/hello?name=Fabien``),
157+
run the :doc:`Symfony Local Web Server </setup/symfony_server>`:
158158

159159
.. code-block:: terminal
160160
161-
$ php -S 127.0.0.1:4321 -t web/ web/front.php
161+
$ symfony server:start --port=4321 --passthru=front.php
162162
163163
.. note::
164164

Diff for: create_framework/introduction.rst

+4-5
Original file line numberDiff line numberDiff line change
@@ -101,14 +101,13 @@ start with the simplest web application we can think of in PHP::
101101

102102
printf('Hello %s', $name);
103103

104-
You can use the PHP built-in server to test this great application in a browser
105-
(``http://localhost:4321/index.php?name=Fabien``):
104+
You can use the :doc:`Symfony Local Web Server </setup/symfony_server>` to test
105+
this great application in a browser
106+
(``http://localhost:8000/index.php?name=Fabien``):
106107

107108
.. code-block:: terminal
108109
109-
$ php -S 127.0.0.1:4321
110-
111-
Otherwise, you can always use your own server (Apache, Nginx, etc.).
110+
$ symfony server:start
112111
113112
In the :doc:`next chapter </create_framework/http_foundation>`, we are going to
114113
introduce the HttpFoundation Component and see what it brings us.

0 commit comments

Comments
 (0)