Image Caching Print

  • 0

Image caching will improve web page loading speed. Most images are able to hotlinked to the IDX server. Caching the images on the api server will result in smaller images and reduce the webpage loading time. Some RETS servers do not allow hotlinking, therefore image caching must be enabled in order to access the listing images.


Using the following code, you can render a listing image:


<?php $photo = rws_idxCommon::listing_photo('',$data["mls_num"],'lg-thumb'); ?>


<img style="vertical-align: middle" src="<?php echo rws_idxCommon::rws_idx_get_image($photo)  ?>" alt="<?php echo $title ?>" />


By editing the php function you can render different size images, as long as the image caching is enabled.


PHP Code Example:

$photo = rws_idxCommon::listing_photo('',$data["mls_num"],'lg-thumb');


You can change the 'lg-thumb' to the following options:


‘full’  -  640x480


FULL SIZE:http://api00.realtywebsolutions.net/images/resized/214014949.jpg&s=full 640x480


‘lg-thumb’ - 320x240


Large Thumb http://api00.realtywebsolutions.net/images/resized/214014949.jpg&s=lg-thumb 320x240


‘thumb’ - 80x60


Regular Thumb http://api00.realtywebsolutions.net/images/resized/214014949.jpg&s=thumb 80x60

‘tinythumb’ - 64x48


Tiny Thumb http://api00.realtywebsolutions.net/images/resized/213506666.jpg&s=tinythumb 64x48


‘w=100&h=250’ - Custom

Custom Image SIze (change w and h values) http://api00.realtywebsolutions.net/images/resized/214014949.jpg&w=100&h=250


Was this answer helpful?

« Back