I have a really strange problem and I don't know why it's doing it
When my pgae gets to the div with the scroller inside the rest of the
html is not executed. I can't see why it's doing it as all the divs are closed.
The rest of the code will work if i take out the scroller
There is nothing wrong with the
css
- HTML: Select all
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://wwww.w3.org/TR/html4/strict.dtd">
<html>
<head>
<title>Projects-SW</title>
<meta hhtp-equiv="Content-Type" content="text/html;
charset=iso8859-1">
<link href="includes/projects.css" rel="stylesheet" type="text/css">
<script type="text/javascript" src="includes/menu.js"></script>
<script type="text/javascript" src="includes/marquee.js"></script>
</head>
<body>
<div id="wrapper">
<div id="title"><img src="images/projects.jpg " alt="Projects (SW) Limited"></div>
<div id="info"></div>
<div id="pic"><?php $number=rand(1,4); ?>
<img src="images/work<?php echo $number;?>.jpg">
</div>
<div id="scroller">
<div id="marqueecontainer" onMouseover="copyspeed=pausespeed" onMouseout="copyspeed=marqueespeed">
<div id="vmarquee" style="position: absolute; width: 98%;">
<?
include 'includes/connection.php';
$q = mysql_query("SELECT * FROM content WHERE title='News'");
if(!$q) die(mysql_error());
$err = mysql_num_rows($q);
if($err == 0) die("No current news to display.");
while($code = mysql_fetch_array($q)) {
echo "<h4>Current News</h4><p>".$code['comments']."</p><br>\n";
}
?>
</div>
</div>
</div>
<div id="nav">r6tutyuty</div>
<div id="main">tyututyuy</div>
<div id="content"></div>
<div id="time"></div>
<div id="copyright"></div>
<div id="image"></div>
</body>
</html>
The only code that you will need is the scroller
css
- Code: Select all
#marqueecontainer{
position: relative;
width: 200px; /*marquee width */
height: 120px; /*marquee height */
background-color: white;
overflow: hidden;
padding: 2px;
padding-left: 4px;
}