Installed the SEO Mod completely on Beta site

phpBB2 SEO Advanced mod Rewrite support forum.
This mods performs URL rewriting for phpBB, injecting categories, forums and topic titles in their URLs.

Moderator: Moderators


Postby cybersaber » Tue Apr 03, 2007 1:07 pm

umm... dcz dude ... I dont see much content on your domain too.. only folder named boards on your domain and links to other sub-domains.

i like your Idea of 2 different urls ... I mean root domain and forums on sub-domain. It sounds great for SERPS.

I'll tell you what I plan to do:

1. I am writing down articles for Yahoo related things.
2. Tutorials on Yahoo.
3. Some other news about Yahoo.
4. some tools like profile veiwer etc

I have some more sub-domains ready like

downloads.mysite.com
dir.mysite.com

also I am thinking of using wordpress for main site. coz mxBB dont seem to be very good.
cybersaber
 
Posts: 40
Joined: Mon Nov 13, 2006 10:11 am

Advertisement

Postby dcz » Tue Apr 03, 2007 1:30 pm

cybersaber wrote:umm... dcz dude ... I dont see much content on your domain too.. only folder named boards on your domain and links to other sub-domains.


Well, a bit more than that actually : http://www.google.fr/search?q=site%3Awww.phpbb-seo.com VS http://www.google.fr/search?q=site%3Aphpbb-seo.com

400 hundred pages are listed in sub domains, vs 2 780 on the main one (the www).

And this was not always the case, actually, I redirected both forums sub domains because the main domain was starting to be a little light in comparison, too light to be able to support the other sub domains.

So this is for real something to think about, you don't really want your main domain to be treated as a link farm.

The redirections are a bit different if you go for folder or sud domain, when you'll be ready, tell me about your choice so I can provide you with the correct ones to use.

++
Useful links :
SEO Forum || SEO Directory || SEO phpBB || Search
____________________

Liens Utiles :
Forum référencement || Annuaire référencement || Référencement phpBB || Recherche
dcz
Admin
Admin
 
Posts: 19911
Joined: Fri Apr 28, 2006 9:03 pm

Postby cybersaber » Tue Apr 03, 2007 4:59 pm

I think a sub folder would be better.

mysite.com/forums

Also I see a differnt thing ...

your forums urls as:

http://www.phpbb-seo.com/boards/apache- ... rite-vf36/

as directories.

--------------------------------------------

where as mine are like:

http://www.phpbb-seo.com/boards/apache- ... -vf36.html

............... Can I also make have changes to make it display like directory. I mean :

/apache-mod-rewrite-vf36/

and not:
apache-mod-rewrite-vf36.html
cybersaber
 
Posts: 40
Joined: Mon Nov 13, 2006 10:11 am

Postby dcz » Tue Apr 03, 2007 11:19 pm

This you can change in phpbb_seo_class.php :
Code: Select all
      $this->seo_ext = array('cat' => '.html',
         'forum' => '.html',
         'topic' => '.html',
         'user' => '.html',
         'gz_ext' => '',
      );


If you set to :
Code: Select all
      $this->seo_ext = array('cat' => '.html',
         'forum' => '/',
         'topic' => '.html',
         'user' => '.html',
         'gz_ext' => '',
      );


and update the .htaccess accordingly for forums :

Code: Select all
# PAGINATED FORUM
RewriteRule ^phpbb/.*-f([0-9]+)-([0-9]+)\.html$ /phpbb/viewforum.php?f=$1&start=$2 [QSA,L]
# FORUM
RewriteRule ^phpbb/.*-f([0-9]+)\.html$ /phpbb/viewforum.php?f=$1 [QSA,L]


to :

Code: Select all
# PAGINATED FORUM
RewriteRule ^phpbb/.*-f([0-9]+)-([0-9]+)/$ /phpbb/viewforum.php?f=$1&start=$2 [QSA,L]
# FORUM
RewriteRule ^phpbb/.*-f([0-9]+)/$ /phpbb/viewforum.php?f=$1 [QSA,L]


Should work on all forum urls at once.

And the zero duplicate will follow the change by itself.

