| |
|
| :: |
| Author |
Message |
korb
Joined: 21 Aug 2008 Posts: 36
|
Posted: Tue Oct 28, 2008 11:35 am Post subject: forum/domain.com instead of http://domain.com/forum |
|
|
Exactly like that: I would like to make /forum/ to be the prefix and not the "suffix".
Is it possible by modifying htaccess? How?
Thanks for any reply |
|
|
| Back to top |
|
 |
|
 |
dcz Administrateur - Site Admin

Joined: 28 Apr 2006 Posts: 15414
|
Posted: Sun Nov 02, 2008 12:43 pm Post subject: Re: forum/domain.com instead of http://domain.com/forum |
|
|
This cannot be done only with the .htaccess.
But it's rather easy, you'd need to create a sub domain (contact your host to know how to do this in your particular case), and then either set it to be linked to the forum/ dir or, move the content of the forum/ dir in the newly created sub domain.
Once done, you'll need to update phpBB's config accordingly for server name and script path.
The server name should now be set to the sub domain (subdomain.example.com), and the path to "/" (since phpBB would now be installed in the sub domain's root, not in "forum/").
While you'd be at it, you should make sure that the cookie domain is as well set properly, should be ".example.com" with the dot "." and without the quotes
All these config update should be done either using phpMyadmin (direct edit) or, in the regular phpBB's acp, but you'd need to use the old domain path to reach it until it would be updated.
Do not forget to clear cache once done.
Another thing you should be aware of is redirecting, since you would change all your forums urls while doing so.
The easiest to do this would be if you could leave phpBB where it physically was, because this way, both example.com/forum and sub.example.com would lead to the same place, where you would be able to perform the redirect (with the www prefix redirection method n°2) and the zero duplicate in case you are using url rewriting.
Another thing to keep in mind while creating sub domains is that it's not necessarily a good thing SEO wise, it's really worth it when the main domain and the sub domain are big and active enough, it's not really good for example if your main domain is for now composed of few pages plus the forum, because it would end up to be tiny once the forum will have been transferred to the sub domain. And the new sub domain will as well be less big than the site plus the forum.
So this is something to think about.
++ |
_________________ Useful links :
SEO Forum || SEO Directory || SEO phpBB || SEO phpBB3 || Search
____________________
Liens Utiles :
Forum référencement || Annuaire référencement || Référencement phpBB || Référencement phpBB3 || Recherche |
|
| Back to top |
|
 |
korb
Joined: 21 Aug 2008 Posts: 36
|
Posted: Thu Nov 06, 2008 2:27 pm Post subject: Tried but is it important? |
|
|
Hi dcz,
Thank you for sharing this to me!
The problem is that my phpBB installation is bridged to Joomla if you remember my case.
So I already did as you said a subdomain, copied files there, OK!
So now I need a solution for the subdomain solution you explain and the bridge with Joomla.
BUT!!
The bridge asumes that I am using a folder inside Joomla root to provide user sync and authentification integration. The bridge wants to know the name of the phpBB3 installation folder like this "forum", but because I am moving it to a subdomain, I don't know how to do this...I guess I have to tell him the subdomain link:
subdomain.domain.com
as the folder?
I will try to get help on rocketwerx support forum.
Ok now what about .htaccess?
This is the htaccess code provided by the bridge developers for inserting in Joomla htaccess file:
| Code: |
########## Begin - RokBridge - phpBB3 edition SEF Section
#
# The following rules need to be added to the Joomla! 1.5
# .htaccess file to allow the bridge to work in SEF mode.
# See also the bridge configuration.php file for details.
# Dont' use the rule below, it's needs optimisation and
# will not work correctly
# RewriteRule ^/forum/distribution/ forum/index.php [F,L]
# Place the below 4 lines in the Joomla! .htaccess file you
# can find in your Joomla! 1.5 root directory.
#
# The lines should be placed before the Joomla! Core SEF
# section.
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !^/index.php
RewriteRule ^/forum/ forum/index.php [L]
########## End - RokBridge - phpBB3 edition SEF Section
|
I think I will delete this code from Joomla htaccess, and I think it;s not ok. The rewrite rule does not generate routable links for phpBB forums. I need some assistance building this htaccess.
| Code: |
Not Found
The requested document was not found on this server.
|
I tryed as suggested
example:
| Code: |
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !^/index.php
RewriteCond %{HTTP_HOST} !^www\.domain\.ro$ [NC]
RewriteCond %{HTTP_HOST} !^(www|forum)\.domain\.ro$ [NC]
|
Thanks for any reply DCZ,
Danny |
|
|
| Back to top |
|
 |
dcz Administrateur - Site Admin

Joined: 28 Apr 2006 Posts: 15414
|
Posted: Sun Nov 09, 2008 10:00 am Post subject: Re: forum/domain.com instead of http://domain.com/forum |
|
|
Well, the simplest way of keeping the interaction between joomla and phpBB would be to install your sub domain within the folder where phpBB3 was in the main domain. This is usually easy to do, just a matter to changing the sub domain target folder (in the VHOST for dedicated server, in the control pannel for shared one providing with the option). You'd have something like :
| Code: | www/<=>www.example.com => joomla
www/forum/ <=> forum.example.com => phpbb3 |
phpBB3 could thus be reached through both -www.example.com/forum/ and forum.example.com, but this would not be a problem, since the zero dupe and the www prefix redirection would make sure that only forum.example.com is used.
Of course, this would mean that phpBB should then be installed in forum.example.com's root (eg no script path).
This way, the path from joomla to phpBB would not change and the bridge should work without any more modification than making sure you set up the cookie domain proper in both joomla and phpBB3 (eg:.example.com with the dot).
It is possible though, that you'll have to tweak joomla a bit in case it is linking to phpBB, like on a last active topic list, because it could continue to use the old domain at first for this.
But beside, everything should work.
++ |
_________________ Useful links :
SEO Forum || SEO Directory || SEO phpBB || SEO phpBB3 || Search
____________________
Liens Utiles :
Forum référencement || Annuaire référencement || Référencement phpBB || Référencement phpBB3 || Recherche |
|
| Back to top |
|
 |
korb
Joined: 21 Aug 2008 Posts: 36
|
Posted: Sun Nov 09, 2008 3:39 pm Post subject: OK |
|
|
So you suggest I should create a folder structure like a domain inside phpBB installation folder, and move the installation files and folders inside httpdocs folder?
But then, what about Joomla htaccess file. It should route to folder with a different rewrite roule.
I really have to try, I have no choice. I'll get back with news.
Danny |
|
|
| Back to top |
|
 |
SeO Administrateur - Site Admin

Joined: 15 Mar 2006 Posts: 4551
|
Posted: Sun Nov 09, 2008 3:47 pm Post subject: Re: forum/domain.com instead of http://domain.com/forum |
|
|
Following this way, phpBB would not change it's physical location, nothing to move, just the target dir of the sub domain, which have to be set up to match the current phpBB physical install dir.
This way both domain would work within the phpBB dir, but only one would be actually used within thanks to the redirections. |
_________________ phpBB SEO || SEO Forum || Forum Référencement
GYM Sitemap & RSS for phpBB3 has been released ! || GYM Sitemap & RSS for phpBB3 est disponible ! |
|
| Back to top |
|
 |
|
|
| Navigation |
Similar Topics |
|
|
|
|
|
|
|