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

Newest Products

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions
 
Thread Tools Search this Thread
  #191  
Old 07-25-2007, 12:04 PM
 
yages yages is offline
 

eXpert
  
Join Date: Sep 2004
Location: Australia
Posts: 332
 

Default Re: Newest Products

Deleted second mod from my site

The first mod (zip file) works Ok but does not show product short description and standard sale price / actual sale price
__________________
yages
x-cart version 4.5.5
Reply With Quote
  #192  
Old 07-31-2007, 10:00 AM
 
vulcan-works vulcan-works is offline
 

Senior Member
  
Join Date: Feb 2004
Posts: 143
 

Default Re: Newest Products

PHP Code:
#
# $Id: newest.php 2007/07/22 $
#
// set variables
$daterange 7776000// 60 * 60 * 24 * 90 days in unix time
$nowtime time();
$oldtime $nowtime $daterange ;
 
# Get new products data and store it into $newproducts array
#
if ( !defined('XCART_START') ) { header("Location: home.php"); die("Access denied"); }
#
# Select from products table
#
$user_account['membershipid'] = !empty($user_account['membershipid'])?$user_account['membershipid']:0;
$old_search_data $search_data["products"];
$old_mode $mode;
$old_page $page;
$search_data["products"] = array();
$search_data["products"]["forsale"] = "Y";
$search_data["products"]["avail"] = "> 0";
$search_data["products"]["add_date"] = "> " $oldtime "";
$search_data["products"]["add_date"] = "< " $nowtime "";
$search_data["products"]["sort_condition"] = "$sql_tbl[products].add_date DESC";
$REQUEST_METHOD "GET";
$mode "search";
include 
$xcart_dir."/include/search.php";
$search_data["products"] = $old_search_data;
x_session_save("search_data");
$mode $old_mode;
$page $old_page;
unset(
$old_search_data$old_mode$old_page);
$smarty->clear_assign("newproducts");
$smarty->assign("newproducts",$products);
$search_data '';
$products = array();
unset(
$search_data$products); 


You must add:
Code:
<?php
at the very top of the file
and
Code:
?>
to the end of it for it to work
but other than that great job!
__________________
X-cart--4.7.12

vulcanworks.net
Reply With Quote
  #193  
Old 08-13-2007, 08:40 PM
 
Amy Amy is offline
 

Senior Member
  
Join Date: Feb 2004
Posts: 147
 

Default Re: Newest Products

how would you change the image size on the home page of the previews?
__________________
X-Cart Pro 4.0.19; Unix

Other:
XAOM
XOffers
XGift Reg

Other Mods:
Customers Who Also Bought, Download Link Regenerate, Easy Checkout, Newest Products, SEO/CDSEO, Marketing Manager Pro, View Wishlist for Providers (custom by xcart), Email New Releases (a fav!), Telefirma's Dynamic Image Generator, Download Links on Invoice
Reply With Quote
  #194  
Old 08-14-2007, 04:08 PM
 
Amy Amy is offline
 

Senior Member
  
Join Date: Feb 2004
Posts: 147
 

Default Re: Newest Products

we found where to change the thumbnail size but when we alter that something else seems to be overriding our settings and reverting it back to 100 px.
__________________
X-Cart Pro 4.0.19; Unix

Other:
XAOM
XOffers
XGift Reg

Other Mods:
Customers Who Also Bought, Download Link Regenerate, Easy Checkout, Newest Products, SEO/CDSEO, Marketing Manager Pro, View Wishlist for Providers (custom by xcart), Email New Releases (a fav!), Telefirma's Dynamic Image Generator, Download Links on Invoice
Reply With Quote
  #195  
Old 08-27-2007, 08:39 PM
  Vacman's Avatar 
Vacman Vacman is offline
 

X-Adept
  
Join Date: Sep 2005
Location: Torrance, CA
Posts: 792
 

Default Re: Newest Products

Nice little add-on. Have something like this for 4.0.16, so it is nice to see it again!

Is there a way to limit the number of products shown? Currently, mine shows 15 newest products.
__________________
Carl Tice

X-Cart 4.6.6
X-Payments 3.0
ReBOOT 3.4.1

PHP 5.6.30
MySQL 5.6.35
Linux 2.6.32-042stab120.18
ionCube PHP Loader v4.7.3
Perl 5.10.1
Reply With Quote
  #196  
Old 08-30-2007, 02:54 AM
 
jimbobsquarepants jimbobsquarepants is offline
 

Newbie
  
Join Date: May 2007
Posts: 1
 

Default Re: Newest Products

Hi Guys,

Does anyone know how to limit it so it will only look in one cat?

Cheers
__________________
Version: 4.1.8 Gold
Reply With Quote
  #197  
Old 11-10-2007, 09:52 AM
 
digiemp digiemp is offline
 

Senior Member
  
Join Date: Aug 2007
Posts: 192
 

Default Re: Newest Products

Nice mod, few questions though.

Is there a way to add a link in the category box that says 'Latest Products' or something similar that would take the customer to a category type page that would list all of the recently added products?

I don't want to clutter my homepage but would still like to capture and display all of the newest products in an easy to find place.

Thanks
__________________
version 4.4.2
Reply With Quote
  #198  
Old 11-12-2007, 07:28 AM
 
Lingerieblowout Lingerieblowout is offline
 

X-Adept
  
Join Date: Sep 2003
Location: Annapolis, MD
Posts: 415
 

Default Re: Newest Products

Digiemp ... Do you mean something like on my cart...

www.lingerieblowout.com
__________________
http://www.lingerieblowout.com
Version 4.1.10

http://www.topnichewebsites.com
Version 4.4.5

Michael
Reply With Quote
  #199  
Old 11-12-2007, 02:22 PM
 
digiemp digiemp is offline
 

Senior Member
  
Join Date: Aug 2007
Posts: 192
 

Default Re: Newest Products

Lingerieblowout, YES! That is exactly what I am looking for. Is that an add on or can you give the code for that?

You have a nice looking site by the way.

Thanks
__________________
version 4.4.2
Reply With Quote
  #200  
Old 11-12-2007, 02:32 PM
 
digiemp digiemp is offline
 

Senior Member
  
Join Date: Aug 2007
Posts: 192
 

Default Re: Newest Products

You also have a shop by price function that I haven't been able to set up properly on my site. Actually, there are quite a few things on your site that I'd like to implement but we'll leave it at those two for now.

Thanks.
__________________
version 4.4.2
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions



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 11:58 PM.

   

 
X-Cart forums © 2001-2020