View Single Post
Old 09-29-2009, 04:46 AM  
frank7799
Confirmed User
 
frank7799's Avatar
 
Industry Role:
Join Date: Jul 2003
Location: In the middle of nowhere...
Posts: 1,974
You can use a query and put the result into an array. There is an example below. You will need html where the variables are integrated in the "while" loop.


PHP Code:
$query "select description,title from ".MYSQLTABLE." where (site = '$site') $order";
$result mysql_query($query);

    
$number mysql_numrows($result);
    
    
$i 1;
    while (
$i <= $number)
    {
 
      
$row   mysql_fetch_array($result);
      
$title stripslashes($row["title"]);
      
$description stripslashes(nl2br($row["description"]));

      
$i++;
     } 
frank7799 is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote