Jump to content
  • 0

How to Add image for Vending Information FluxCp?


Question

8 answers to this question

Recommended Posts

  • 0
Posted

The code should probably match the item/index.php theme file so the page will only try to show the image if the file is actually there:

<?php if ($icon=$this->iconImage($item->item_id)): ?>
	<td width="24"><img src="<?php echo htmlspecialchars($icon) ?>?nocache=<?php echo rand() ?>" /></td>
	<td><?php echo htmlspecialchars($item->name) ?></td>
<?php else: ?>
	<td colspan="2"><?php echo htmlspecialchars($item->name) ?></td>
<?php endif ?>

The images are served from data/items/icons/

  • 0
Posted (edited)

The code should probably match the item/index.php theme file so the page will only try to show the image if the file is actually there:

<?php if ($icon=$this->iconImage($item->item_id)): ?>
	<td width="24"><img src="<?php echo htmlspecialchars($icon) ?>?nocache=<?php echo rand() ?>" /></td>
	<td><?php echo htmlspecialchars($item->name) ?></td>
<?php else: ?>
	<td colspan="2"><?php echo htmlspecialchars($item->name) ?></td>
<?php endif ?>

The images are served from data/items/icons/

 

Do you have all the icons sir? Should I name it also 1.jpg 2.jpg?

Edited by Meister
  • 0
Posted
8 hours ago, melv0 said:

hi, @Akkarin can u give me example what should i do to show image 

 

vending.png

Well, since i don't have a crystal ball, i have no idea what you've done to get to this stage and have a non-image displayed. Right-click the image and select "open in new tab" and see what it's trying to load. 

  • 0
Posted
On 3/27/2018 at 12:08 AM, Akkarin said:

Well, since i don't have a crystal ball, i have no idea what you've done to get to this stage and have a non-image displayed. Right-click the image and select "open in new tab" and see what it's trying to load. 

sorry, you say this "The images are served from data/items/icons/"

On 12/15/2015 at 7:40 PM, Akkarin said:

The code should probably match the item/index.php theme file so the page will only try to show the image if the file is actually there:


<?php if ($icon=$this->iconImage($item->item_id)): ?>
	<td width="24"><img src="<?php echo htmlspecialchars($icon) ?>?nocache=<?php echo rand() ?>" /></td>
	<td><?php echo htmlspecialchars($item->name) ?></td>
<?php else: ?>
	<td colspan="2"><?php echo htmlspecialchars($item->name) ?></td>
<?php endif ?>

The images are served from data/items/icons/

I mean, how do I bring up images of diabolus ring in data/items/icons/
should the berfomat icon?
is it like this? 
 µ Æ º ¾ ð ¼ ½ º ¸ ç · µ. ico << sprite name diabolus ring
 or diabolus_ring.ico

 

sorry bad english i use translator

  • 0
Posted
5 minutes ago, Akkarin said:

Ah. You've just uploaded the images without using a conversion script.

Use this: 

 

 

yeah i mean this..

thx a lot bro :D

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...