Jump to content

[SOLVED] New to PHP can you help please


neilcg1

Recommended Posts

Hi I am new to PHP and trying to teach myself. I currently have a web site with a checkbox the code for this is:

<td width="37" align="center"><input name="checkbox" type="checkbox" id="checkbox" value="checkbox" <?php if ($row[8]) echo "checked"; ?>>

 

I am trying to replace the checkbox with a flashing arrow code thus:

 

<td width="37" align="center"> <img border="0" <?php if

 

($row[8])  echo "src=\"arrow8.gif"\" ?> width="30"

 

height="30">";

 

<?php if ($row[8]) echo "checked"; ?>

 <td width="53">

<div align="center">

<?php echo $row[10]?>

    </form>

 

I get syntax error stating "," expected, which I can fix but the I get T LNUMBER error which is throwing me.

 

ANy help greatly appreciated.

 

Many Thanks

Link to comment
Share on other sites

Learn to use ' single quotes and " double quotes

 

u use " double quotes all over, yet still continue with the string.

 

' single quotes dun do $string processing within the quoted string

 

" double quotes process $string variables within the string and also provide character substitution.

 

it dusn look like u are processing any variables or special characters in yer echo's

so replace the " double quotes to ' single quotes to mark the begin and end of yer string

Link to comment
Share on other sites

Sorry Guys not getting anywhere, probably because I dont really know what I am doing.

 

Perhaps if I explain a bit more fully.

 

I have a web site: www.autobetpro.com/testtwo.php which has a checkbox which is unticked until the feed to the web site ticks the box. The code for this site is:

<html>

<head>

<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

<title>TML Nano Runners</title>

<style type="text/css">

</style>

<link href="../NHX/CSS/Level1_Verdana.css" rel="stylesheet" type="text/css">

<link href="../NHX/CSS/scb.css" rel="stylesheet" type="text/css">

<style type="text/css">

<!--

.style28 {font-size: xx-small}

-->

</style>

</head>

 

<body>

<?php

$sql_connect = @mysql_connect("******", "****", "****")

// $sql_connect = @mysql_connect("*****", "*****", "******")

or

die('Could not connect: ' . mysql_error());

mysql_select_db("tml");

 

$qry = "select distinct r2.name, r.selectionId, m.marketId, v.name, DATE_FORMAT(m.start_time_gmt + INTERVAL 0 SECOND, '%H:%i'), r.ID, r.lay10, r.lay1, r.layed, r.percentage, r2.finishing_position from tml.runners r join capture.markets m on (m.marketId = r.marketId) join venues.venues v on (v.id = m.venue) join capture.runners r2 on (r2.selectionid = r.selectionid AND r.marketid = r2.marketid) where to_days(m.start_time_gmt) = to_days(utc_date)  - if(HOUR(UTC_TIMESTAMP) < 13, 1, 0)  order by m.start_time_gmt";

//if(HOUR(UTC_TIMESTAMP) < 14, 1, 0)  order by m.start_time_gmt";

 

//echo $qry;

$rs = mysql_query($qry, $sql_connect);

$heading = "TML Runners";

?>

<div align="center"><span class="Heading"><?php echo $heading?></span></div>

<hr>

 

<table width="500"  height="20" border=1 align="center" cellpadding=1 cellspacing=0 bordercolor="#777777" bordercolordark="#ffffff" bgcolor="#FFFFCC" class="data_tbl">

<tr>

    <th width="41" bgcolor="#C0C0C0"><div align="center"><span class="style5">Start</span></div></th>

    <th width="102" bgcolor="#C0C0C0"><span class="style5">Venue</span></th>

    <th width="111" bgcolor="#C0C0C0"><span class="style5">Runner</span></th>

    <th width="56" bgcolor="#C0C0C0"><span class="style5">10 Min</span></th>

    <th width="70" bgcolor="#C0C0C0"><span class="style5">1 Min</span></th>

    <th width="53" bgcolor="#C0C0C0"><span class="style5">%age</span></th>

    <th width="37" bgcolor="#C0C0C0"><span class="style5">Lay</span></th>

    <th width="37" bgcolor="#C0C0C0"><span class="style5">Finished</span></th>

  </tr>

    <col width="10">

  <?php

$cnt = 1;

