![]() |
How can I get the threadid?
I'm trying to change the URL's for forums and threads in an effort to make them more friendly to search engines like Google. I know there are several hacks with a rather different way of doing this, but I'm giving this method a shot. Right now I'm working on displaying threads by changing the normal URL (http://www.domain.com/forum/showthread.php?s=&threadid=123) to the new one (http://www.domain.com/forum/thread/123). I've almost got it working - here's what I've done so far:
- - - - - - - - - - 1. Created a copy of showthread.php and named the new file simply "thread" without any extension. 2. I then uploaded a .htaccess file in my forum directory containing the following (which will cause Apache to read the new "thread" file as a PHP script). Code:
<Files thread> Code:
<?php After I perform the modifications above, I am able view a thread by using the new URL (http://www.domain.com/forum/thread/123). However, it will *only* show me the first thread on the forum (with a threadid of 1). I know the problem lies in the $threadid=$url_array; line, but I don't know what to change it to to fix it so that it will display whatever threadid number I specify in the URL. How should I change that line to achieve the desired effect? |
Have you had a look at fastforward's hack? It's quite effective. Also, go to vbulletin.com and have a look at filburt1's non-hack solution. Both use .htaccess to remap the path.
|
I was scared away from fastforward's hack, but I just now discovered filburt's. But, alas, his version is giving me trouble, too! Please take a look at my problem if you get a chance. :)
|
You need to get your host to allow you to edit .htaccess files on your server - your host has protected that file.
|
Oh, it is on my own dedicated server, so that shouldn't be a problem. Where can I edit those .htaccess permissions? But, come to think of it, I've never had this problem with .htaccess files before, so it might be something else.
|
Ah, never mind, I figured out my problem! :)
|
All times are GMT. The time now is 10:37 AM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|