Then, after the phpBB SEO rewriterules, add :

Code: Select all
#we keep them to kill them ;-)
RewriteRule ^forums.* /new_folder/index.php [L,NC]
RewriteRule ^post-([0-9]*).html&highlight=([a-zA-Z0-9]*) /new_folder/viewtopic.php?p=$1&highlight=$2 [L,NC]
RewriteRule ^post-([0-9]*).* /viewtopic.php?p=$1 [L,NC]
RewriteRule ^view-poll([0-9]*)-([0-9]*)-([a-zA-Z]*).* /new_folder/viewtopic.php?t=$1&postdays=$2&postorder=$3&vote=viewresult [L,NC]
RewriteRule ^about([0-9]*).html&highlight=([a-zA-Z0-9]*) /new_folder/viewtopic.php?t=$1&highlight=$2 [L,NC]
RewriteRule ^about([0-9]*).html&view=newest /new_folder/viewtopic.php?t=$1&view=newest [L,NC]
RewriteRule ^about([0-9]*)-([0-9]*)-([a-zA-Z]*)-([0-9]*).* /new_folder/viewtopic.php?t=$1&postdays=$2&postorder=$3&start=$4 [L,NC]
RewriteRule ^about([0-9]*)-([0-9]*).* /new_folder/viewtopic.php?t=$1&start=$2 [L,NC]
RewriteRule ^about([0-9]*).* /new_folder/viewtopic.php?t=$1 [L,NC]
RewriteRule ^about([0-9]*).html /new_folder/viewtopic.php?t=$1&start=$2&postdays=$3&postorder=$4&highlight=$5 [L,NC]
RewriteRule ^mark-forum([0-9]*).html* /new_folder/viewforum.php?f=$1&mark=topics [L,NC]
RewriteRule ^updates-topic([0-9]*).html* /new_folder/viewtopic.php?t=$1&watch=topic [L,NC]
RewriteRule ^stop-updates-topic([0-9]*).html* /new_folder/viewtopic.php?t=$1&unwatch=topic [L,NC]
RewriteRule ^forum-([0-9]*).html /new_folder/viewforum.php?f=$1 [L,NC]
RewriteRule ^forum-([0-9]*).* /new_folder/viewforum.php?f=$1 [L,NC]
RewriteRule ^topic-([0-9]*)-([0-9]*)-([0-9]*).* /new_folder/viewforum.php?f=$1&topicdays=$2&start=$3 [L,NC]
RewriteRule ^ptopic([0-9]*).* /new_folder/viewtopic.php?t=$1&view=previous [L,NC]
RewriteRule ^ntopic([0-9]*).* /new_folder/viewtopic.php?t=$1&view=next [L,NC]



Then, create a viewforum.php file and put this in it :

Code: Select all
<?php
/**
*
* @package phpBB SEO redirection suite
* @version $Id: phpbb_seo_class.php,v 1.0 2006/12/09 13:48:48 dcz Exp $
* @copyright (c) 2006 dcz - www.phpbb-seo.com
* @http://opensource.org/licenses/gpl-license.php GNU General Public License v2
*
*/
define('IN_PHPBB', true);
$phpbb_root_path = './new_folder/';
include($phpbb_root_path . 'extension.inc');
include($phpbb_root_path . 'common.'.$phpEx);

//
// Start initial var setup
//
if ( isset($HTTP_GET_VARS[POST_FORUM_URL]) || isset($HTTP_POST_VARS[POST_FORUM_URL]) )
{
   $forum_id = ( isset($HTTP_GET_VARS[POST_FORUM_URL]) ) ? intval($HTTP_GET_VARS[POST_FORUM_URL]) : intval($HTTP_POST_VARS[POST_FORUM_URL]);
}
else if ( isset($HTTP_GET_VARS['forum']))
{
   $forum_id = intval($HTTP_GET_VARS['forum']);
}
else
{
   $forum_id = '';
}

$start = ( isset($HTTP_GET_VARS['start']) ) ? intval($HTTP_GET_VARS['start']) : 0;
$start = ($start < 0) ? 0 : $start;

