Hi, I'm just starting up with PHP and am trying to figure out why the below code works on my friend's computer and doesn't work on mine.
I've set up a new Web site on IIS on Windows 2000 Server and I'm running PHP4.3.3.
When I run the code below I receive this error:
"Notice: Undefined variable: p in C:\temp\my web site\index.php on line 10
Notice: Undefined index: in C:\temp\my web site\index.php on line 10"
Any ideas what is going wrong here?
Thanks,
May
----------------------
<html>
<head>
<title>My Web Site</title>
</head>
<?
$pages['1'] = '01_1_home.php';
if (!$pages[$p]) {$p = array_shift(array_keys($pages));}
?>
<frameset rows="*" cols="134,*" frameborder="NO" border="0" framespacing="0">
<frame src="nav_1.php?s=1&p=<?=$p?>" name="leftFrame" scrolling="NO" noresize>
<frameset rows="206,*" cols="*" framespacing="0" frameborder="NO" border="0">
<frame src="top_01.php" name="topFrame" scrolling="NO" noresize>
<frame src="<?=$pages[$p]?>" name="mainFrame">
</frameset>
</frameset>
</html>
I've set up a new Web site on IIS on Windows 2000 Server and I'm running PHP4.3.3.
When I run the code below I receive this error:
"Notice: Undefined variable: p in C:\temp\my web site\index.php on line 10
Notice: Undefined index: in C:\temp\my web site\index.php on line 10"
Any ideas what is going wrong here?
Thanks,
May
----------------------
<html>
<head>
<title>My Web Site</title>
</head>
<?
$pages['1'] = '01_1_home.php';
if (!$pages[$p]) {$p = array_shift(array_keys($pages));}
?>
<frameset rows="*" cols="134,*" frameborder="NO" border="0" framespacing="0">
<frame src="nav_1.php?s=1&p=<?=$p?>" name="leftFrame" scrolling="NO" noresize>
<frameset rows="206,*" cols="*" framespacing="0" frameborder="NO" border="0">
<frame src="top_01.php" name="topFrame" scrolling="NO" noresize>
<frame src="<?=$pages[$p]?>" name="mainFrame">
</frameset>
</frameset>
</html>