freakystreak Posted September 3, 2015 Share Posted September 3, 2015 Hi guys, I know that may have been asked before but I was just wondering if there was anyway to have URLS that follow this format? Instead of http://www.my-website.co.uk/category/subcategory-c-1.html(as it currently is) to this... http://www.my-website.co.uk/subcategory.html In essence not passing the category_id in the url. I would also like the products to follow this too. Incidentally I'm using 2.3.4 Bootstrap and have installed Header Tags SEO URLS 5 Pro R205. I understand that you need the category_id in some way to match the query but can't you mask it through .htaccess in some way? URL rewriting is not my strongest suite. Cheers. Ah, the world wide web. What a wonderful place. Link to comment Share on other sites More sharing options...
MrPhil Posted September 3, 2015 Share Posted September 3, 2015 It's possible, but labor-intensive and error-prone. SEO URI's keep category numbers, etc. in them because they can 1) be automatically generated, and 2) can be automatically processed (by stripping off everything but the numeric data, and using that to generate the dynamic URI). The category or subcategory name is just redundant "noise" for the benefit of humans. To get rid of the category number, for instance, you would have to keep a mapping in the system between the category name and the category number. You could not automatically handle this in .htaccess*, but would have to pass the category name on to some general lookup PHP code. In addition, names can be ambiguous or duplicate, and you would have to check whether a category name is already in use (more of a problem with product names). If you are willing to do a lot of manual labor, you can write .htaccess code to map category or subcategory names to dynamic URI's, but it will require constant maintenance. * Technically, you could, but it would involve osC rewriting the .htaccess file with each store change. Link to comment Share on other sites More sharing options...
freakystreak Posted September 3, 2015 Author Share Posted September 3, 2015 What is the overall effect of the SEO URLS and Google. Does Google prefer a cut down, shorted url or does it not care? Just so I can explain to my boss as it's he who wants this in the first place Ah, the world wide web. What a wonderful place. Link to comment Share on other sites More sharing options...
MrPhil Posted September 3, 2015 Share Posted September 3, 2015 I haven't heard anything about Google preferring a shorter URI, but then I'm not an SEO expert, so you might want to get another opinion. My point is that whatever minor gain there might be from a slightly shorter URI is likely to be offset by increased problems on your end, from extra labor in creating or maintaining such a scheme and/or processing it, to accidental duplicate names. I'll repeat: a category name without a number would have to be looked up somewhere, to map it to a number for use in osC. With a number, it's easy for .htaccess to grab the number and use it. Note that hyphens (-) in a URI separate keywords, in Google's world, while underscores (_) combine separate words into single terms. So long as your name(s) are hyphen-separated, they should be indexed as keywords. Category letters and numbers should preferably be underscore-separated so that Google doesn't get upset about seeing single letters and numbers such as -c-1 (it should just ignore c and 1 because they're so short/numeric, so in this case it doesn't really matter). Link to comment Share on other sites More sharing options...
freakystreak Posted September 3, 2015 Author Share Posted September 3, 2015 Thanks for the reply. Appreciate it Ah, the world wide web. What a wonderful place. Link to comment Share on other sites More sharing options...
Hotclutch Posted September 3, 2015 Share Posted September 3, 2015 I doubt removing the Ids at the end of the URL would give any advantage at all. Link to comment Share on other sites More sharing options...
MrPhil Posted September 3, 2015 Share Posted September 3, 2015 If it's just a matter of aesthetics, and the Boss doesn't like the -c-1 code "mixed in" with the actual category name (or a product name), I would think that the SEO code could be modified to move it to the false directory: http://www.my-website.com/category-1/category_name.html That's a possibility. It would be a modification of both the PHP code producing the link, and the .htaccess code to create the dynamic URI. Link to comment Share on other sites More sharing options...
♥toyicebear Posted September 4, 2015 Share Posted September 4, 2015 You would have to remove Header Tags SEO URLS 5 Pro R205 and create your own clean url modifications. Its fully possible I have made that for several clients. There are a few addons for "clean" urls you can look at, but they are all fairly old. SEO-G - http://addons.oscommerce.com/info/5080 Search Engine Friendly Url's - http://addons.oscommerce.com/info/2796 Basics for osC 2.2 Design - Basics for Design V2.3+ - Seo & Sef Url's - Meta Tags for Your osC Shop - Steps to prevent Fraud... - MS3 and Team News... - SEO, Meta Tags, SEF Urls and osCommerce - Commercial Support Inquiries - OSC 2.3+ How To To see what more i can do for you check out my profile [click here] Link to comment Share on other sites More sharing options...
clustersolutions Posted September 4, 2015 Share Posted September 4, 2015 For that kinda trouble...Magento? Woocommerce? Link to comment Share on other sites More sharing options...
Hotclutch Posted September 4, 2015 Share Posted September 4, 2015 This is really not worth the effort, unless your IDs are running into the tens of thousands. Google in many cases does not even show the url anymore in listings. Link to comment Share on other sites More sharing options...
freakystreak Posted September 4, 2015 Author Share Posted September 4, 2015 Thanks guys. I will definitely take a look at your suggestions toyicebear. Ah, the world wide web. What a wonderful place. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.