while($row = mysql_fetch_array($rs)) {

?>

  <tr class="small_tbl">

    <form action="" method="post" name="form1">

    </form>

    <td width="41"><?php echo $row[4]?>

     

     <td width="102"><?php echo $row[3]?>

       <td width="111"><div align="center"><?php echo $row[0]?>

    <td width="56"><div align="center"><?php echo $row[6]?>

    </div>

    <td width="70"><div align="center"><?php echo $row[7]?>

        </div>

      <label for="checkbox"></label>

            <div align="center">

              <input type="hidden" name="ID" value="<?php echo $row[5]; ?>" />

              <input type="hidden" name="marketId" value="<?php echo $row[2]; ?>" />

              <input type="hidden" name="selectionId" value="<?php echo $row[1]; ?>" />

        </div>

      <td width="53"><div align="center"><?php echo $row[9]?>

    <td width="37" align="center"><input name="checkbox" type="checkbox" id="checkbox" value="checkbox" <?php if ($row[8]) echo "checked"; ?>>

      <td width="53"><div align="center"><?php echo $row[10]?>

    </form>   

  </tr>

      <?php

  $cnt += 1;

 

}

 

mysql_free_result($rs);

mysql_close($sql_connect);

 

?>

</table>

<hr>

<center>

  <span class="footer">Copyright© NHX Thailand. All rights reserved</span>

</center>

 

</body>

</html>

 

I want to replace the checkbox with a green flashing arrow and I have tried to do this with the following script below, but as you can see from the following url, the arrow appears where every checkbox is. I am trying to get it just to appear where the ticked checkboxes are in the first url above.

 

www.autobetpro.com/livebets.php

<html>

<head>

<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

<title>AUTOBETPRO LIVE BETS</title>

<style type="text/css">

</style>

<link href="unsaved:///../NHX/CSS/Level1_Verdana.css" rel="stylesheet" type="text/css">

<link href="unsaved:///../NHX/CSS/scb.css" rel="stylesheet" type="text/css">

<style type="text/css">

<!--

.style28 {font-size: xx-small}

-->

</style>

</head>

 

<body bgcolor="#E0E0E0">

<?php

$sql_connect = @mysql_connect("213.232.95.7:3306", "Neil", "graystoke")

// $sql_connect = @mysql_connect("localhost:3306", "user", "webcore")

or

die('Could not connect: ' . mysql_error());

mysql_select_db("tml");

 

$qry = "select distinct r2.name, r.selectionId, m.marketId, v.name, DATE_FORMAT(m.start_time_gmt + INTERVAL 0 SECOND, '%H:%i'), r.ID, r.lay10, r.lay1, r.layed, r.percentage, r2.finishing_position from tml.runners r join capture.markets m on (m.marketId = r.marketId) join venues.venues v on (v.id = m.venue) join capture.runners r2 on (r2.selectionid = r.selectionid AND r.marketid = r2.marketid) where to_days(m.start_time_gmt) = to_days(utc_date)  - if(HOUR(UTC_TIMESTAMP) < 13, 1, 0)  order by m.start_time_gmt";

//if(HOUR(UTC_TIMESTAMP) < 14, 1, 0)  order by m.start_time_gmt";

 

//echo $qry;

$rs = mysql_query($qry, $sql_connect);

$heading = "";

?>

<div align="center"><span class="Heading"><?php echo $heading?><script type="text/javascript" src="http://www.freeflashheaders.com/resources/swfobject.js"></script>

<div id="freeflashheader" align="center">

<div id="noUpdate">

<p>The content presented here requires JavaScript to be enabled and the latest version of the Macromedia Flash Player. If you are you using a browser with JavaScript disabled please enable it now. Otherwise, please update your version of the free Flash Player by <a href="http://www.macromedia.com/go/getflashplayer">downloading here</a>. </p>

</div>

</div>

 

<script type="text/javascript">

var so = new SWFObject("http://www.freeflashheaders.com/resources/displayHeader.swf", "FFHDisplayHeader", "700", "150", "9", "#ffffff");

so.addParam("scale", "exactfit");

so.addVariable("id", "9426");

so.addVariable("header", "1");

so.write("freeflashheader");

  </script>

</span></div>

<p align="center"><b><font color="#FF0000" face="Tahoma" size="5">Live Bets</font></b></p>

<div align="center">

  <center>

 

<table width="700"  height="20" border=1 cellpadding=0 cellspacing=0 bordercolor="#777777" bordercolordark="#FFFFFF" bgcolor="#FFE493" class="data_tbl" style="border-collapse: collapse">

