HI. I would like to have the output of the entered variables repeat forever, but it's stopping at the last entered variable. Help would be great!
<html>
<head>
<script type="text/javascript">
var t;
var c=0;
var iCount=0;
var W=new Array();
var C=new Array();
<?php
$total=29; //The total number of records -1
echo 'W[0]="'.$W1.'";';
echo 'C[0]="'.$C1.'";';
echo 'W[1]="'.$W2.'";';
echo 'C[1]="'.$C2.'";';
echo 'W[2]="'.$W3.'";';
echo 'C[2]="'.$C3.'";';
echo 'W[3]="'.$W4.'";';
echo 'C[3]="'.$C4.'";';
echo 'W[4]="'.$W5.'";';
echo 'C[4]="'.$C5.'";';
echo 'W[5]="'.$W6.'";';
echo 'C[5]="'.$C6.'";';
echo 'W[6]="'.$W7.'";';
echo 'C[6]="'.$C7.'";';
echo 'W[7]="'.$W8.'";';
echo 'C[7]="'.$C8.'";';
echo 'W[8]="'.$W9.'";';
echo 'C[8]="'.$C9.'";';
echo 'W[9]="'.$W10.'";';
echo 'C[9]="'.$C10.'";';
echo 'W[10]="'.$W11.'";';
echo 'C[10]="'.$C11.'";';
echo 'W[11]="'.$W12.'";';
echo 'C[11]="'.$C12.'";';
echo 'W[12]="'.$W13.'";';
echo 'C[12]="'.$C13.'";';
echo 'W[13]="'.$W14.'";';
echo 'C[13]="'.$C14.'";';
echo 'W[14]="'.$W15.'";';
echo 'C[14]="'.$C15.'";';
echo 'W[15]="'.$W16.'";';
echo 'C[15]="'.$C16.'";';
echo 'W[16]="'.$W17.'";';
echo 'C[16]="'.$C17.'";';
echo 'W[17]="'.$W18.'";';
echo 'C[17]="'.$C18.'";';
echo 'W[18]="'.$W19.'";';
echo 'C[18]="'.$C19.'";';
echo 'W[19]="'.$W20.'";';
echo 'C[19]="'.$C20.'";';
echo 'W[20]="'.$W21.'";';
echo 'C[20]="'.$C21.'";';
echo 'W[21]="'.$W22.'";';
echo 'C[21]="'.$C22.'";';
echo 'W[22]="'.$W23.'";';
echo 'C[22]="'.$C23.'";';
echo 'W[23]="'.$W24.'";';
echo 'C[23]="'.$C24.'";';
echo 'W[24]="'.$W25.'";';
echo 'C[24]="'.$C25.'";';
echo 'W[25]="'.$W26.'";';
echo 'C[25]="'.$C26.'";';
echo 'W[26]="'.$W27.'";';
echo 'C[26]="'.$C27.'";';
echo 'W[27]="'.$W28.'";';
echo 'C[27]="'.$C28.'";';
echo 'W[28]="'.$W29.'";';
echo 'C[28]="'.$C29.'";';
echo 'W[29]="'.$W30.'";';
echo 'C[29]="'.$C30.'";';
echo 'var iTotal='.$total.';';
?>
function newTimer()
{
if (iCount==0)
{
document.getElementById("WPlaceHolder").innerHTML=W[c];
iCount++;
t=setTimeout("newTimer()",1000);
}
else if(iCount==1)
{
document.getElementById("CPlaceHolder").innerHTML=C[c];
iCount++;
t=setTimeout("newTimer()",1000);
}
else if(c!=iTotal)
{
document.getElementById("WPlaceHolder").innerHTML="";
document.getElementById("CPlaceHolder").innerHTML="";
iCount=0;
c++;
t=setTimeout("newTimer()",1000);
}
}
</script>
</head>
<body onLoad="newTimer()">
<center>
<B> <font size=32> <span id="WPlaceHolder"> </span></font> <font color="green" size=32><span id="CPlaceHolder"></span></font></b>
</center>
<br />
</body>
</html>
Java API in PHP?
I have an application that we use internally here at the office.The software company provides a Java API.Is there a way to use this Java API with PHP?or am i stuck having to use tomcat and jsp to
GET vs SUBMIT Button to show sections on one index.php page?
Just curious if one of these ways is better (i.e. more efficient) than the other. I have an index.php page where there is a menu across the top with 5 choices. For example, HOME | MONKEYS | CATS |
C++ Http request?
Code:
problems with php variables in mysql query
i can't seem to get the following query to work. select $q1c from $vote_rate where id = $recent_record LIMIT 0,1 ;this method did not work eitherselect .$q1c. from .$vote_rare. where id =
Linking with Foreign Keys
I have been getting an erro when I try and link:
problem with array - multilingual page
this is my test page :Code: <?php if(isset($_GET['lang'])) { if($_GET['lang'] == "en") { require_once("languages/lang-en.php"); }
fwrite error
Hi All,Does anyone know what is causing the error in this code?Code: <?$errorLog_FilePath = "error_log.txt";$handle = @fopen($errorLog_FilePath,'a+');$strError =
Form validation with functions
Hi thereI am trying to make a very simple form validation function. I currently have the followingfunction formValidate($field, $msg) { if (empty($_POST['$field'])) { $errors[] = $msg; } else
Display certain image depending on time of year
Hi, I am new to these forums and would really appreciate some advice on a piece of coding I have done.Basically what I am trying to do is on our intranet, display a different home page banner
include function being weird?
I have a very simple system to grab an IP outputted by a PHP file.. (for a project I have) but it outputs a 1 at the end!!<form method="post" action="<?php echo