|
113.
|
|
|
You can run PHP scripts at a terminal prompt. To run PHP scripts at a terminal prompt you should install the <application>php-cli</application> package. To install <application>php-cli</application> you can enter the following command at a terminal prompt: <screen>
<command>sudo apt install php-cli</command>
</screen>
|
|
|
represents a line break.
Start a new line in the equivalent position in the translation.
|
|
|
|
(no translation yet)
|
|
|
|
Located in
serverguide/C/web-servers.xml:724(para)
|
|
114.
|
|
|
You can also execute PHP scripts without installing the Apache PHP module. To accomplish this, you should install the <application>php-cgi</application> package. You can run the following command at a terminal prompt to install the <application>php-cgi</application> package: <screen>
<command>sudo apt install php-cgi</command>
</screen>
|
|
|
represents a line break.
Start a new line in the equivalent position in the translation.
|
|
|
|
(no translation yet)
|
|
|
|
Located in
serverguide/C/web-servers.xml:733(para)
|
|
115.
|
|
|
To use <application>MySQL</application> with PHP you should install the <application>php-mysql</application> package. To install <application>php-mysql</application> you can enter the following command at a terminal prompt: <screen>
<command>sudo apt install php-mysql</command>
</screen>
|
|
|
represents a line break.
Start a new line in the equivalent position in the translation.
|
|
|
|
(no translation yet)
|
|
|
|
Located in
serverguide/C/web-servers.xml:743(para)
|
|
116.
|
|
|
Similarly, to use <application>PostgreSQL</application> with PHP you should install the <application>php-pgsql</application> package. To install <application>php-pgsql</application> you can enter the following command at a terminal prompt: <screen>
<command>sudo apt install php-pgsql</command>
</screen>
|
|
|
represents a line break.
Start a new line in the equivalent position in the translation.
|
|
|
|
De la même manière, pour utiliser <application>PostgreSQL</application> avec PHP, vous devez installer le paquet <application>php-pgsql</application>. Pour ce faire, vous pouvez saisir la commande suivante à l'invite d'un terminal [nbsp] : <screen>
<command>sudo apt install php-pgsql</command>
</screen>
|
|
Translated and reviewed by
Nicolas Delvaux
|
|
|
|
Located in
serverguide/C/web-servers.xml:751(para)
|
|
117.
|
|
|
If you have installed the <application>libapache2-mod-php</application> or <application>php-cgi</application> packages, you can run PHP scripts from your web browser. If you have installed the <application>php-cli</application> package, you can run PHP scripts at a terminal prompt.
|
|
|
|
Si vous avez installé les paquets <application>libapache2-mod-php</application> ou <application>php-cgi</application>, vous pouvez lancer des scripts PHP depuis votre navigateur internet. Si vous avez installé le paquet <application>php-cli</application>, vous pouvez lancer des scripts PHP à l'invite d'un terminal.
|
|
Translated by
Pascal Maugendre
|
|
Reviewed by
Nicolas Delvaux
|
|
|
|
Located in
serverguide/C/web-servers.xml:764(para)
|
|
118.
|
|
|
By default, when <application>libapache2-mod-php</application> is installed, the Apache 2 Web server is configured to run PHP scripts. In other words, the PHP module is enabled in the Apache Web server when you install the module. Please verify if the files <filename>/etc/apache2/mods-enabled/php7.0.conf</filename> and <filename>/etc/apache2/mods-enabled/php7.0.load</filename> exist. If they do not exist, you can enable the module using the <command>a2enmod</command> command.
|
|
|
|
(no translation yet)
|
|
|
|
Located in
serverguide/C/web-servers.xml:773(para)
|
|
119.
|
|
|
Once you have installed the PHP related packages and enabled the Apache PHP module, you should restart the Apache2 Web server to run PHP scripts. You can run the following command at a terminal prompt to restart your web server: <screen><command>sudo systemctl restart apache2.service</command> </screen>
|
|
|
|
Une fois les paquets concernant PHP installés et le module Apache PHP activé, vous devez redémarrer le serveur web Apache2 pour lancer des scripts PHP. Vous pouvez saisir la commande suivante à l'invite d'un terminal pour redémarrer votre serveur web [nbsp] : <screen>
<command>sudo systemctl restart apache2.service</command>
</screen>
|
|
Translated by
Pascal Baudry
|
|
Reviewed by
Jean-Marc
|
|
|
|
Located in
serverguide/C/web-servers.xml:785(para)
|
|
120.
|
|
|
Testing
|
|
|
|
Tests
|
|
Translated by
Emmanuel Sunyer
|
|
|
|
Located in
serverguide/C/web-servers.xml:793(title) serverguide/C/network-auth.xml:1063(title) serverguide/C/mail.xml:359(title) serverguide/C/mail.xml:1669(title) serverguide/C/dns.xml:380(title) serverguide/C/clustering.xml:182(title)
|
|
121.
|
|
|
To verify your installation, you can run the following PHP phpinfo script:
|
|
|
|
Pour vérifier votre installation, vous pouvez lancer le script PHP phpinfo suivant[nbsp] :
|
|
Translated by
Pascal Maugendre
|
|
Reviewed by
Jean-Marc
|
|
|
|
Located in
serverguide/C/web-servers.xml:794(para)
|
|
122.
|
|
|
<?php
phpinfo();
?>
|
|
|
represents a line break.
Start a new line in the equivalent position in the translation.
|
|
|
represents a space character.
Enter a space in the equivalent position in the translation.
|
|
|
|
<?php
phpinfo();
?>
|
|
Translated by
Emmanuel Sunyer
|
|
|
|
Located in
serverguide/C/web-servers.xml:797(programlisting)
|