I have this code for when I click a <a id="c01_i001">link</a>
to check if the page exists and open it:
[code]<?php
$page = $_GET[‘page’];
$pages = array(‘c01_i001’, ‘c01_i002’,
‘c01_i001en’, ‘c01_i002en’
…more pages…
);
if (!empty($page)) {
if(in_array($page,$pages)) {
$page .= '.php';
require_once('../' . $page . '');
}
else require_once('../p_error_msg_loop_a.php');
}
else require_once('../p_error_msg_loop_a.php');
?>[/code]
It is working fine as long as my page is inside my main directory. What I am trying to do now is to open a page that is in another folder inside my main directory so I change this line:
require_once('../' . $page . '');
to this:
require_once('../folder/' . $page . '');
BUT I got a blank page with out any errors (checking with firebug as well).
Do I miss anything there?