Wrong page heading for wishlist menuitem
- pulsarinformatique
-
Topic Author
- Offline
Less
More
6 years 1 month ago #324048
by pulsarinformatique
Wrong page heading for wishlist menuitem was created by pulsarinformatique
-- HikaShop version -- : 4.3.0 buisiness
-- Joomla version -- : 3.9.19
-- PHP version -- : 7.3
-- Browser(s) name and version -- : Chrome
Hi
I created a wishlist menu item, set its type to 'wishlist' instead of 'cart' but when I display the page the page heading is still 'cart" even if I set a custom page heading in the 'page display' tab of the menu item !!
did you see that please ?
thanks
-- Joomla version -- : 3.9.19
-- PHP version -- : 7.3
-- Browser(s) name and version -- : Chrome
Hi
I created a wishlist menu item, set its type to 'wishlist' instead of 'cart' but when I display the page the page heading is still 'cart" even if I set a custom page heading in the 'page display' tab of the menu item !!
did you see that please ?
thanks
Please Log in or Create an account to join the conversation.
6 years 1 month ago #324050
by nicolas
Replied by nicolas on topic Wrong page heading for wishlist menuitem
Hi,
That's a bug.
Change the line:
if(!empty($menu) && method_exists($menu, 'getParams') && $menu->link == 'index.php?option=com_hikashop&view=cart&layout=listing') {
to:
if(!empty($menu) && method_exists($menu, 'getParams') && in_array($menu->link, array('index.php?option=com_hikashop&view=cart&layout=show', 'index.php?option=com_hikashop&view=cart&layout=listing'))) {
in the file components/com_hikashop/views/cart/view.html.php and it should work fine.
That's a bug.
Change the line:
if(!empty($menu) && method_exists($menu, 'getParams') && $menu->link == 'index.php?option=com_hikashop&view=cart&layout=listing') {
to:
if(!empty($menu) && method_exists($menu, 'getParams') && in_array($menu->link, array('index.php?option=com_hikashop&view=cart&layout=show', 'index.php?option=com_hikashop&view=cart&layout=listing'))) {
in the file components/com_hikashop/views/cart/view.html.php and it should work fine.
The following user(s) said Thank You: pulsarinformatique
Please Log in or Create an account to join the conversation.
- pulsarinformatique
-
Topic Author
- Offline
6 years 4 weeks ago #324074
by pulsarinformatique
Replied by pulsarinformatique on topic Wrong page heading for wishlist menuitem
Hi
Sorry it doesn't work. the wishlist url is index.php?option=com_hikashop&view=cart&layout=showcart but the line you gave is in the listing() {...} function which is not called when we are in the wishlist page
it may be this file but should be somewhere else in the file ?
thanks
Sorry it doesn't work. the wishlist url is index.php?option=com_hikashop&view=cart&layout=showcart but the line you gave is in the listing() {...} function which is not called when we are in the wishlist page
it may be this file but should be somewhere else in the file ?
thanks
Please Log in or Create an account to join the conversation.
6 years 3 weeks ago #324103
by nicolas
Replied by nicolas on topic Wrong page heading for wishlist menuitem
Hi,
That's not what it should be.
Here is what I have on my end:
monosnap.com/file/2dcDpVcVY8rMDPwnc6o2hTuTRXYcGL
As you can see, the layout parameter is "show" not "showcart" for a "cart display" menu item type.
Try deleting the menu item and recreating it.
I stand by my modification which I've successfully tested on my end before writing my previous message.
That's not what it should be.
Here is what I have on my end:
monosnap.com/file/2dcDpVcVY8rMDPwnc6o2hTuTRXYcGL
As you can see, the layout parameter is "show" not "showcart" for a "cart display" menu item type.
Try deleting the menu item and recreating it.
I stand by my modification which I've successfully tested on my end before writing my previous message.
The following user(s) said Thank You: pulsarinformatique
Please Log in or Create an account to join the conversation.
- pulsarinformatique
-
Topic Author
- Offline
6 years 3 weeks ago - 6 years 3 weeks ago #324117
by pulsarinformatique
Replied by pulsarinformatique on topic Wrong page heading for wishlist menuitem
Hi
there are two locations in the file where I can edit the line you gave
line 160 and line 583
in both case, if I log in on front end (in my example as a super user) and go to the wishlist menu item
if add var_dump("here");die()
just after
if(!empty($menu) && method_exists($menu, 'getParams') && in_array($menu->link, array('index.php?option=com_hikashop&view=cart&layout=show', 'index.php?option=com_hikashop&view=cart&layout=listing'))) {
I never enter the block which is NORMAL since the real url a a wishlist menu item is
index.php?option=com_hikashop&view=cart&layout=showcart
please check the attached screenshot where you can see the url of the wishlist menu item
thanks
Cyril
there are two locations in the file where I can edit the line you gave
line 160 and line 583
in both case, if I log in on front end (in my example as a super user) and go to the wishlist menu item
if add var_dump("here");die()
just after
if(!empty($menu) && method_exists($menu, 'getParams') && in_array($menu->link, array('index.php?option=com_hikashop&view=cart&layout=show', 'index.php?option=com_hikashop&view=cart&layout=listing'))) {
I never enter the block which is NORMAL since the real url a a wishlist menu item is
index.php?option=com_hikashop&view=cart&layout=showcart
please check the attached screenshot where you can see the url of the wishlist menu item
thanks
Cyril
Last edit: 6 years 3 weeks ago by pulsarinformatique.
Please Log in or Create an account to join the conversation.
6 years 3 weeks ago #324127
by nicolas
Replied by nicolas on topic Wrong page heading for wishlist menuitem
Hi,
Try deleting the menu item and recreating it. The URL should then be index.php?option=com_hikashop&view=cart&layout=show and the modification I gave will work.
Try deleting the menu item and recreating it. The URL should then be index.php?option=com_hikashop&view=cart&layout=show and the modification I gave will work.
Please Log in or Create an account to join the conversation.
Less
More
- Posts: 7
- Thank you received: 0
6 years 2 weeks ago #324306
by free2shine@gmx.com
Replied by free2shine@gmx.com on topic Wrong page heading for wishlist menuitem
I have exactly the same problem. Didn't work for me either
Please Log in or Create an account to join the conversation.
6 years 2 weeks ago #324335
by nicolas
Replied by nicolas on topic Wrong page heading for wishlist menuitem
Hi,
So what do you have for the "Link" setting of your menu item ?
Did you apply the modification I recommended ?
So what do you have for the "Link" setting of your menu item ?
Did you apply the modification I recommended ?
Please Log in or Create an account to join the conversation.
Less
More
- Posts: 7
- Thank you received: 0
6 years 2 weeks ago #324364
by free2shine@gmx.com
Replied by free2shine@gmx.com on topic Wrong page heading for wishlist menuitem
Yes I did apply all the recommendations but it didn't change anything. I deleted the menu and recreated it but still no change...
I have now given up and I am using the wishlist module instead (in the article position). That works fine for me.
I have now given up and I am using the wishlist module instead (in the article position). That works fine for me.
Please Log in or Create an account to join the conversation.
Time to create page: 0.146 seconds