Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls
 

Subcategory Display in 3.1.3a

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 11-08-2002, 11:00 AM
  minorgod's Avatar 
minorgod minorgod is offline
 

X-Adept
  
Join Date: Sep 2002
Location: Arivaca, AZ
Posts: 402
 

Default Subcategory Display in 3.1.3a

I'm looking at main/subcategories.tpl and I can't figure out what line 7 does or means....

Code:
[img]../icon.php?categoryid={$cat}[/img]

Is this garbage or does it actually do something? I've never seen an img src set equal to a php page and I can't even find the php page being referenced. Could someone enlighten me? Does this have something to do with that "browse" button at the top of my "modify category" page. I'd like to have icons for various categories, but can't figure out if this functionality already exists in the cart or not.
__________________
www.brettbrewer.com
Getting back into x-cart dev after a long hiatus. Modded lots of x-carts from version 3.1.x to 4.1.x. Developer of ImageScaler mod, Pre-login per user coupon mod, Wordpress feed mod, DigitalSubscriptions mod, Phonetic bulk download keys addon for DownloadExpander mod, Serial Number Generator for ESD products, Custom CMS/LMS integrations, external products mod, and more.
Reply With Quote
  #2  
Old 11-23-2002, 02:37 PM
 
syddos syddos is offline
 

eXpert
  
Join Date: Sep 2002
Location: London, England, UK
Posts: 259
 

Default

Hi,

This setting calls thephp file to process the catalogue image, I think this line calls the php script to produce the "No image available" icon for this item.

It will produce the "default image icon" for catalogue items without images.

Regards,
__________________
Syddos

Nothing is impossible, We just don't know how to do it ........Yet!

Xcart 4.1.X PRO (Testing Platform: winXP Pro)
Perl 5.8.7 (win32)
WINAMP 1.6.3 (win32 server package. Includes the following)
- phpMyAdmin v2.8.03
- MySql 5.0.21
- Apache 2.0.55 (win32)
- php 5.1.4
- SQLitemanager 1.2.0
Reply With Quote
  #3  
Old 11-23-2002, 05:30 PM
 
derrick92130 derrick92130 is offline
 

Advanced Member
  
Join Date: Nov 2002
Location: San Diego, California USA
Posts: 68
 

Default img src calling php question

This is actually a pretty trick way of getting the image. The "img src" tag is expecting an argument of an image file. The image will be the results of the execution of /xcart/icon.php (at the very top level back in the 3.1.x versions). The icon.php program makes a call to the icon table in the database using the value passed in "categoryid". The resulting image is then returned to the "img src" tag, which is none the wiser that the image was extracted out of the database. Minorgod was right on the mark, with the returning of a "default image" if no match can be found in the icon database.

Hope this helps.
__________________
-Derrick
FreeRangeMinds, LLC
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 10:12 AM.

   

 
X-Cart forums © 2001-2020