<tr>

    <th width="80" bgcolor="#C0C0C0" nowrap><div align="center">

      <span class="style5">Race Time</span></div></th>

    <th width="102" bgcolor="#C0C0C0"><span class="style5">Race Course</span></th>

    <th width="150" bgcolor="#C0C0C0"><span class="style5">Horse</span></th>

   

   

   

    <th width="150" bgcolor="#C0C0C0" nowrap><span class="style5">Lay Bet </span></th>

    <th width="37" bgcolor="#C0C0C0"><span class="style5">Finishing Position</span></th>

  </tr>

    <col width="10">

  <?php

$cnt = 1;

while($row = mysql_fetch_array($rs)) {

?>

  <tr class="small_tbl">

    <form action="" method="post" name="form1">

    </form>

    <td width="41"><?php echo $row[4]?>

     

     <td width="102"><?php echo $row[3]?>

       <td width="111"><div align="center"><?php echo $row[0]?>

   

    </div>

   

        </div>

            <div align="center">

              <input type="hidden" name="ID" value="<?php echo $row[5]; ?>" />

              <input type="hidden" name="marketId" value="<?php echo $row[2]; ?>" />

              <input type="hidden" name="selectionId" value="<?php echo $row[1]; ?>" />

        </div>

     

    <td width="37" align="center"> <img border='0' src='arrow8.gif' width='36' height='36'>

<?php if ($row[8]) echo "checked"; ?> <td width="53"><div align="center"><?php echo $row[10]?>

    </form>   

  </tr>

      <?php

  $cnt += 1;

 

}

 

mysql_free_result($rs);

mysql_close($sql_connect);

 

?>

</table>

<hr>

<center>

  <span class="footer">Copyright© NHX Thailand. All rights reserved</span>

</center>

 

  </center>

</div>

 

</body>

</html>

 

I have tried to replace the code section above that relates to the arrow with:

<td width="37" align="center"> <img border="0" <?php if

 

($row[8])  echo "src=\"arrow8.gif"\" ?> width="30"

 

height="30">";

 

<?php if ($row[8]) echo "checked"; ?>

 <td width="53">

<div align="center">

<?php echo $row[10]?>

    </form>

 

But I am getting no where.

 

I hope this explains my position more fully and any help really appreciated.

 

Thank

Link to comment
Share on other sites

Hi Thousand apologies, I had no idea about code tags so I hope I have done this right.

I have a web site: www.autobetpro.com/testtwo.php which has a checkbox which is unticked until the feed to the web site ticks the box. The code for this site is:

<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>TML Nano Runners</title>
<style type="text/css">
</style>
<link href="../NHX/CSS/Level1_Verdana.css" rel="stylesheet" type="text/css">
<link href="../NHX/CSS/scb.css" rel="stylesheet" type="text/css">
<style type="text/css">
<!--
.style28 {font-size: xx-small}
-->
</style>
</head>

<body>
<?php
$sql_connect = @mysql_connect("*****", "*****", "*****")
// $sql_connect = @mysql_connect("*****", "*****", "*****")
or 
die('Could not connect: ' . mysql_error());
mysql_select_db("tml");

$qry = "select distinct r2.name, r.selectionId, m.marketId, v.name, DATE_FORMAT(m.start_time_gmt + INTERVAL 0 SECOND, '%H:%i'), r.ID, r.lay10, r.lay1, r.layed, r.percentage, r2.finishing_position from tml.runners r join capture.markets m on (m.marketId = r.marketId) join venues.venues v on (v.id = m.venue) join capture.runners r2 on (r2.selectionid = r.selectionid AND r.marketid = r2.marketid) where to_days(m.start_time_gmt) = to_days(utc_date)  - if(HOUR(UTC_TIMESTAMP) < 13, 1, 0)  order by m.start_time_gmt"; 
//if(HOUR(UTC_TIMESTAMP) < 14, 1, 0)  order by m.start_time_gmt"; 

//echo $qry;
$rs = mysql_query($qry, $sql_connect);
$heading = "TML Runners";
?>
<div align="center"><span class="Heading"><?php echo $heading?></span></div>
<hr>

