OldTimer Posted June 17, 2005 Posted June 17, 2005 Does this make for a better url that can be indexed by search engines. As an example: Before: http://localhost/test/modules/mylinks/viewcat.php?cid=1 After: http://localhost/test/mylinks+viewcat.cid+1.htm Thanks greg Quote
surefire Posted June 17, 2005 Posted June 17, 2005 Search engines have been indexing dynamic urls for some time now. So having variables in your url after '?' won't prevent you from being indexed. There is a theory that a page with a static url will rank better than the same page having a dynamic looking url. There's also a theory about having your desired search terms in the url itself. So if your site is about fishing, you would want. somesite.com/fishing/links/ The short version of 'How to rank well with search engines' goes something like this >Have relevant text links pointing back to your site from high ranking sites >Have lots of content relevant to the search terms >Keep the content fresh Quote
owatagal Posted June 17, 2005 Posted June 17, 2005 For what it's worth, if all your pages are processed on viewcat.php and the only variable you're dealing with is 'cid', you don't have to keep that info in your shorter URL. You can shorten the URL to something like: http://localhost/test/mylinks/1.htm The viewcat.php and the 'cid' get coded into the .htaccess rewrite or scripting language rewrite, whichever you use. In terms of search engine ranking, the two short URLs probably function the same, but for security the second is a little better (the casual user won't know the location of the page you use to process information), and for usability the second is better (the above link looks friendlier/is easier for a visitor to your site to remember. Could be worthwhile.) I know that's not exactly what you're asking here, but it might be worth thinking about if you're going to shorten the URL anyway. Quote
OldTimer Posted June 17, 2005 Author Posted June 17, 2005 Thanks much all for the replies owatagal This was a core hack for xoops. And I was just pleased that I got it to work. I agree that http://localhost/test/mylinks/1.htm looks friendlier than http://localhost/kiss_2/mylinks+viewcat.cid+1.htm and if it's more secure even the better. However my knowledge of all this is very limited. What I did was download the hack. I installed 3 files, simplified_url.php and loadpage.php and the .HTACCESS File I wouldn't have a clue on how to achieve your shorter url. I don't expect you to do this, but if you have the free time (sometime) you can download the hack HERE and maybe give me a clue on what to alter or add, or I could post the files here. thanks greg Quote
owatagal Posted June 18, 2005 Posted June 18, 2005 (edited) OldTimer, I took a quick look at the code--it looks to me like the code is aimed at creating a shorter URL while maintaining maximum flexibility in the program itself, so that the short URL will work regardless of what module is referred to. The viewcat.cid IS actually neccesary to the hack, because those components can change from module to module. I don't know XOOPs well enough to know how any changes would affect that code or updates to the code down the line; I'm afraid if I tried to play with it I'd just break the hack completely Sorry-- I'd stick with the hack they provide, especially since you've already gotten it working! Edited June 18, 2005 by owatagal Quote
OldTimer Posted June 18, 2005 Author Posted June 18, 2005 owatagal, Thank you so much for taking the time to look at that for me. As an after thought, what with over 350 some modules, I would guess they know what they're doing. And like you say, I've already got it working. Again thanks. (oh-what-a-gal) greg Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.