Hi,
I am assembling navigation links for an online article. The code works
fine for WIN IE 6 users, but not for NN4, or Mac IE5 users. When it
works, the resulting link looks like this:
http://www.mydomain.com/pr3/article2.php
On the machines with trouble, we get this:
/pr3/\\\\www.mydomain.com\\pr3\\article2.php
(Sorry for the dummy URL - I can't share the page yet)
As you can see, the link is now relative, and the slashes are working
out poorly. Is there a rule or technique I am missing that could make
this calculation work for the older browsers?
Thanks,
Matt
The relevant code is:
$page_num=1;
$page_location='http:\\\www.mydomain.com\\pr3\\';
$prev_page=$page_num-1;
$next_page=$page_num+1;
if ($prev_page == 0) {
$prev_page_link=NULL;
$prev_page_label=NULL;
}
else {
$prev_page_link = $page_location .'article'. $prev_page . '.php';
$prev_page_label = '< ' . $prev_page;
}
if ($next_page > $num_pages) {
$next_page_link=NULL;
$next_page_label=NULL;
}
else {
$next_page_link = $page_location .'article'. $next_page . '.php';
$next_page_label =$next_page . ' >';
echo ('<td width="380px" align="right"><h3> Article
Navigation:</h3></td>');
echo ("<td align=\"left\"><h3><a
href=\"$prev_page_link\">$prev_page_label</a> $nbsp $page_num $nbsp <a
href =\"$next_page_link\">$next_page_label</a></h3></td></tr>");