Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

cieto Featured Products v 2.1 beta JUST RELEASE!


emiliano

Recommended Posts

Cieto featured products v 2.1 beta

 

http://www.oscommerce.com/community/contributions,505

 

CHANGELOG

04/20/2003 V2.1 beta

# Now it shows only products from the category you are in!!! Thanks to Dreamscape

# Configuration from admin:

|__Show or not the featured products.

|__Quantity of featured to show.

|__Columns in layout.

|__Words of description to show (from product's description) if short description it's not entered.

 

Please post any bug.

 

cheers

Emiliano

patagonia, argentina

Link to comment
Share on other sites

styleshhets have changed in admin? that?s weir..

 

ok.. i?ll check.. this week i have 3 more exams.. so everything i post will be beta.. so be carefull..

 

 

cheers

emiliano

patagonia, argentina

Link to comment
Share on other sites

some "file:///C|/web3/" are in the code

 

<link rel="stylesheet" type="text/css" href="file:///C|/web3/admin/includes/stylesheet.css">

 

I have this problem adding products now:

admin:

Fatal error: Call to undefined function: tep_get_uploaded_file()

catalog:

1064 - Something is wrong in your syntax

 

and i can seem to get this mod running :(

no featured product with short description are visible in the page.

 

I have use the latest 2.2MS1 and today 2.2CVS... similar problems.

Link to comment
Share on other sites

mm too long to post it..

 

in categories.php search for

 

file:///C|/web3/admin/

 

and delete it everytime you find it... that's the fix for that file.. don't forget to pass the file definitions to filenames.php

 

new instructions to get working the contribution

That's it. So far, the Cieto Featured Products with short descriptions has just been installed, but not activated yet. It's been written that you can, at

will, switch between the Featured Products box, and the What's New box.

To change it to show the Featured Products, just changed the "Display featured products" at the admin -> configuration -> featured products.

There you could set up everything.. not everything but this a great feature!

Then just go and add your products that you want to be featured, in the admin panel.

 

cheers

emiliano

patagonia, argentina

Link to comment
Share on other sites

new fix.. (from deleted post)

 

Cut this from catalog/includes/application_top.php

 

// Featured products mod.

 define('FILENAME_FEATURED', 'featured.php');

 define('FILENAME_FEATURED_PRODUCTS', 'featured_products.php'); // Modify this layout as you wish  

 

and paste it to catalog/includes/filenames.php

 

cheers

emiliano

patagonia, argentina

Link to comment
Share on other sites

it is because the buy now button is using the post method to prevent spiders and bots from runnnig amuck and filling your cart up. I had thought that at least in MS1 this would have been made standard (buy now buttons to post method like the other buttons), but it has not been.

 

towards the bottom of the catalog/includes/application_top.php, you will need to look for the action cases and change the case for "buy now" from:

 

      // performed by the 'buy now' button in product listings and review page

     case 'buy_now' :        if (isset($HTTP_GET_VARS['products_id'])) {

                               if (tep_has_product_attributes($HTTP_GET_VARS['products_id'])) {

                                 tep_redirect(tep_href_link(FILENAME_PRODUCT_INFO, 'products_id=' . $HTTP_GET_VARS['products_id']));

                               } else {

                                 $cart->add_cart($HTTP_GET_VARS['products_id'], $cart->get_quantity($HTTP_GET_VARS['products_id'])+1);

                               }

                             }

                             tep_redirect(tep_href_link($goto, tep_get_all_get_params($parameters)));

                             break;

 

to:

      // performed by the 'buy now' button in product listings and review page

     case 'buy_now' :        if (isset($HTTP_GET_VARS['products_id'])) {

                               if (tep_has_product_attributes($HTTP_GET_VARS['products_id'])) {

                                 tep_redirect(tep_href_link(FILENAME_PRODUCT_INFO, 'products_id=' . $HTTP_GET_VARS['products_id']));

                               } else {

                                 $cart->add_cart($HTTP_GET_VARS['products_id'], $cart->get_quantity($HTTP_GET_VARS['products_id'])+1);

                               }

                             } else {

         if (isset($HTTP_POST_VARS['products_id'])) {

                               if (tep_has_product_attributes($HTTP_POST_VARS['products_id'])) {

                                 tep_redirect(tep_href_link(FILENAME_PRODUCT_INFO, 'products_id=' . $HTTP_POST_VARS['products_id']));

                               } else {

                                 $cart->add_cart($HTTP_POST_VARS['products_id'], $cart->get_quantity($HTTP_POST_VARS['products_id'])+1);

                               }

                              }

        }

                             tep_redirect(tep_href_link($goto, tep_get_all_get_params($parameters)));

                             break;

 

either that or change the featured module to use buy now links instead of buy now forms (if you do not mind a spider/bot running amuck with your cart).

The only thing necessary for evil to flourish is for good men to do nothing

- Edmund Burke

Link to comment
Share on other sites

That was it Josh. I changed the code in application_top.php, and that worked.

 

Thanks for your help Josh!

 

and

 

Thanks again Emiliano!

 

Brandon

Link to comment
Share on other sites

in admin/categories.php

 

replace:

 

        $categories_image = tep_get_uploaded_file('categories_image');

       $image_directory = tep_get_local_path(DIR_FS_CATALOG_IMAGES);

 

by:

 

        $categories_image = new upload('categories_image');

       $image_directory = new upload(DIR_FS_CATALOG_IMAGES);

 

seams to resolve the function problem (when you add the product)

Link to comment
Share on other sites

i really don?t know if that it?s the only change between $Id: categories.php,v 1.138 (the one i post with 2.1beta) and $Id: categories.php,v 1.140(from the last cvs)

 

so i made categories again from v 1.140 (just ask for it [email protected])

 

the buy now button seems to work ok.. if the products has some options (like colors, etc) it sends you to the product info to choose the options.. if the products don?t have any option it just add it to your cart... what kind of problem do you find here?

 

cheers

emiliano

 

pd: another bug?

patagonia, argentina

Link to comment
Share on other sites

:D :D :D

 

1064 - Something is wrong in your syntax

 

this amazing mod don't work if you have PHP 4.0 on your server!!

 

it seems that you need 4.1x and more.

I update my server from 4.0 to 4.3.1. reinstall OSC and install this mod again.

 

Everething work fine now:) this is a great mod, congratulation.

Link to comment
Share on other sites

I've just installed the mod and I'm getting this after adding a new featured product on the admin:

 

Warning: Cannot add header information - headers already sent by (output started at /admin/includes/functions/general.php:2444) in /admin/includes/functions/general.php on line 35

 

And line 35 of general.php is:

 

header('Location: ' . $url);

 

that belongs to the function:

 

function tep_redirect($url) {

   global $logger;



   header('Location: ' . $url);



   if (STORE_PAGE_PARSE_TIME == 'true') {

     if (!is_object($logger)) $logger = new logger;

     $logger->timer_stop();

   }



   exit;

 }

 

The product DOES get inserted anyways, but I don't like the error page.

 

Any ideas?

 

BTW Emiliano, good work!

Link to comment
Share on other sites

This error page keeps showing even in the catalog, when making orders and when trying to login as a user. What changes does this contribution makes to cause this?

 

Please help, thanks!!

Link to comment
Share on other sites

eevrything works great here in a fresh install..

 

login? be carefull you might touch something you don't need to..

header problems.. i don't have it!

ask by mail the new categories.php the contribution won't work without it..

 

cheers

emiliano

[email protected]

patagonia, argentina

Link to comment
Share on other sites

I am now getting this when adding a new product or editing and existing product...

 

1054 - Unknown column 'products_featured_status' in 'field list'

 

insert into products (products_quantity, products_model, products_price, products_date_available, products_weight, products_status, products_featured_status, products_tax_class_id, manufacturers_id, products_date_added) values ('5', 'GDBUTTERFLY', '15.00', null, '5.00', '1', '', '0', '', now())

 

I could not find a products_featured_status in the database, nor could I find where I was to add this during the install. Any ideas?

 

Mike

Link to comment
Share on other sites

I could not find a products_featured_status in the database, nor could I find where I was to add this during the install. Any ideas?

 

ups..that?s a new feature i was working on.. how it arrived to you? i?ll send you the fix next week... sorry but i?ll be at my parents house this weekend..

 

cheers

emiliano

patagonia, argentina

Link to comment
Share on other sites

Thanks for the explanation, emiliano. For a while there, I thought I was going batty. For now, I have commented that line out of admin/categories.php and everyone seems happy.

 

Patiently waiting for the update.....

 

Mike

Link to comment
Share on other sites

  • 1 month later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...