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
How come the code works, but doesn’t for two-dimensional array of mine?
Tell me what is pear?
What is active record in php?
Which function(s) in PHP computes the difference of arrays?
Which Scripting Engine PHP uses?
What is ci framework in php?
What are php parameters?
What is php constructor?
Explain Booleans in PHP?
Explain a resource?
How can MYSQL functions be available with PHP?
Which function is used in php to delete a file?
Is php used in 2019?
Tell me what is the actually used php version?
What is the meaning of a final class and a final method?