<table width="500"  height="20" border=1 align="center" cellpadding=1 cellspacing=0 bordercolor="#777777" bordercolordark="#ffffff" bgcolor="#FFFFCC" class="data_tbl">
<tr>
    <th width="41" bgcolor="#C0C0C0"><div align="center"><span class="style5">Start</span></div></th>
    <th width="102" bgcolor="#C0C0C0"><span class="style5">Venue</span></th>
    <th width="111" bgcolor="#C0C0C0"><span class="style5">Runner</span></th>
    <th width="56" bgcolor="#C0C0C0"><span class="style5">10 Min</span></th>
    <th width="70" bgcolor="#C0C0C0"><span class="style5">1 Min</span></th>
    <th width="53" bgcolor="#C0C0C0"><span class="style5">%age</span></th>
    <th width="37" bgcolor="#C0C0C0"><span class="style5">Lay</span></th>
    <th width="37" bgcolor="#C0C0C0"><span class="style5">Finished</span></th>
  </tr>
    <col width="10">
   <?php
$cnt = 1;
while($row = mysql_fetch_array($rs)) {
?>
  <tr class="small_tbl">
    <form action="" method="post" name="form1">
    </form>
    <td width="41"><?php echo $row[4]?>
      
     <td width="102"><?php echo $row[3]?>
       <td width="111"><div align="center"><?php echo $row[0]?>
     <td width="56"><div align="center"><?php echo $row[6]?>
     </div>
     <td width="70"><div align="center"><?php echo $row[7]?>
         </div>
       <label for="checkbox"></label>
            <div align="center">
              <input type="hidden" name="ID" value="<?php echo $row[5]; ?>" />
              <input type="hidden" name="marketId" value="<?php echo $row[2]; ?>" />
              <input type="hidden" name="selectionId" value="<?php echo $row[1]; ?>" />
        </div>
      <td width="53"><div align="center"><?php echo $row[9]?>
     <td width="37" align="center"><input name="checkbox" type="checkbox" id="checkbox" value="checkbox" <?php if ($row[8]) echo "checked"; ?>>
      <td width="53"><div align="center"><?php echo $row[10]?>
    </form>    
  </tr>
       <?php
  $cnt += 1;
  
}

mysql_free_result($rs);
mysql_close($sql_connect);

?>
</table>
<hr>
<center>
  <span class="footer">Copyright(C) NHX Thailand. All rights reserved</span>
</center>

</body>
</html>
/code]

I want to replace the checkbox with a green flashing arrow and I have tried to do this with the following script below, but as you can see from the following url, the arrow appears where every checkbox is. I am trying to get it just to appear where the ticked checkboxes are in the first url above.

www.autobetpro.com/livebets.php
[code]<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>AUTOBETPRO LIVE BETS</title>
<style type="text/css">
</style>
<link href="unsaved:///../NHX/CSS/Level1_Verdana.css" rel="stylesheet" type="text/css">
<link href="unsaved:///../NHX/CSS/scb.css" rel="stylesheet" type="text/css">
<style type="text/css">
<!--
.style28 {font-size: xx-small}
-->
</style>
</head>

<body bgcolor="#E0E0E0">
<?php
$sql_connect = @mysql_connect("213.232.95.7:3306", "Neil", "graystoke")
// $sql_connect = @mysql_connect("localhost:3306", "user", "webcore")
or 
die('Could not connect: ' . mysql_error());
mysql_select_db("tml");

$qry = "select distinct r2.name, r.selectionId, m.marketId, v.name, DATE_FORMAT(m.start_time_gmt + INTERVAL 0 SECOND, '%H:%i'), r.ID, r.lay10, r.lay1, r.layed, r.percentage, r2.finishing_position from tml.runners r join capture.markets m on (m.marketId = r.marketId) join venues.venues v on (v.id = m.venue) join capture.runners r2 on (r2.selectionid = r.selectionid AND r.marketid = r2.marketid) where to_days(m.start_time_gmt) = to_days(utc_date)  - if(HOUR(UTC_TIMESTAMP) < 13, 1, 0)  order by m.start_time_gmt"; 
//if(HOUR(UTC_TIMESTAMP) < 14, 1, 0)  order by m.start_time_gmt"; 

//echo $qry;
$rs = mysql_query($qry, $sql_connect);
$heading = "";
?>
<div align="center"><span class="Heading"><?php echo $heading?><script type="text/javascript" src="http://www.freeflashheaders.com/resources/swfobject.js"></script>
<div id="freeflashheader" align="center">
   <div id="noUpdate">
   <p>The content presented here requires JavaScript to be enabled and the latest version of the Macromedia Flash Player. If you are you using a browser with JavaScript disabled please enable it now. Otherwise, please update your version of the free Flash Player by <a href="http://www.macromedia.com/go/getflashplayer">downloading here</a>. </p>
   </div>
