Jump to content

SEO Filtering for URL's and more


monkeytooth

Recommended Posts

I have run into a huge road block with my current project, and I can't find any information on this in particular, be it cause I don't know what the method is called or what, I don't know.

 

Right now I am using mod_rewrite to create "friendly" URLs ie: www.domain.com/var/string/var2/string2/

 

Now making these url's working with them, etc isn't the problem. My problem is the data I have to work with. I have a very very very large database that was created who knows when, and updated ever since. biggest problem with it is I don't think anyone ever considered the databases use in either a real world environment or as a web app.

 

So I am stuck with several million records with an unknown count of rows that actually contain what I would call bad markup. I am building a search function that pulls this information out, lists it, and then creates a link like above for it so it can goto a product specific page.

 

So my issue is what would be my best way to filter my outputs so I can create a URL like above. When the key data for the outputs contains characters like ", ', &, (, ), [, ], :, ;, etc.. I mean I can replace them on the initial search side and actually make the link the way I want with str_replace (or similar). But what I am stuck on is the landing page for the product, Now that I have changed the URL to be friendly, how can I reverse it. I can't delimit every bad thing as a - or anything then I end up with URLs like "Title---Of--Product---this-other-thing" and seeing as - normally delimits a space in those type of URLs I can't just reverse it. Anyone have any suggestions?

 

How does wordpress do something like that? I have seen wordpress installs where the URL is "Title-of-Product-this-other-thing" and in the title on the page show "Title of Product & This other thing" is wordpress using to columns maybe? One for SEO link useage, one for actual search?

 

several million records I have, what would someone suggest I do?

Link to comment
https://forums.phpfreaks.com/topic/188312-seo-filtering-for-urls-and-more/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.