Skip to main content

Prevent google indexing cart links

More
11 years 5 months ago - 11 years 5 months ago #200044 by BeLlSiBuB
-- HikaShop version -- : 2.4.0
-- Joomla version -- : Joomla! 3.3.6
-- PHP version -- : 5.3.29
-- Browser(s) name and version -- : Firefox 37.0.2

Hi,
I have found that google keeps indexing component links to carts/wishlists. I don't think it's a good idea to have potential customers clicking on these links to get to the website only to be greeted with virtually a blank page and a messege saying either "You must be logged in to use wishlists" or "Product successfully added to the cart".

Please refer to the hidden URL and attachment.

Is there a way to stop this other than robots.txt please?
Last edit: 11 years 5 months ago by BeLlSiBuB.

Please Log in or Create an account to join the conversation.

More
11 years 5 months ago #200081 by Xavier
Hi,

We just added code on our end based on your request, in the file "administrator/components/com_hikashop/helpers/cart.php", function "getJS()", replace:
Code:
echo '<div style="display:none;">'. '<a rel="{handler: \'iframe\',size: {x: '.$popupWidth.', y: '.$popupHeight.'}}" id="hikashop_notice_box_trigger_link" href="'.hikashop_completeLink('checkout&task=notice&cart_type=cart'.$url_itemid,true).'"></a>'. '<a rel="{handler: \'iframe\',size: {x: '.$popupWidth.', y: '.$popupHeight.'}}" id="hikashop_notice_wishlist_box_trigger_link" href="'.hikashop_completeLink('checkout&task=notice&cart_type=wishlist'.$url_itemid,true).'"></a>'. '</div>';
By:
Code:
echo '<div style="display:none;">'. '<a rel="{handler: \'iframe\',size: {x: '.$popupWidth.', y: '.$popupHeight.'}} nofollow" id="hikashop_notice_box_trigger_link" href="'.hikashop_completeLink('checkout&task=notice&cart_type=cart'.$url_itemid,true).'"></a>'. '<a rel="{handler: \'iframe\',size: {x: '.$popupWidth.', y: '.$popupHeight.'}} nofollow" id="hikashop_notice_wishlist_box_trigger_link" href="'.hikashop_completeLink('checkout&task=notice&cart_type=wishlist'.$url_itemid,true).'"></a>'. '</div>';

Please Log in or Create an account to join the conversation.

More
11 years 5 months ago #200119 by BeLlSiBuB
Thanks for looking at this. I replaced what looked like the code on cart.php using dreamweaver although I could not find the exact text. So I guess I will wait and see what happens with google?

Please Log in or Create an account to join the conversation.

More
11 years 5 months ago #200124 by Jerome
Hi,

The extra text ?

Regards,

Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Please Log in or Create an account to join the conversation.

More
11 years 5 months ago #200176 by BeLlSiBuB
Ahh, I forgot to include "Ignore whitespace". So will this stop google indexing these links or does it do something else?

Please Log in or Create an account to join the conversation.

More
11 years 5 months ago #200213 by nicolas
Yes, it will stop google indexing these links, nothing else.
The following user(s) said Thank You: BeLlSiBuB

Please Log in or Create an account to join the conversation.

Time to create page: 0.218 seconds
Powered by Kunena Forum