$server_protocol = ($board_config['cookie_secure']) ? 'https://' : 'http://';
$server_name = preg_replace('#^\/?(.*?)\/?$#', '\1', trim($board_config['server_name']));
$server_port = ($board_config['server_port'] <> 80) ? ':' . trim($board_config['server_port']) : '';
$script_name = preg_replace('#^\/?(.*?)\/?$#', '\1', trim($board_config['script_path']));
$script_name = ($script_name == '') ? '' : $script_name . '/';
$root_url = $server_protocol . $server_name . $server_port . '/';
$phpbb_url = $root_url . $script_name;
if (!empty($forum_id)) {
   if ( !empty($db) ) {
      $db->sql_close();
   }
   $url = "viewforum.$phpEx?" . POST_FORUM_URL . "=$forum_id";
   header("HTTP/1.1 301 Moved Permanently", TRUE, 301);
   header("Location: " . $phpbb_url . $url);
   exit();
} else {
   if ( !empty($db) ) {
      $db->sql_close();
   }
   $url = "index.$phpEx";
   header("HTTP/1.1 301 Moved Permanently", TRUE, 301);
   header("Location: " . $phpbb_url);
   exit();
}

?>


and create a viewtopic.php file and put this in it :

Code: Select all
<?php
/**
*
* @package phpBB SEO redirection suite
* @version $Id: phpbb_seo_class.php,v 1.0 2006/12/09 13:48:48 dcz Exp $
* @copyright (c) 2006 dcz - www.phpbb-seo.com
* @http://opensource.org/licenses/gpl-license.php GNU General Public License v2
*
*/

define('IN_PHPBB', true);
// You need here to set the correct path to your forum !!!
$phpbb_root_path = './new_folder/';
include($phpbb_root_path . 'extension.inc');
include($phpbb_root_path . 'common.'.$phpEx);

//
// Start initial var setup
//
$topic_id = $post_id = 0;
$url = '';
if ( isset($HTTP_GET_VARS[POST_TOPIC_URL]) )
{
   $topic_id = intval($HTTP_GET_VARS[POST_TOPIC_URL]);
}
else if ( isset($HTTP_GET_VARS['topic']) )
{
   $topic_id = intval($HTTP_GET_VARS['topic']);
}

if ( isset($HTTP_GET_VARS[POST_POST_URL]))
{
   $post_id = intval($HTTP_GET_VARS[POST_POST_URL]);
}


$start = ( isset($HTTP_GET_VARS['start']) ) ? intval($HTTP_GET_VARS['start']) : 0;
$start = ($start < 0) ? 0 : $start;
if (!$topic_id && !$post_id)
{
   message_die(GENERAL_MESSAGE, 'Topic_post_not_exist');
}
$server_protocol = ($board_config['cookie_secure']) ? 'https://' : 'http://';
$server_name = preg_replace('#^\/?(.*?)\/?$#', '\1', trim($board_config['server_name']));
$server_port = ($board_config['server_port'] <> 80) ? ':' . trim($board_config['server_port']) : '';
$script_name = preg_replace('#^\/?(.*?)\/?$#', '\1', trim($board_config['script_path']));
$script_name = ($script_name == '') ? '' : $script_name . '/';
$root_url = $server_protocol . $server_name . $server_port . '/';
$phpbb_url = $root_url . $script_name;
if ($topic_id) {
   if ( !empty($db) ) {
      $db->sql_close();
   }
   $url = "viewtopic.$phpEx?" . POST_TOPIC_URL . "=$topic_id";
   header("HTTP/1.1 301 Moved Permanently", TRUE, 301);
   header("Location: " . $phpbb_url . $url);
   exit();
} elseif ($post_id) {
   if ( !empty($db) ) {
      $db->sql_close();
   }
   $url = "viewtopic.$phpEx?" . POST_POST_URL . "=$post_id#$post_id";
   header("HTTP/1.1 301 Moved Permanently", TRUE, 301);
   header("Location: " . $phpbb_url . $url);
   exit();
} else {
   if ( !empty($db) ) {
      $db->sql_close();
   }
   $url = "index.$phpEx";
   header("HTTP/1.1 301 Moved Permanently", TRUE, 301);
   header("Location: " . $phpbb_url);
   exit();
}

