Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Please explain tep_image


lildog

Recommended Posts

Could someone please post a brief explanation of . tep_image(DIR_WS_IMAGES . 'default/1.gif') . or point me in the right direction?

 

This is from the default home page, I know it is displaying the number one graphic. Just wanted to know what it is doing.

 

Thanks

 

Todd

Link to comment
Share on other sites

Could someone please post a brief explanation of . tep_image(DIR_WS_IMAGES . 'default/1.gif') . or point me in the right direction?...

It takes the image path you give it (you can pass it other parameters too like a name etc) and generates HTML that is then embedded into the page output.... and hey-presto - you get a piccie !! Well, most of the time, anyway :-)

 

Rich.

Link to comment
Share on other sites

why not just use a <img src="images/piccie.gif">? Is it a formatting thing?

 

If you look at the tep_image() function in includes/functions/html_output.php, you'll see it does a little more than just print out the img tag. It calculates image size if neccessary. You can also make global changes to img tags, like prefixing something to the title or alt parameters for all images.

Contributions

 

Discount Coupon Codes

Donations

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...