CMS MADE SIMPLE FORGE

Cart2

 

[#11204] param viewcartpage is not used for RedirectContent (but destpage is)

avatar
Created By: Florian Verdet (fvg)
Date Submitted: Wed Nov 02 20:03:13 -0400 2016

Assigned To:
Version: 1.2.2
CMSMS Version: 2.1.5
Severity: Minor
Resolution: None
State: Open
Summary:
param viewcartpage is not used for RedirectContent (but destpage is)
Detailed Description:
(Is a kind of follow-up to bug #10734
http://dev.cmsmadesimple.org/bug/view/10734 )

File: Cart2/action.viewcart.php

Lines 34ff handles $params['viewcartpage'] and assigns to $destpage. Well.

But lines 47 and 162 do
  $this->RedirectContent($returnid);
without using $destpage.

$destpage is only used for mact-returnid hidden form setting (via
CGCreateFormStart), which delays viewcartpage's effect by one step.

I would expect action.viewcart to behave similarly to action.default
(addtocart).
See modules/Cart2/action.default.php lines 312ff using $params['destpage'] for
RedirectContent.

(As the reporter of the other bug, I use with AJAX for getting just some JSON
without whole-page markup...)


History