?>


Note that you'll have to replace new_folder by the rel folder name where phpBB is installed in both the created viewforum.php and viewtopic.php and the .htaccess.

The viewtopic.php and viewtopic.php are meant to be uploaded at the root level, in order to redirect old vanilla url : viewtopic.php?t=xx to new_folder/viewtopic.php?t=xx, allowing the zero duplicate to do its job for these too.

You'll have to check headers for these the same way you did for the zero duplicate, since here it's php redirection, we need to make sure.

++
Useful links :
SEO Forum || SEO Directory || SEO phpBB || Search
____________________

Liens Utiles :
Forum référencement || Annuaire référencement || Référencement phpBB || Recherche
dcz
Admin
Admin
 
Posts: 19911
Joined: Fri Apr 28, 2006 9:03 pm

Postby cybersaber » Wed Apr 04, 2007 10:37 am

Thanx for the redirection code. I am working out on some more content like articles, tutorials, and online tools. Once I complete that .. I'll get everything into action. Plus ... Recently I saw the google dance is in action. so, we'll see some PR changes soon. I hope I'll complete my work before it. Also I am installing some other Mods too.

One question for you: Is it any good if I upgrade to phpbb3.. I see it look much better. Also will phpbb2 templates work on phpbb3. ?? Yep. I know its Beta.
cybersaber
 
Posts: 40
Joined: Mon Nov 13, 2006 10:11 am

Postby dcz » Fri Apr 06, 2007 10:04 am

cybersaber wrote:One question for you: Is it any good if I upgrade to phpbb3.. I see it look much better. Also will phpbb2 templates work on phpbb3. ?? Yep. I know its Beta.


As you said it's beta, and it was clearly stated at phpBB.com that no update procedure will be offered to go from the beta to the first RC.

So, first RC is where to start if you're on a hurry, better to wait for the 3.0 stable if you don't want to have to update possibly many time the forum until it gets officially stable.

++
Useful links :
SEO Forum || SEO Directory || SEO phpBB || Search
____________________

Liens Utiles :
Forum référencement || Annuaire référencement || Référencement phpBB || Recherche
dcz
Admin
Admin
 
Posts: 19911
Joined: Fri Apr 28, 2006 9:03 pm

Postby cybersaber » Fri Apr 06, 2007 1:09 pm

Well I think I'll go on with phpbb2 ... also I guess phpbb2 templates dont work on phpbb3 .. Anyhow I'll go on with phpbb2. Also I need to setup a portal somehow... MxBB doesnt seem that good to me .. can you recommend anything better dcz.

Also isnt there any portal in which custom posting feature is available.

I like instead of displaying all posts on the portal, I can only display the posts I like on the frontpage of the portal.
cybersaber
 
Posts: 40
Joined: Mon Nov 13, 2006 10:11 am

Postby dcz » Sat Apr 07, 2007 11:20 am

To go with phpBB, mxBB is one of the most advanced, but it can be tricky to mod.
EZportal is handy if you do not fear to install mods.

The other solution would be to go for a standalone script, such as drupal, mambo, wordpress as well and etc ...

Some of them have some phpBB modules, like mkportal. You need to test some before you decide.

++
Useful links :
SEO Forum || SEO Directory || SEO phpBB || Search
____________________

Liens Utiles :
Forum référencement || Annuaire référencement || Référencement phpBB || Recherche
dcz
Admin
Admin
 
Posts: 19911
Joined: Fri Apr 28, 2006 9:03 pm

Postby cybersaber » Sat Apr 07, 2007 11:27 am

hey DCZ dude you there. ??

I have tried out ezportal, phpbb easyCMs, php extension, Im portal.

But not really satisified with anyone them. Here's a need:

1. portal which is completely separate from the main forum with its own index file. so that I can easily shift my forums in any folder.

2. Portal having options to post topic only as an article with comment which I approve to be on the frontpage of the portal.

3. With left and right side block. In left side block I can display the Recent Forum Posts and also add more information in it.

