Jump to content

[SOLVED] Image Display Problem


Sinikka

Recommended Posts

There are two types of variations for the image I'm trying to get to display a dyed and non-dyed pet. Right now the coding will only pull the dyed pets and display them but passes over the non-dyed. I'm trying to get it to show both like it does on other pages throughout the site and it's the same coding but for some reason it won't work on this page. I was wondering if anyone had any suggestions or can see something that I'm not seeing as to why this isn't working correctly.

 

$query = mysql_query("SELECT * FROM user_pets2 WHERE owner = '$userid' AND adoption = '0' AND game = '$game' ORDER BY id ASC");

while ($array = mysql_fetch_array($query))
{
$id = $array[id];
$getPet = fetch("SELECT * FROM pets2 WHERE id = '$array[species]' AND game = '$game'");

$image[$id] = "pet_$getPet[id]";

if ($array[wearing] != 0)
{
	$findLook = fetch("SELECT * FROM pet_looks WHERE change_from = '$array[species]' AND item_name = '$array[wearing]'");

	if ($findLook[id])
	{
		$image[$id] = "pet2_$findLook[id]";

echo "
<p align=center>
<img src=$base_url/images/user_images/opg_$game/pets/$image[$id].gif>
<br><b>$array[name]</b> the $getPet[name]!</p><p align=center>Equipped Items:</p>";

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.