Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

i want to store retrieved data from database into an array
list with limit.And display the data from that array
list.have any answer for this?

Answer Posted / guest

First retrieve data from database using following command

$select = mysql_query("SELECT * FROM table limit number") or
die(mysql_error);

then store retrieve data in array using following command

while($row = mysql_fetch_array($select))
{
$rname[] = $row['name'];
}

display values of array

foreach($rname as $val)
{
echo $val;
}

Is This Answer Correct ?    15 Yes 5 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How many types of php frameworks are there?

919


What language is php written in?

1068


Tell me which programming language does php resemble to?

927


Explain php parameterized functions.

978


What is the use of count() function in php?

970


Which is variable cost?

963


What is polymorphism in php?

990


When a conditional statement is ended with an endif?

938


What is php session and how it works?

993


What is the delimiter syntax is PHP's default delimiter syntax

1277


Can you explain, when to use if-else if-else over switch statements?

1013


What do you mean range() in php?

1094


What is the difference between mysql_fetch_array() and mysql_fetch_assoc()?

1059


What is uri routing?

1044


Explain which cryptographic extension provide generation and verification of digital signatures?

1006