Ezportal looks good but it need a redirect to portal.php ... and I dont prefer it. Isnt there a way to get the above told features in any phpbb CMS. Its not really too much I am asking for.

I really need it badly can you help me out DCZ.
cybersaber
 
Posts: 40
Joined: Mon Nov 13, 2006 10:11 am

Postby dcz » Sat Apr 07, 2007 11:39 am

cybersaber wrote:hey DCZ dude you there. ??


:lol:
Useful links :
SEO Forum || SEO Directory || SEO phpBB || Search
____________________

Liens Utiles :
Forum référencement || Annuaire référencement || Référencement phpBB || Recherche
dcz
Admin
Admin
 
Posts: 19911
Joined: Fri Apr 28, 2006 9:03 pm

Postby cybersaber » Sun Apr 08, 2007 5:07 am

seems like you are Mocking at me :roll:
cybersaber
 
Posts: 40
Joined: Mon Nov 13, 2006 10:11 am

Postby dcz » Mon Apr 09, 2007 9:40 am

A bit actually, but don't worry, it's just regular Frenchie sarcastic jokes spirit, did not mean to be rude in any way, just to spend some fun time here :D

Please feel free to gently mock at me if you think it will help us out laughing ;)

Just said this because you where asking this only 7 minutes after I replied.

To make it a bit more clear, I cannot really build your site for you, I guess you'll have to test solutions and make up your mind about what do you want to do.

You're right to proceed carefully, but, at one stage, you should go online, and this means it can be before you'll have the web site you're dreaming of right now.

Little by little ...

++
Useful links :
SEO Forum || SEO Directory || SEO phpBB || Search
____________________

Liens Utiles :
Forum référencement || Annuaire référencement || Référencement phpBB || Recherche
dcz
Admin
Admin
 
Posts: 19911
Joined: Fri Apr 28, 2006 9:03 pm

Postby cybersaber » Mon Apr 09, 2007 9:59 am

Yeah... I love sarcastic jokes spirit. :lol: No problem with me ... actually I enjoy light atmosphere than anything else 8) ... Its really enjoyable to talk with you. And yeah you are telling the truth. I know I'll have to get online sooner coz time is passing away. :roll:

But the thing is that once i use something like a portal or anything ... I wont be able to change it again. Its one important step. and mxBB didnt sound promising to me. I'll try out ezportal. As opensource users I think we all are like a big family and its a part of daily doing to laugh, talk, chat, discuss and help each others :roll: . And dcz you are one of the best guys I have ever known. ;)
cybersaber
 
Posts: 40
Joined: Mon Nov 13, 2006 10:11 am

Postby cybersaber » Mon Apr 09, 2007 6:26 pm

alright I have installed ezportal on the beta site. I'll PM you the details.


I am working on it myself. ezportal only allows announcements to be on the portal page from specific forum. But I need posts from any forum on the index page with a control on which post to allow on index page.

I am looking around for more function. Still if you configure it out somehow please do tell me. I'll be grateful to you. ;) .. :D
cybersaber
 
Posts: 40
Joined: Mon Nov 13, 2006 10:11 am

Postby cybersaber » Tue Apr 10, 2007 7:16 pm

Well for now I dont see much scope or features with any portal mangement system. So, I finally decided to create a plain php page and add in all the content I need manually. Yeah I know its a lot of labour but I dont see any other alternative. People at mx-system are not much active to help in.

Though its a small feature but I dont see any active response from them. So, it finally stuck to me to launch the site without a portal system and in future I wont use any portal ( coz no good support available to any portal ... most of the portal developers are proud of their creation and dont want to help in for a small feature ... lolz Dumbass portal Developers ... ;) ... it doesnt hurts me ) .. Anyhow I am happy the dcz isnt like that. He helps each and everyone who contacts him.

I'll be updating this thread with more updates once I finish the main page of the site.
cybersaber
 
Posts: 40
Joined: Mon Nov 13, 2006 10:11 am

PreviousNext

Return to phpBB2 Advanced mod Rewrite

 


  • Related topics
    Replies
    Views
    Last post

Who is online

Users browsing this forum: No registered users and 2 guests


 
cron