Comprenant
Je salue!
Comment mettre en œuvre les importations de code à partir d'une autre page.
Par exemple:
il existe:
Faut:
Comment mettre en œuvre les importations de code à partir d'une autre page.
Par exemple:
il existe:
[== PHP ==]
<?php include(dirname(__FILE__).'/header.php'); ?>
Faut:
[== PHP ==]
<?php include(dirname(__FILE__).'http://site.fr/themes/standard/header.php'); ?>
Connectez-vous ou Inscrivez-vous pour répondre.
Réponses
You can't include a remote file in this way.
More php code is required. Try this by copying the following code Please consider that calling file_get_contents is only possible if allow_url_fopen is set on by your host in php.ini.
It's not the only available solution, but let's start with it
Cheers
Consultant PluXml
Ancien responsable et développeur de PluXml (2010 à 2018)
Inclus. La réponse est:
Warning: file_get_contents(http://pluxml.mapc2012.ru/version/russian/themes/standard/header.php): failed to open stream: HTTP request failed! HTTP/1.1 500 Internal Server Error in F:\OpenServer\domains\shop\themes\shop\blog.php on line 3
Could not read the file.
Maybe not a valid url, or insuffisant access rights.
link tested: http://pluxml.mapc2012.ru/version/russian/themes/standard/header.php
ps: please also consider files coming from PluXml's theme are protected with this following line (1st line) to prevent file inclusion from another site.
Consultant PluXml
Ancien responsable et développeur de PluXml (2010 à 2018)