Forums / Setting Up Categories, Products, Attributes / Coming Products question....

Coming Products question....

Started by mamat on 13 Dec 2008, 1:30 AM · Views: 4,298

Results 21 to 26 of 26
17 Dec 2008, 5:32 AM
#21
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Coming Products question....

If the time where there to be used and the calculations available for the time itself then it would show ...

I have not tried to take this beyond the date on functionality but gave the full syntax for date and time ...

Linda McGrath
If you have to think ... you haven't been zenned ...

**Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!**

Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here

Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!

17 Dec 2008, 2:05 PM
#22
mamat avatar

mamat

Zen Follower

Join Date:
Nov 2008
Posts:
222
Plugin Contributions:
0

Re: Coming Products question....

Ajeh:

If the time where there to be used and the calculations available for the time itself then it would show ...

I have not tried to take this beyond the date on functionality but gave the full syntax for date and time ...

AHHHHHH!! So I wasn't completely off my rocker! LOL! Thank you!!

crossing fingers that this will be one of the "upgrades" with the new release

Me + Zen = Truehart Treasures

5 Jun 2009, 5:54 AM
#23
softcorpse avatar

softcorpse

Zen Follower

Join Date:
Aug 2004
Posts:
96
Plugin Contributions:
0

Re: Coming Products question....

thanks Ajeh, this works great! ;)

8 Oct 2010, 6:49 PM
#24
softcorpse avatar

softcorpse

Zen Follower

Join Date:
Aug 2004
Posts:
96
Plugin Contributions:
0

Re: Coming Products question....

Urgh, sorry to be a nuisance Ajeh, I quoted you on the wrong code earlier, what I wanted was to know how to keep/add the "add to cart" button to the following code:

$button_check = $db->Execute("select product_is_call, products_quantity, products_date_available from " . TABLE_PRODUCTS . " where products_id = '" . (int)$product_id . "'");
switch (true) {

// cannot be added to the cart
case (zen_get_products_allow_add_to_cart($product_id) == 'N'):
return $additional_link;
break;
case (date_diff($button_check->fields['products_date_available'], date('Y-m-d H:i:s', time())) < 0 ):
$return_button = 'Coming Soon!!<br />Count Down: ' . date_diff($button_check->fields['products_date_available'], date('Y-m-d H:i:s', time())) . ' Days!';
break;

So instead of it saying "Coming Soon!!" it would instead have the add to cart button in its place.

Thanks again.

28 Jan 2011, 11:23 PM
#25
mrspiffy avatar

mrspiffy

New Zenner

Join Date:
Mar 2009
Posts:
29
Plugin Contributions:
1

Re: Coming Products question....

The code presented here breaks listing under 1.3.9.

Any changes to the code that will make it work under 1.3.9?

thanks!

29 Jan 2011, 12:07 AM
#26
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Coming Products question....

Let's pretend that no one has seen this code in a couple three years ...

What code is breaking what and what is the error message that you see in the /cache on the debug log that is generated? :unsure:

Linda McGrath
If you have to think ... you haven't been zenned ...

**Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!**

Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here

Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!