"); */ // $ind should be 2 for full domains, 3 for subdirectories, etc. $ind = 2; // set the collection if available $part_collection = $url_array[$ind]; if (empty($part_collection) || $part_collection == $page) { include('lang.en.inc'); include_once($page); exit(); } else { if ($part_collection != 'all') { $collection = $part_collection; } } $ind++; // set the language if available if (isset($url_array[$ind])) { $part_language = $url_array[$ind]; if (empty($part_language) || $part_language == $page) { include_once($page); exit(); } else { if ($part_language != 'all' && !is_numeric($part_language)) { $language = $part_language; if (file_exists("lang.$language.inc")) { include("lang.$language.inc"); } else { include("lang.en.inc"); } } else { include('lang.en.inc'); } } } else { include_once($page); exit(); } $ind++; // set the function if available if (isset($url_array[$ind])) { $part_function = $url_array[$ind]; if (empty($part_function) || $part_function == $page) { include_once($page); exit(); } else { $function = $part_function; } } else { include_once($page); exit(); } $ind++; // set the id if available if (isset($url_array[$ind])) { $part_id = $url_array[$ind]; if (empty($part_id) || $part_id == $page) { include_once($page); exit(); } else { if (is_numeric($part_id)) { $id = $part_id; include_once($page); } else { echo ('Invalid ID specification ('.$url_array[$ind].'). Return home.'); exit(); } } } else { include_once($page); exit(); } ?>