</div>

<script type="text/javascript">
   var so = new SWFObject("http://www.freeflashheaders.com/resources/displayHeader.swf", "FFHDisplayHeader", "700", "150", "9", "#ffffff");
   so.addParam("scale", "exactfit");
   so.addVariable("id", "9426");
   so.addVariable("header", "1");
   so.write("freeflashheader");
  </script>
</span></div>
<p align="center"><b><font color="#FF0000" face="Tahoma" size="5">Live Bets</font></b></p>
<div align="center">
  <center>

<table width="700"  height="20" border=1 cellpadding=0 cellspacing=0 bordercolor="#777777" bordercolordark="#FFFFFF" bgcolor="#FFE493" class="data_tbl" style="border-collapse: collapse">
<tr>
    <th width="80" bgcolor="#C0C0C0" nowrap><div align="center">
      <span class="style5">Race Time</span></div></th>
    <th width="102" bgcolor="#C0C0C0"><span class="style5">Race Course</span></th>
    <th width="150" bgcolor="#C0C0C0"><span class="style5">Horse</span></th>
    
    
    
    <th width="150" bgcolor="#C0C0C0" nowrap><span class="style5">Lay Bet </span></th>
    <th width="37" bgcolor="#C0C0C0"><span class="style5">Finishing Position</span></th>
  </tr>
    <col width="10">
   <?php
$cnt = 1;
while($row = mysql_fetch_array($rs)) {
?>
  <tr class="small_tbl">
    <form action="" method="post" name="form1">
    </form>
    <td width="41"><?php echo $row[4]?>
      
     <td width="102"><?php echo $row[3]?>
       <td width="111"><div align="center"><?php echo $row[0]?>
     
     </div>
     
         </div>
            <div align="center">
              <input type="hidden" name="ID" value="<?php echo $row[5]; ?>" />
              <input type="hidden" name="marketId" value="<?php echo $row[2]; ?>" />
              <input type="hidden" name="selectionId" value="<?php echo $row[1]; ?>" />
        </div>
      
     <td width="37" align="center"> <img border='0' src='arrow8.gif' width='36' height='36'>
<?php if ($row[8]) echo "checked"; ?> <td width="53"><div align="center"><?php echo $row[10]?>
    </form>    
  </tr>
       <?php
  $cnt += 1;
  
}

mysql_free_result($rs);
mysql_close($sql_connect);

?>
</table>
<hr>
<center>
  <span class="footer">Copyright(C) NHX Thailand. All rights reserved</span>
</center>

  </center>
</div>

</body>
</html>
/code]

I have tried to replace the code section above that relates to the arrow with:
[code]<td width="37" align="center"> <img border="0" <?php if 

($row[8])  echo "src=\"arrow8.gif"\" ?> width="30" 

height="30">"; 

<?php if ($row[8]) echo "checked"; ?>
 <td width="53">
<div align="center">
<?php echo $row[10]?>
    </form>/code]

But I am getting no where.

I hope this explains my position more fully and any help really appreciated.

Thanks


Link to comment
Share on other sites

Sorry Guys not getting anywhere, probably because I dont really know what I am doing.

 

Perhaps if I explain a bit more fully.

 

I have a web site: www.autobetpro.com/testtwo.php which has a checkbox which is unticked until the feed to the web site ticks the box. The code for this site is:

<html>

<head>

<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

<title>TML Nano Runners</title>

<style type="text/css">

</style>

<link href="../NHX/CSS/Level1_Verdana.css" rel="stylesheet" type="text/css">

<link href="../NHX/CSS/scb.css" rel="stylesheet" type="text/css">

<style type="text/css">

<!--

.style28 {font-size: xx-small}

-->

</style>

</head>

 

<body>

<?php

$sql_connect = @mysql_connect("213.232.95.7:3306", ***********)

// $sql_connect = @mysql_connect("localhost:3306", *************)

or

die('Could not connect: ' . mysql_error());

mysql_select_db("tml");

 

