max() problem


Posted on 16th Feb 2014 07:03 pm by admin

I have a while loop to get image names.
Code: $imagequery = mysql_query("SELECT * FROM ad_image WHERE user='$user' AND ad='$adnr' ORDER BY `picorder` ASC")or die(mysql_error());
$totpics = mysql_num_rows($imagequery);
while ($imageset = mysql_fetch_array($imagequery)){
Did you know?Explore Trending and Topic pages for more stories like this.
$order= $imageset['picorder'];
$image= $imageset['image'];
$title= $imageset['title'];
$imagesize = getimagesize($modx->config['base_path'].'ad_images/'.$image);
$height = $imagesize[1];
}
How do I get the highest number of $height as
Code: $array = array($height);
echo max($array);does not work?
No comments posted yet

Your Answer:

Login to answer
154 Like 11 Dislike
Previous forums Next forums
Other forums

Strange php code found on my website
I got hacked and the following code was placed within my files:

Code: [Select]<?
/*

get the country of visitor and display content based on that
Hello all,

I have seen that Google analytics can tell you where a visitor is coming from and

Insert numbers from Barcode scanner into online php page
I have a real big problem, Here is what I'm trying to do. I have a Intermec CN3 handheld computer th

want to add a break after a certain amount of characters
i was wondering how to add a break in a blog post after a certain amount of characters... any idea o

Array becomes unset by itself?
Hi,

I have a bit of experience with PHP but not extensive. It seems I cannot store any items

Help adding strtolower( to my in_array
strtolower i need to add it to this to work, iuno how.

Code: $moderators = array('Admin', 'ba

php slowing my site?
Hi all,

I think that one of the reasons that my site doesn't work fast is that the code is ve

PHP mail() with images
I'm trying to get images to send along with my HTML e-mail sent through PHP mail(). I only tried vie

mysql UPDATE request not working and driving me crazy!!!
Hi,

I have been stuck on this for ages.

Quite simply I am trying to update my database

Dynamically set AccordianPane Header
I have an accordian on my master page. I'd like to be able to dynamically change the header on diff

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash