vinod41 Posted December 31, 2013 Posted December 31, 2013 Hi, How can I achieve dynamic product name link in product_info I'm not a coder, but can copy paste ;) here is the current product name line of php code of customized osc. <h1 class="name"><?php echo $products_name; ?></h1> Regards
Jack_mcs Posted December 31, 2013 Posted December 31, 2013 It's unclear to me what it is you want to do. Are you wanting to add a link to some product in your shop to a product page in your shop? Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. All of My Addons Get the latest versions of my addons Recommended SEO Addons
vinod41 Posted January 1, 2014 Author Posted January 1, 2014 Hi, currently individual product info page has Product name, for eg: www.store.com/sony-camera I want to make Product Name link to self page: Sony Camera <h1 class="name"><a href="http://store.com/sony-camera/"><?php echo $products_name; ?></a></h1> <- this is static <h1 class="name"><a href="http://store.com/product-url/"><?php echo $products_name; ?></a></h1> <- need to do it dynamically, I don't know how to do it. Thanks and Happy New Year
Jack_mcs Posted January 1, 2014 Posted January 1, 2014 Still can't follow. You must be talking about the text on the page, even though you mention the url. If so, the text on the page already as the product name changed dynamically. Are you trying to make it a link to itself? Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. All of My Addons Get the latest versions of my addons Recommended SEO Addons
vinod41 Posted January 1, 2014 Author Posted January 1, 2014 Hi, Yes, Link to itself... I've done some copy pasting.. and achieved it. Do let me know if it is correct or need any corrections, as of now product page is perfectly linked to itself. <h1 class="name"><a <?php echo 'title="' . $product_info['products_name'] . ' - ' . my company . '"'; ?> href="<?php echo tep_href_link(FILENAME_PRODUCT_INFO, 'products_id=' . $product_info['products_id'], 'NONSSL') ?>"><?php echo $products_name; ?></span></a></h1> I hope this may be helpful for others too. Regards and Happy New Year
burt Posted January 1, 2014 Posted January 1, 2014 Why do you need a product page to link to itself. Looks like some form of spammy SEO.
vinod41 Posted January 2, 2014 Author Posted January 2, 2014 I'm trying to get the product url for rich snipet -- schema.org
burt Posted January 2, 2014 Posted January 2, 2014 See the SEO Header Tags Reloaded addon for that. http://addons.oscommerce.com/info/8864
Jack_mcs Posted January 2, 2014 Posted January 2, 2014 @@vinod41 You don't need to do that. There is a Rich Snippet tool in your google account that let's you setup everything from there with just a few clicks. Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. All of My Addons Get the latest versions of my addons Recommended SEO Addons
vinod41 Posted January 2, 2014 Author Posted January 2, 2014 My shop is heavily moded, tries header tag seo earlier, something went wrong so I rolled back. In google webmaster I setted up structured data, but it fetches other pages in that group as well and consider as error. So best solution for me is to deploy within site, I'll give a try to SEO Header Tags Reloaded. Is there any edit document available like what to update/edit/replace. as I can't just replace whole file. Regards
burt Posted January 2, 2014 Posted January 2, 2014 Get used to using a compare program such as "beyond compare" or "winmerge". I really dislike "do this do that" instructions as they dumb down the average user, and of course are only useful if your store is not already modified.
Recommended Posts
Archived
This topic is now archived and is closed to further replies.