VirtueMart Forum

VirtueMart 2 + 3 + 4 => Virtuemart Development and bug reports => Topic started by: urzh12 on June 09, 2016, 02:25:11 AM

Title: Continue Shopping - 404 Redirect
Post by: urzh12 on June 09, 2016, 02:25:11 AM
I'm using virtue mart bundled with the Horme 3 Joomla template. My "continue shopping" button on any page goes to a 404 redirect page everytime. I have only recently tested this so I BELIEVE this was never work. When it redirects, it is showing this URL localhost/index.php?option=com_virtuemart&view=category&virtuemart_category_id=7&Itemid=101

I read that this is due to an item ID not populating correctly in VirtueMart?
Title: Re: Continue Shopping - 404 Redirect
Post by: GJC Web Design on June 09, 2016, 10:37:41 AM
are u testing on localhost?
Title: Re: Continue Shopping - 404 Redirect
Post by: urzh12 on June 10, 2016, 02:41:45 AM
yes..
Title: Re: Continue Shopping - 404 Redirect
Post by: MagikCommerce on June 10, 2016, 16:10:51 PM
Hello,

You can debug code and customize continue shopping link as expected in following file.

      - /components/com_virtuemart/controllers/cart.php.

There is a following function
     function public function addJS() with code as $continue_link = JRoute::_('index.php?option=com_virtuemart' . $categoryLink);

Thanks
Title: Re: Continue Shopping - 404 Redirect
Post by: urzh12 on June 13, 2016, 15:17:07 PM
Thank you. is this normal localhost browsing behavior though? I just want to make sure I'm actually having an issue
Title: Re: Continue Shopping - 404 Redirect
Post by: urzh12 on June 13, 2016, 15:22:21 PM
What would I replace in the function to just have "continue shopping" button return to homepage?
Title: Re: Continue Shopping - 404 Redirect
Post by: MagikCommerce on June 13, 2016, 16:42:57 PM
Quote from: urzh12 on June 13, 2016, 15:22:21 PM
What would I replace in the function to just have "continue shopping" button return to homepage?


$continue_link = JRoute::_('index.php?option=com_virtuemart' . $categoryLink);

replace with
$continue_link = JURI::base();
Title: Re: Continue Shopping - 404 Redirect
Post by: urzh12 on June 13, 2016, 20:01:55 PM
Thanks - that worked.