How To Display Array Contents
RegisterLogin
How To Display Array Contents
Post Description: How To Display Array Contents
Tags: How, To, Display, Array, Contents
This Post Was Posted On Feb 29, 2008 By mysql #1288
Post Description: How To Display Array Contents
Tags: How, To, Display, Array, Contents
This Post Was Posted On Feb 29, 2008 By mysql #1288
How To Display Array Contents by mysql
for example if i have an array with 5 different values, how can i display what that array holds?
thanks
Leave Your Comments
Related Pages: [Add Your Website]
Post New Topic
Administrator
#1719 1
take a look at this tutorial. it helped me alot
how-to-index-arrays-and-show-all-the-elements-and-values-of-array
how-to-index-arrays-and-show-all-the-elements-and-values-of-array
Feb 24, 2008 Reply Report abuse
tech support
#1718 2
if you want display from mysql query you can us this one:
$sql = "SELECT * FROM ".$db_prefix."config";
$result = mysql_query($sql ,$db);
$myrow = mysql_fetch_array($result);
print_r(array_values($myrow));
$result = mysql_query($sql ,$db);
$myrow = mysql_fetch_array($result);
print_r(array_values($myrow));
Feb 23, 2008 Reply Report abuse
hostman
#1717 3
Feb 11, 2008 Reply Report abuse
lucas
#1716 4
lets say you have something like this:
you will have something like this come out:
OUTPUT:
<?php
$array = array("size" => "XL", "color" => "gold");
print_r(array_values($array));
?>
you will have something like this come out:
OUTPUT:
Array
(
[0] => XL
[1] => gold
)
Feb 11, 2008 Reply Report abuse
Leave Your Comments...
©2012 Webune Forums - Sat Dec 15, 2012 6:41 pm
Powered by: Webune Forums V3
Powered by: Webune Forums V3