Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

"Prices for Logged-In Users Only" is NOT functioning correctly


Guest

Recommended Posts

Hi and thank you all.

 

My website is for Wholesale Not for end buyers. So we don?t want our visitors to see the price until they logged in then they can see and purchase.

 

I have been reading "Prices for Logged-In Users Only" and I have did what it was in the last modification contribution page: http://www.oscommerce.com/community/contributions,601

And in the loadable attachment, NOT in below code because I don?t have such code in my PHP! For some reason! it didn?t came with it.

 

Search at catalog/includes/application_top.php on Line 354:

 

// customer adds a product from the products page

case 'add_product' :

// if the customer is not logged on, redirect them to the login page

if (!tep_session_is_registered('customer_id')) {

$navigation->set_snapshot();

tep_redirect(tep_href_link(FILENAME_LOGIN, '', 'SSL'));

}

 

And add afterwards:

 

// Neu hinzugef?gt

case 'buy_now' :

// if the customer is not logged on, redirect them to the login page

if (!tep_session_is_registered('customer_id')) {

$navigation->set_snapshot();

tep_redirect(tep_href_link(FILENAME_LOGIN, '', 'SSL'));

}

 

 

And part of this contribution attached file works but there is still a problem in this code.

 

Here is my website: http://store.supremesilver.com/index.php

 

If you pay attention to my website you are able to browse the site without seeing price. And this is great.

Whenever you want to add to cart it sends you to Login and this is great too.

After you logged in then there are problems:

 

Problem: When you click on "Add to Chart" in this link http://store.supremesilver.com/index.php

 

You will get "Your Shopping Cart is empty!" at this link: http://store.supremesilver.com/shopping_cart.php

 

BUT

 

when you click on "Details" then when you click on "Add to cart" button then it does adds the item to shopping cart..

 

The Problem here is: why when you click on "Add to cart" before you click on "Details" it doesn?t add an item to cart but after you click on Details then it does?

 

 

Thanks for any help to solve this problem.

 

 

Errol

Link to comment
Share on other sites

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...