$qry = "select distinct r2.name, r.selectionId, m.marketId, v.name, DATE_FORMAT(m.start_time_gmt + INTERVAL 0 SECOND, '%H:%i'), r.ID, r.lay10, r.lay1, r.layed, r.percentage, r2.finishing_position from tml.runners r join capture.markets m on (m.marketId = r.marketId) join venues.venues v on (v.id = m.venue) join capture.runners r2 on (r2.selectionid = r.selectionid AND r.marketid = r2.marketid) where to_days(m.start_time_gmt) = to_days(utc_date)  - if(HOUR(UTC_TIMESTAMP) < 13, 1, 0)  order by m.start_time_gmt";

//if(HOUR(UTC_TIMESTAMP) < 14, 1, 0)  order by m.start_time_gmt";

 

//echo $qry;

$rs = mysql_query($qry, $sql_connect);

$heading = "TML Runners";

?>

<div align="center"><span class="Heading"><?php echo $heading?></span></div>

<hr>

 

<table width="500"  height="20" border=1 align="center" cellpadding=1 cellspacing=0 bordercolor="#777777" bordercolordark="#ffffff" bgcolor="#FFFFCC" class="data_tbl">

<tr>

    <th width="41" bgcolor="#C0C0C0"><div align="center"><span class="style5">Start</span></div></th>

    <th width="102" bgcolor="#C0C0C0"><span class="style5">Venue</span></th>

    <th width="111" bgcolor="#C0C0C0"><span class="style5">Runner</span></th>

    <th width="56" bgcolor="#C0C0C0"><span class="style5">10 Min</span></th>

    <th width="70" bgcolor="#C0C0C0"><span class="style5">1 Min</span></th>

    <th width="53" bgcolor="#C0C0C0"><span class="style5">%age</span></th>

    <th width="37" bgcolor="#C0C0C0"><span class="style5">Lay</span></th>

    <th width="37" bgcolor="#C0C0C0"><span class="style5">Finished</span></th>

  </tr>

    <col width="10">

  <?php

$cnt = 1;

while($row = mysql_fetch_array($rs)) {

?>

  <tr class="small_tbl">

    <form action="" method="post" name="form1">

    </form>

    <td width="41"><?php echo $row[4]?>

     

     <td width="102"><?php echo $row[3]?>

       <td width="111"><div align="center"><?php echo $row[0]?>

    <td width="56"><div align="center"><?php echo $row[6]?>

    </div>

    <td width="70"><div align="center"><?php echo $row[7]?>

        </div>

      <label for="checkbox"></label>

            <div align="center">

              <input type="hidden" name="ID" value="<?php echo $row[5]; ?>" />

              <input type="hidden" name="marketId" value="<?php echo $row[2]; ?>" />

              <input type="hidden" name="selectionId" value="<?php echo $row[1]; ?>" />

        </div>

      <td width="53"><div align="center"><?php echo $row[9]?>

    <td width="37" align="center"><input name="checkbox" type="checkbox" id="checkbox" value="checkbox" <?php if ($row[8]) echo "checked"; ?>>

      <td width="53"><div align="center"><?php echo $row[10]?>

    </form>   

  </tr>

      <?php

  $cnt += 1;

 

}

 

mysql_free_result($rs);

mysql_close($sql_connect);

 

?>

</table>

<hr>

<center>

  <span class="footer">Copyright© NHX Thailand. All rights reserved</span>

</center>

 

</body>

</html>

 

I want to replace the checkbox with a green flashing arrow and I have tried to do this with the following script below, but as you can see from the following url, the arrow appears where every checkbox is. I am trying to get it just to appear where the ticked checkboxes are in the first url above.

 

www.autobetpro.com/livebets.php

<html>

<head>

<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

<title>AUTOBETPRO LIVE BETS</title>

<style type="text/css">

</style>

<link href="unsaved:///../NHX/CSS/Level1_Verdana.css" rel="stylesheet" type="text/css">

<link href="unsaved:///../NHX/CSS/scb.css" rel="stylesheet" type="text/css">

<style type="text/css">

<!--

.style28 {font-size: xx-small}

-->

</style>

</head>

 

<body bgcolor="#E0E0E0">

<?php

$sql_connect = @mysql_connect("213.232.95.7:3306", **********)

// $sql_connect = @mysql_connect("localhost:3306", **********)

or

die('Could not connect: ' . mysql_error());

mysql_select_db("tml");

 

