Jump to content

FMR

Members
  • Posts

    7
  • Joined

  • Last visited

FMR's Achievements

Newbie

Newbie (1/7)

0

Reputation

  1. When I open the file in php without BOM with direct path it works but when I try to open the page which needs the products.xml (or .php) I get the "can't load products" error.
  2. When I change the extension I also change all references to productsXMLFile : "data-provider/products.xml", for productsPHPFile : "data-provider/products.php", and url: configOptions.productsXMLFile+"?file="+DateTime.getTime(), dataType: "xml", for url: configOptions.productsPHPFile+"?file="+DateTime.getTime(), dataType: "php", inside of the .js But I get an error message saying: Can't load products. That's why I suspected I couldn't change the extension. There is something I'm missing.
  3. I remove the BOM and the error is gone. But it still doesn't work. I guess I must keep the .xml extension. But the server just doesn't recognize the php inside it. Any idea on how to force it? Thank you for the help!
  4. In fact, I don't know if this is related but when I try to load the file 1 on itself I get this error: Warning: Cannot modify header information - headers already sent by (output started at /home/steph941/public_html/miseau-point/code/etudiantfr/data-provider/products.php:1) in /home/steph941/public_html/miseau-point/code/etudiantfr/data-provider/products.php on line 2 I checked for white spaces and there is none.
  5. The file just won't load. I tried to change the extension but it didn't work either.
  6. Hello everyone, I'm trying to include this PHP code inside of a .xml: <?php $parent = basename(dirname($_SERVER['PHP_SELF'])); echo $parent; ?> The code doesn't seem to be recognized at all. I tried to create a .htaccess file and dropped it in the same folder as the .xml: AddHandler x-httpd-php .xml AddHandler php-script .php .xml AddHandler php5-script .php .xml AddType application/x-httpd-php .xml AddType application/x-httpd-php .xml I was trying the parse .xml as .php. I changed the header of the xml for: <?php header("Content-Type: text/xml;charset=utf-8"); ?> and still no luck. I attached the xml file with this post. I must say. I'm out of ideas for something I am sure is possible. If someone has any ideas at all it would be really appreciated. Thank you in advance! FMR products.xml
  7. Hello everyone, I'm trying to include this PHP code inside of a .xml: <?php $parent = basename(dirname($_SERVER['PHP_SELF'])); echo $parent; ?> The code doesn't seem to be recognized at all. I tried to create a .htaccess file and dropped it in the same folder as the .xml: AddHandler x-httpd-php .xml AddHandler php-script .php .xml AddHandler php5-script .php .xml AddType application/x-httpd-php .xml AddType application/x-httpd-php .xml I was trying the parse .xml as .php. I changed the header of the xml for: <?php header("Content-Type: text/xml;charset=utf-8"); ?> and still no luck. I attached the xml file with this post. I must say. I'm out of ideas for something I am sure is possible. If someone has any ideas at all it would be really appreciated. Thank you in advance! FMR products.xml
×
×
  • Create New...