The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
Spider Friendly URL hack Details »» | |||||||||||||||||||||||||
I've started using better URLs for the search engines and I'm looking for some advice on what templates to modify. I also don't have the multi page part working right currently so I could use some help on that.
I haven't figured out the part to go to specific posts quite yet but I thought I'd share what I have so far. URLs for the threads now look like this: http://www.iamnotageek.com/t-76948.html Insert this into your .htaccess file in your forum base directory. Code:
RewriteEngine on RewriteRule ^t-([0-9]+) showthread.php?t=$1 [L] If that shows the thread properly THEN go into your admincp and use the template search function. Do a search for showthread.php and start editing those templates to send people to these new URLs. Don't modify things like the next page links. This could potentially raise CPU usage quite a bit but my site pulls a decent amount of people per day and I'm not noticing much of a spike in CPU usage. This can also be done for forums. I've done it here http://iamnotageek.com/f-46.html If I can get the next page system working right I'll get the full instructions together. Show Your Support
|
Comments |
#32
|
|||
|
|||
using the names in the URL is simple... Basically have the rewrite completely ignore the text after the f-28 then you can have f-28-Iamthekingof_myownworld.html if you want and all that it cares to parse is the f-28
|
#33
|
|||
|
|||
Well it will spider much better if the forum names where in the URL.
http://www.google.com/search?hl=en&i...=Google+Search http://www.google.com/search?hl=en&l...ro&btnG=Search How could i do this without always havin to hack the .htacess file every time. |
#34
|
|||
|
|||
http://www.sportsrant.com/forums/f28...im-angels.html
http://www.sportsrant.com/forums/f29...e-orioles.html http://www.sportsrant.com/forums/f31...h-pirates.html These are examples from my forum, using the mod from Dani's tutorial with a few corrections. This is the only content that is in my .htaccess file: Quote:
It is really easy to put in place Is this what you were asking, so you dont have to change the htaccess everytime you add or delete a forum |
#35
|
|||
|
|||
its this line here that does it
RewriteRule ^f([0-9]+)-(.*).html$ forumdisplay.php?forumid=$1 [L] the * means don't do any form of parsing of that |
#36
|
|||
|
|||
Thanks, i got it to work. Now im making it so threads are in the html. Like http://mysite.com/t-71.Spider-Friendly-URL-hack.html. and having it cut it out with long URLS.
|
#37
|
||||
|
||||
what i have to do im Templates??
Template forumhome_lastpostby Code:
<a href="showthread.php?$session[sessionurl]goto=newpost&t=$lastpostinfo[lastthreadid]" title="<phrase 1="$lastpostinfo[lastthread]">$vbphrase[go_first_unread_in_thread_x]</phrase>"><strong>$lastpostinfo[trimthread]</strong></a> <a href="showthread.php?$session[sessionurl]goto=lastpost&t=$lastpostinfo[lastthreadid]"><img class="inlineimg" src="$stylevar[imgdir_button]/lastpost.gif" alt="$vbphrase[go_to_last_post]" border="0" /></a> |
#38
|
|||
|
|||
Hi all, i´ve like this hack.
A little question, i´ve replace the link on a forumhome last topics template: OLD WAS <a href="showthread.php?$session[sessionurl]threadid=$thread[threadid]" title="$thread[preview]"><strong>$thread[title]</strong></a> <em>$vbphrase[last_post]:</em> $thread[date] NEW CODE <a href="t-$thread[threadid]-$thread[title].html" title="$thread[preview]"><strong>$thread[title]</strong></a> <em>$vbphrase[last_post]:</em> $thread[date] Problem, the thread title was: Willkommen, gabby He makes: t-9020-Willkommen,%20gabby!.html I don´t like ",%" on the url Psycho Beat Project would be: t-9019-Psycho%20Beat%20Project.html I want replace signs like "" "," "." or "/20" with a "-" sign. Example t-9019-Psycho-Beat-Project.html or much better Psycho-Beat-Project.html Update: I´ve created a $ttitle with replace string the signs like "!"... I think it´s not the best way, because i must replace also $lastthread strings like "!" on the forumhome... |
#39
|
|||
|
|||
this is one of the most best hack i ever seen
i will start using it right now and i hope we could do the rest also so owre site's will be all from a to z HTML pages i have a website that i made is spider friendly it's 4images see this http://www.racing4e.com/index.html |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|