$qry = "select distinct r2.name, r.selectionId, m.marketId, v.name, DATE_FORMAT(m.start_time_gmt + INTERVAL 0 SECOND, '%H:%i'), r.ID, r.lay10, r.lay1, r.layed, r.percentage, r2.finishing_position from tml.runners r join capture.markets m on (m.marketId = r.marketId) join venues.venues v on (v.id = m.venue) join capture.runners r2 on (r2.selectionid = r.selectionid AND r.marketid = r2.marketid) where to_days(m.start_time_gmt) = to_days(utc_date)  - if(HOUR(UTC_TIMESTAMP) < 13, 1, 0)  order by m.start_time_gmt";

//if(HOUR(UTC_TIMESTAMP) < 14, 1, 0)  order by m.start_time_gmt";

 

//echo $qry;

$rs = mysql_query($qry, $sql_connect);

$heading = "";

?>

<div align="center"><span class="Heading"><?php echo $heading?><script type="text/javascript" src="http://www.freeflashheaders.com/resources/swfobject.js"></script>

<div id="freeflashheader" align="center">

<div id="noUpdate">

<p>The content presented here requires JavaScript to be enabled and the latest version of the Macromedia Flash Player. If you are you using a browser with JavaScript disabled please enable it now. Otherwise, please update your version of the free Flash Player by <a href="http://www.macromedia.com/go/getflashplayer">downloading here</a>. </p>

</div>

</div>

 

<script type="text/javascript">

var so = new SWFObject("http://www.freeflashheaders.com/resources/displayHeader.swf", "FFHDisplayHeader", "700", "150", "9", "#ffffff");

so.addParam("scale", "exactfit");

so.addVariable("id", "9426");

so.addVariable("header", "1");

so.write("freeflashheader");

  </script>

</span></div>

<p align="center"><b><font color="#FF0000" face="Tahoma" size="5">Live Bets</font></b></p>

<div align="center">

  <center>

 

<table width="700"  height="20" border=1 cellpadding=0 cellspacing=0 bordercolor="#777777" bordercolordark="#FFFFFF" bgcolor="#FFE493" class="data_tbl" style="border-collapse: collapse">

<tr>

    <th width="80" bgcolor="#C0C0C0" nowrap><div align="center">

      <span class="style5">Race Time</span></div></th>

    <th width="102" bgcolor="#C0C0C0"><span class="style5">Race Course</span></th>

    <th width="150" bgcolor="#C0C0C0"><span class="style5">Horse</span></th>

   

   

   

    <th width="150" bgcolor="#C0C0C0" nowrap><span class="style5">Lay Bet </span></th>

    <th width="37" bgcolor="#C0C0C0"><span class="style5">Finishing Position</span></th>

  </tr>

    <col width="10">

  <?php

$cnt = 1;

while($row = mysql_fetch_array($rs)) {

?>

  <tr class="small_tbl">

    <form action="" method="post" name="form1">

    </form>

    <td width="41"><?php echo $row[4]?>

     

     <td width="102"><?php echo $row[3]?>

       <td width="111"><div align="center"><?php echo $row[0]?>

   

    </div>

   

        </div>

            <div align="center">

              <input type="hidden" name="ID" value="<?php echo $row[5]; ?>" />

              <input type="hidden" name="marketId" value="<?php echo $row[2]; ?>" />

              <input type="hidden" name="selectionId" value="<?php echo $row[1]; ?>" />

        </div>

     

    <td width="37" align="center"> <img border='0' src='arrow8.gif' width='36' height='36'>

<?php if ($row[8]) echo "checked"; ?> <td width="53"><div align="center"><?php echo $row[10]?>

    </form>   

  </tr>

      <?php

  $cnt += 1;

 

}

 

mysql_free_result($rs);

mysql_close($sql_connect);

 

?>

</table>

<hr>

<center>

  <span class="footer">Copyright© NHX Thailand. All rights reserved</span>

</center>

 

  </center>

</div>

 

</body>

</html>

 

I have tried to replace the code section above that relates to the arrow with:

<td width="37" align="center"> <img border="0" <?php if

 

($row[8])  echo "src=\"arrow8.gif"\" ?> width="30"

 

height="30">";

 

<?php if ($row[8]) echo "checked"; ?>

 <td width="53">

<div align="center">

<?php echo $row[10]?>

    </form>

 

But I am getting no where.

 

I hope this explains my position more fully and any help really appreciated.

 

Thank

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.