Jump to content

Recommended Posts

My website has stopped working...not sure why...error in this file somewhere

 

<?

include 'lnglat.php';

include 'conn.php';

 

$startrow = $_GET['row'];

 

?><br><?

$query = "SELECT * FROM testimonials WHERE lat BETWEEN ".$rlat." AND ".$llat." AND lng BETWEEN ".$llng." AND ".$rlng." LIMIT ".$startrow.", 9";

?>

 

<html xmlns:v="urn:schemas-microsoft-com:vml">

  <head>

    <title>My GMapEZ Maps</title>

 

    <meta name="gmapkey" content="ABQIAAAAHK9B1odMblO_RDGYp68fVBQph564W_sfd6LeiVJWuMclzaD6KBRQKiQJdlASrx4wj5V8HWxb2QuhlQ" />

    <script

      src="http://n01se.net/gmapez/gmapez-2.js"

      type="text/javascript"></script>

  </head> 

  <body>

   

<div class="GMapEZ G_MAP_TYPE GLargeMapControl GMapTypeControl GOverviewMapControl" style="width: 388px; height: 300px;">

<a href="http://maps.google.com/maps?ll=<? echo $_GET['lat']; ?>,<? echo $_GET['lng'];?>&spn=0.006130,0.009795&t=k&hl=en">GREEN START</a><div><b>You Are Here!</b><br>Your Longitude is: <? echo $_GET['lng'];?><br> Your Latitude is: <? echo $_GET['lat'];?></div>

<?

 

$result = mysql_query($query, $link) or die("Data not found.");

 

for($x = 0 ; $x < mysql_num_rows($result) ; $x++){

    $row = mysql_fetch_assoc($result);

if ($row['lat'] == 0.000000) {}else{

?><a href="http://maps.google.com/maps?ll=<? echo ($row['lat']); ?>,<? echo ($row['lng']);?>&spn=0.006130,0.009795&t=k&hl=en"><? echo $x + 1;?></a>

  <div>

  <? if (!empty($row['quote'])){echo '"'.$row['quote'].'"';} ?>

  <? if (!empty($row['firstname'])){echo $row['firstname']."<br>";} ?>

  <? if (!empty($row['lastname'])){echo $row['lastname']."<br>";} ?>

  <? if (!empty($row['address'])){echo $row['address']."<br>";} ?>

  <? if (!empty($row['city'])){echo $row['city'].",";} ?>

  <? if (!empty($row['state'])){echo $row['state'];} ?>

  <? if (!empty($row['zip'])){echo $row['zip'];} ?>

  </div><?

} // empty lat

?>

  <?

}  //end for loop

 

?>

 

</div>

<!-- Start of StatCounter Code -->

<script type="text/javascript">

sc_project=2219825;

sc_invisible=1;

sc_partition=20;

sc_security="d20cf4ff";

</script>

 

<script type="text/javascript" src="http://www.statcounter.com/counter/counter.js"></script><noscript><div class="statcounter"><a href="http://www.statcounter.com/free_hit_counter.html" target="_blank"><img class="statcounter" src="http://c21.statcounter.com/2219825/0/d20cf4ff/1/" alt="counter hit make" ></a></div></noscript>

<!-- End of StatCounter Code -->

</body>

</html>

Link to comment
https://forums.phpfreaks.com/topic/117708-error-in-code-help/
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.