PHP Web Host - Quality Web Hosting For All PHP Applications Clan Themes! We make clans look good!!
  Login or Register
 • Home • Downloads • Your Account • Forums • 

View next topic
View previous topic


Google
 
Web RavenPHPScripts (This Site)
Post new topic   Reply to topic
Author Message
Rikk03
Worker
Worker


Joined: Feb 16, 2004
Posts: 164

PostPosted: Thu May 06, 2004 3:13 am Reply with quote Back to top

Help!

I have this block that shows Special Priced Products, however it only shows one item with picture per page load, I want to either:

Add additional random pictures below from same source - but so as not to show the same random picture twice

OR

Rotate the pictures from same source - removing the random element the current code is as follows

Code:
if (eregi("block-OSCSpecials.php",$_SERVER['PHP_SELF'])) {

    Header("Location: index.php");


    die();

}



global  $cPath, $languages_id, $random_product;

  $currencies = new currencies();

  $content ='';



 if ($random_product = tep_random_select("select p.products_id, pd.products_name, p.products_price, p.products_tax_class_id, p.products_image, s.specials_new_products_price from " . "products" . " p, " . "products_description" . " pd, " . "specials" . " s where p.products_status = '1' and p.products_id = s.products_id and pd.products_id = s.products_id and pd.language_id = '" . $languages_id . "' and s.status = '1' order by s.specials_date_added DESC limit " . MAX_RANDOM_SELECT_SPECIALS)) {

  $content = '<center><a href="'.tep_href_link("product_info.php", 'products_id=' . $random_product["products_id"], 'NONSSL') . '">' . tep_image('modules/catalog/images/'.$random_product['products_image'], $random_product['products_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT) . '</a><br><a href="' . tep_href_link('product_info.php', 'products_id=' . $random_product['products_id'], 'NONSSL') . '">' . $random_product['products_name'] /*. '</a><br><s>'. $currencies->display_price($random_product['products_price'], tep_get_tax_rate($random_product['products_tax_class_id'])) . '</s><br><span class="productSpecialPrice">' . $currencies->display_price($random_product['specials_new_products_price'], tep_get_tax_rate($random_product['products_tax_class_id']))*/ . '</span></center>';   
 

}



?>


Any help would be greatly appreciated.

Regards

Richard
View user's profile Send private message
Display posts from previous:       
Post new topic   Reply to topic

View next topic
View previous topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Forums ©
 

All logos and trademarks in this site are property of their respective owner.
The comments are property of their posters, all the rest © 2002-2011 by Raven

You can syndicate our news using the file xml

CSE HTML Validator Helped Clean up This Page! [Valid RSS] valid RSS 2.0 Valid robots.txt Stop Spam Harvesters, Join Project Honey Pot

Website engines core code is © copyright by PHP-Nuke but has been heavily patched and modified by myself and others.
PHP-Nuke is a free software released under the GNU/GPL.


:: fisubice phpbb2 style by Daz :: PHP-Nuke theme by www.nukemods.com ::
:: fisubice Theme Modified by the RavenNuke™ Team ::

:: W3C CSS Compliance Validation :: W3C HTML 4.01 Transitional Compliance Validation ::

zerosum