View Single Post
  #7  
Old 07-28-2015, 04:16 AM
  totaltec's Avatar 
totaltec totaltec is offline
 

X-Guru
  
Join Date: Jan 2007
Location: Louisville, KY USA
Posts: 5,823
 

Default Re: How to restrict a category by login only

Look in include/login.php I would pass a variable in the URL, from your login link. Like login.php?cat_return=1.

Then test for this in the PHP file, and if found assign a variable to smarty.

Then include a hidden input field in the login form, and populate it with 0 or 1 depending on whether this return value is set.

Then on form submission and successful login, assign the $redirect_url to your special origin point if that hidden input field is populated.
__________________
Mike White - Now Accepting new clients and projects! Work with the best, get a US based development team for just $125 an hour. Call 1-502-773-6454, email mike at babymonkeystudios.com, or skype b8bym0nkey

XcartGuru
X-cart Tutorials | X-cart 5 Tutorials

Check out the responsive template for X-cart.
Reply With Quote