Jump to content

Archived

This topic is now archived and is closed to further replies.

ltoto

div tag around code (huggiebear may know)

Recommended Posts

I was just wondering how to style the country Id part in this code

[code]<?php

$sql="SELECT c.countryName, c.countryImage, r.regionName, r.Id
    FROM tabCountry c, tabRegion r
    WHERE c.Id = r.countryId";
$result = mysql_query($sql);
if (!$result) {
  die('Invalid query: ' . mysql_error());
}
$country = "null";
while ($row = mysql_fetch_array($result, MYSQL_ASSOC)){
  $cheader = $row['countryName'];
  if (strcmp($country,$cheader) !=0){
      $country = $row['countryName'];

      echo <<<HTML
     
    <br>

     
        <div class="homebar2"><h1>$cheader</h1></div>
<div class="country">  <img src="../thumb/phpThumb.php?src=../images/country_{$row['countryImage']}&amp;w=100&amp;h=100&amp;zc=1"  alt="Latest Deals">  </div> 
       
HTML;
  }
echo <<<HTML
  <a href="index.php?Id=16&id={$row['Id']}">{$row['regionName']}</a><br>
HTML;
}
?>[/code]

so i want to style the regions basically

Share this post


Link to post
Share on other sites

×

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.