Zen Cart Logo
Forums / All Other Contributions/Addons / re-coding success message to work with Magic SEO URL?

re-coding success message to work with Magic SEO URL?

Locked

Views: 1,754

Results 1 to 4 of 4
This thread is locked. New replies are disabled.
11 Nov 2007, 11:23 PM
#1
lankeeyankee avatar

lankeeyankee

Totally Zenned

Join Date:
Jan 2007
Posts:
1,514
Plugin Contributions:
1

re-coding success message to work with Magic SEO URL?

I found out that if you have the "display cart after adding product" option set to false in configuration/my store when you are using Magic SEO URL the "success" message won't display. The author told me that it is caused by automatic redirection from original URLs and that the only way around it is some re-coding of the zencart core code due to problems with session variables.

Is this something that can be done relatively easily or does it involve a major rewrite of core code? I have been finding with test users of our site that the "success" message is important to avoid confusion of whether or not the product has been added to the cart, so I really want to keep this feature. If it is too difficult or involved, can anyone suggest an alternative to notify the user that the item has been added to the cart? It shows up in the shopping cart sidebox of course but sometimes that isn't obvious and you have to keep the not-too-computer-savvy users in mind.:smile:

Thanks!

Matt

12 Nov 2007, 1:20 AM
#2
Kim avatar

Kim

Obaa-san

Join Date:
Jun 2003
Location:
West Coast, North America
Posts:
26,627
Plugin Contributions:
0

Re: re-coding success message to work with Magic SEO URL?

I found out that if you have the "display cart after adding product" option set to false in configuration/my store when you are using Magic SEO URL the "success" message won't display. The author told me that it is caused by automatic redirection from original URLs and that the only way around it is some re-coding of the zencart core code due to problems with session variables.

Sorry- but it isn't our problem or job to rewrite to code to work with an outside add on.

12 Nov 2007, 3:19 PM
#3
lankeeyankee avatar

lankeeyankee

Totally Zenned

Join Date:
Jan 2007
Posts:
1,514
Plugin Contributions:
1

Re: re-coding success message to work with Magic SEO URL?

Kim:

Sorry- but it isn't our problem or job to rewrite to code to work with an outside add on.

Thanks for the helpful advice!!:blink:

I wasn't asking you to rewrite the code, just for opinions about what it would take to get it to work so I could see if it's feasible to get a rent-a-coder to do it without it costing a big chunk of change. I would of course pass along the code to the community. Or perhaps someone could offer a solution to do a success notification in a different way which would be easier to implement and without changing any core code, such as an if-then type of statement. If add to cart buton is clicked then display this message. But I am still in php 101 so I am speaking from an ignorant viewpoint!:smile:

Matt

27 Jan 2008, 7:38 PM
#4
iray avatar

iray

New Zenner

Join Date:
Jun 2007
Posts:
72
Plugin Contributions:
0

Re: re-coding success message to work with Magic SEO URL?

Hello Mat,

Very simple solution has been found. As I mentioned in other thread some time ago, it is necessary to modify ZenCart sources in order to fix this issue.
Exact required step is following:

Please open includes/classes/message_stack.php

Find:

$_SESSION['messageToStack']= '';

Replace with:

$_POST['msuSaveMessages'] = true;
$_SESSION['messageToStack']= '';