Well bust mah britches and call me cheeky, on Thu, 21 Feb 2008 22:32:30
GMT Tym scribed:
That's perfect! gizza clue? ;-) please!
....Here's the source for the frameset page, fr_0.php:
<?
if ($_POST['impic']) {
$chpic = "?pic=" . $_POST['impic'];
} else {
$chpic = "?pic=dblon";
}
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN"
"
http://www.w3.org/TR/html4/frameset.dtd">
<html>
<head>
<title>Frameset Example</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="author" content="Neredbojias">
<link rel="icon" href="../nerbo.ico" type="image/x-icon">
</head>
<frameset cols="50%,50%">
<frame src="fr_1.php<? echo $chpic; ?>" name="fr1">
<frame src="fr_2.php<? echo $chpic; ?>" name="fr2">
</frameset>
</html>
....Here's what you might call the "nav" page, fr_1:
<?
$ch1="";$ch2="";$ch3="";$ch4="";
if ($_GET['pic'] === "dbald") {
$ch4 = " checked";
} elseif ($_GET['pic'] === "dredh") {
$ch3 = " checked";
} elseif ($_GET['pic'] === "dbrun") {
$ch2 = " checked";
} else {
$ch1 = " checked";
}
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"
http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<title>Pic-A-Pic</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="author" content="Neredbojias">
<style type="text/css">
body {
margin:4px 12px 12px;
padding:0;
background:#7c6870;color:#e8d8d4;
font-family:sans-serif;
}
h3 {
margin-top:0px;
}
#ct1 {
line-height:1.4;
font-size:110%;
}
form {
margin:0;
}
input {
margin-left:0;
}
..cu {
margin:.5em 0;
padding:0;
font-family:Helvetica,Arial,sans-serif;
font-size:83%;
font-weight:bold;
}
</style>
</head>
<body>
<h3>Pic-A-Pic</h3>
<div id="ct1">
<br>
Choose your Image:
<br>
<form method="post" action="fr_0.php" target="_top">
<div>
<br>
<input type="radio" name="impic" value="dblon"<? echo $ch1; ?>> Blond<br>
<input type="radio" name="impic" value="dbrun"<? echo $ch2; ?>> Brunette
<br>
<input type="radio" name="impic" value="dredh"<? echo $ch3; ?>> Redhead
<br>
<input type="radio" name="impic" value="dbald"<? echo $ch4; ?>> Bald<br>
<br>
<input type="reset" value="Clear" class="cu">
<input name="smit" type="submit" value="Submit" class="cu">
</div>
</form>
</div>
<script type="text/javascript">
</script>
</body>
</html>
....And here's the pic page, fr_2:
<?
if ($_GET['pic'] === "dbald" || $_GET['pic'] === "dredh" || $_GET['pic']
=== "dbrun") {
$pic = $_GET['pic'] . ".jpg";
} else {
$pic = "dblon.jpg";
}
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
"
http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="author" content="Neredbojias">
<title>Pic-A-Pic Image</title>
<style type="text/css">
html,body {
height:100%;
overflow:auto;
}
body {
margin:0;
padding:0;
text-align:center;
background:#7c6870;color:#e8d8d4;
line-height:0px;
font-size:0px;
}
table {
margin:auto;
height:100%;
border:0;
}
</style>
</head>
<body>
<table cellspacing="0" cellpadding="0"><tr><td align="center"><img
src="<? echo $pic; ?>" alt=""></td></tr></table>
</body>
</html>
Happy coding!