PoKeSaFaRi
Former PokemonSafari Webmaster
- 370
- Posts
- 21
- Years
- Age 39
- Spain
- Seen Jan 4, 2017
Hello. I'm experiencing an error on my webpage. The url is www.poke-safari.com
When clicking any of the links, the content that it should load on the content area won't load, but instead it loads the same news area as in the main page.
I've checked for quite a long time if the problem was the php code i was using, and ended up finding that's not the problem. I've been using the same php code for doing this for a while and I never experienced this problem before.
I'm posting the code, just in case it can be helpfull to solve the problem:
/********************* Content Starts Here ************************/
if(strstr($ps, "..") || $ps[0]=="/") $ps = "";
if(empty($ps)) $ps = "news.htm";
else { $ps = $ps. ".htm"; }
if(is_file("$ps")){ include("$ps");
} else echo "<b>Se ha producido un error</b><br> Comunicaselo al webmaster cuanto antes para que lo pueda arreglar. Gracias";
/******************** Content Ends Here *************************/
I've tried it on my computer's home server to make sure it's not me. So maybe it's an error due to a wrong PHP instalation or an error of some kind.
When clicking any of the links, the content that it should load on the content area won't load, but instead it loads the same news area as in the main page.
I've checked for quite a long time if the problem was the php code i was using, and ended up finding that's not the problem. I've been using the same php code for doing this for a while and I never experienced this problem before.
I'm posting the code, just in case it can be helpfull to solve the problem:
/********************* Content Starts Here ************************/
if(strstr($ps, "..") || $ps[0]=="/") $ps = "";
if(empty($ps)) $ps = "news.htm";
else { $ps = $ps. ".htm"; }
if(is_file("$ps")){ include("$ps");
} else echo "<b>Se ha producido un error</b><br> Comunicaselo al webmaster cuanto antes para que lo pueda arreglar. Gracias";
/******************** Content Ends Here *************************/
I've tried it on my computer's home server to make sure it's not me. So maybe it's an error due to a wrong PHP instalation or an error of some kind.