URL modification help

Need some coding help with a MOD or tweak you are working on? - Ask here.
Forum rules
Ask for support specifically regarding coding help with phpBB3.
Not for generic usability questions or support.

URL modification help

Postby pallindrome » 06 Aug 2012, 23:07

Hello friends I am trying to convert my urls from :
Code: Select all
www.yoursite/viewforum.php?f=43
to
Code: Select all
www.yoursite/43
is it possible ?
pallindrome
Cadet IV
Cadet IV
 
Posts: 49
Joined: 26 Mar 2011, 00:58
Gender: Male
phpBB Knowledge: 5


Re: URL modification help

Postby pallindrome » 08 Aug 2012, 02:47

Can any one help me please ?
pallindrome
Cadet IV
Cadet IV
 
Posts: 49
Joined: 26 Mar 2011, 00:58
Gender: Male
phpBB Knowledge: 5

Re: URL modification help

Postby Sniper_E » 08 Aug 2012, 06:17

No, you can not do that. The viewforum.php has to be in the url.
Image
No is NEVER an Option and NEVER is the only Option when it comes to Giving Up!
User avatar
Sniper_E    
STG Jedi Master
STG Jedi Master
 
Posts: 6983
Joined: 31 May 2006, 06:29
Location: Shreveport, LA
Favorite Team: The STG Team
Gender: Male
phpBB Knowledge: 6

Re: URL modification help

Postby pallindrome » 10 Aug 2012, 21:35

Hmmm i see, ok thanks for your help :)
pallindrome
Cadet IV
Cadet IV
 
Posts: 49
Joined: 26 Mar 2011, 00:58
Gender: Male
phpBB Knowledge: 5

Re: URL modification help

Postby Handyman » 13 Aug 2012, 18:28

It is possible with htaccess modifications, but you still need a plan to take into consideration both the viewforum and viewtopic pages to show the different forums and topics.
As an example, you could use this format:
this: viewforum.php?f=43
would become this: /viewforum/43
and this: viewtopic.php?t=539
would become this: /viewtopic/539

Or you could use a format like:
/f43
/t539
Please contact me if you have any news to submit to SCOFF News.
SCOFFing at the candidates while you sleep.
My Mods || My Mod Queue
Image
User avatar
Handyman    
Rear Fleet Admiral
Rear Fleet Admiral
 
Posts: 7454
Joined: 08 May 2006, 04:45
Location: Where no man has gone before!
Favorite Team: Seattle Seahawks
Gender: Male

Re: URL modification help

Postby pallindrome » 02 Sep 2012, 21:07

Thank you very much handy man. Can you give an example of codes on how to do it ?
pallindrome
Cadet IV
Cadet IV
 
Posts: 49
Joined: 26 Mar 2011, 00:58
Gender: Male
phpBB Knowledge: 5

Re: URL modification help

Postby Handyman » 03 Sep 2012, 12:38

If you download the SEO URL's MOD, you'll be well on your way there.
It has a few outstanding issues, but you'll at least be able to see 95% of what's needed to make it work.
If you understand the code a bit, you could modify it so that instead of having the topic or forum name in the URL, you could just use the forum or topic id's. (BTW, see the link for the SEO URL's MOD).
Please contact me if you have any news to submit to SCOFF News.
SCOFFing at the candidates while you sleep.
My Mods || My Mod Queue
Image
User avatar
Handyman    
Rear Fleet Admiral
Rear Fleet Admiral
 
Posts: 7454
Joined: 08 May 2006, 04:45
Location: Where no man has gone before!
Favorite Team: Seattle Seahawks
Gender: Male

Re: URL modification help

Postby pallindrome » 24 Sep 2012, 04:13

Thanks bro I will try it out :)
pallindrome
Cadet IV
Cadet IV
 
Posts: 49
Joined: 26 Mar 2011, 00:58
Gender: Male
phpBB Knowledge: 5


Return to phpBB3 Coding Assistance

Who is online

Users browsing this forum: No registered users and 16 guests

cron