phpBB SEO
Boards
Directory  
SEO  
Downloads
  phpBB SEO : Search Engine Optimization, Directory, Forums  
Index
Forums
Annuaire
Référencement
Télécharger
 
  Search Rechercher
    Register
Username :  Password :  Log me on automatically each visit  
S'enregistrer  
 
   
Need REALLY Good Coding Skills

 
Post new topic   Reply to topic    phpBB SEO » SEO Forum  » phpBB3 SEO TooLKit  » phpBB SEO Premod
::  
Author Message
divinemanwah



Joined: 01 Apr 2008
Posts: 28

Need REALLY Good Coding SkillsPosted: Tue Jul 01, 2008 2:10 am    Post subject: Need REALLY Good Coding Skills

hello, so far i've been using phpbb seo premod for quite a long time now.
and now i've read about this topic of placing the last 5 topics here:

http://www.phpbb.com/community/viewtopic.php?f=72&t=952855

my only problem is that the links that it can generate are php queries like ...forums/viewtopic.php?f=3455

how can i transform it to links like those of PHPBB SEO? (...forums/FORUM_NAME/TOPIC_TITLE/TILE.html)

here are the codes that i used:


connect.php
Code:
    <?
        require_once("forums/config.php");
        $connection = mysql_connect('MY_SQL_HOST', $dbuser, $dbpasswd) or die(mysql_error());
        mysql_select_db($dbname, $connection) or die(mysql_error());
    ?>


test.php
Code:
    <?
        require_once("connect.php");
       
        $forumQ=mysql_query("SELECT topic_id, forum_id, topic_title, topic_last_post_time FROM phpbb_topics WHERE topic_approved=1 ORDER BY topic_last_post_time DESC LIMIT 10");
        while($forumRow = mysql_fetch_row($forumQ)){
           
            $date=date('D M d, Y g:i a', $forumRow[3]);

            echo $number."<a href=forums/viewtopic.php?f=".$forumRow[1]."&t=".$forumRow[0].">".$forumRow[2]."</a><br>".$date."<br><br>";
        }
    ?>



if you want to look, here is my url to the test file:
www.itspot.co.cc/testest.php
Back to top
SeO
Administrateur - Site Admin
Administrateur - Site Admin


Joined: 15 Mar 2006
Posts: 3477

Need REALLY Good Coding SkillsPosted: Tue Jul 01, 2008 6:46 am    Post subject: Re: Need REALLY Good Coding Skills

The easiest way to do so will be to parse GYM Sitemaps RSS Feeds, otherwise you'll have to share more than just the db connect to do the rewriting with all options.

GYM 2.0.B1 is going to be released soon Wink

_________________
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
divinemanwah



Joined: 01 Apr 2008
Posts: 28

Need REALLY Good Coding SkillsPosted: Fri Jul 04, 2008 11:23 am    Post subject: Re: Need REALLY Good Coding Skills

yes, i know that using the easy way is very convenient, but can someone please help me here so i can understand PHP much better?

i saw this post and i think it was successful in rewriting it's URLs.

http://www.phpbb-seo.com/boards/phpbb-seo-premod/discussions-vt2784.html

codes anyone?
Back to top
HB
phpBB SEO Team
phpBB SEO Team


Joined: 16 Oct 2006
Posts: 808

Need REALLY Good Coding SkillsPosted: Fri Jul 04, 2008 1:20 pm    Post subject: Re: Need REALLY Good Coding Skills

It's the same code here with $topic_data substituted for the variables in your query (topic id, topic type, topic title, forum id, forum title). In other words, fill in these values:

Code:
$topic_data['forum_id'] = ...;
$topic_data['forum_name'] = ...;
$topic_data['topic_id'] = ...;
$topic_data['topic_title'] = ...;
$topic_data['topic_type'] = ...;

And copy the rest of the code from the post cited above. Your query has most of the values you need already. Add the necessary columns from phpbb_topics and probably a join (SELECT t.topic_id... f.forum FROM phpbb_topics t, phpbb_forums f WHERE t.forum_id = f.forum_id AND ...).

BTW, I recommend reading the phpBB code and copying where possible. There are many code excerpts that are very similar to what you want to do (probably in viewtopics.php). For example, the global $db is already initialized and connected, the table names are predefined as constants, etc.

_________________
Dan Kehn
Back to top
Visit poster's website
divinemanwah



Joined: 01 Apr 2008
Posts: 28

Need REALLY Good Coding SkillsPosted: Fri Jul 04, 2008 1:44 pm    Post subject: Re: Need REALLY Good Coding Skills

ok, sorry but i'm really confused now..
i don't know if i can use this code on a static page like on my site...
please take a look at www.itspot.co.cc
in my index page, there is a "Latest News" box with the first code (but it contains links without SEO)...
any help?
thanks!
Back to top
divinemanwah



Joined: 01 Apr 2008
Posts: 28

Need REALLY Good Coding SkillsPosted: Thu Jul 24, 2008 1:54 pm    Post subject: Re: Need REALLY Good Coding Skills

anyone? Sad
Back to top
dcz
Administrateur - Site Admin
Administrateur - Site Admin


Joined: 28 Apr 2006
Posts: 14131

Need REALLY Good Coding SkillsPosted: Thu Jul 24, 2008 2:03 pm    Post subject: Re: Need REALLY Good Coding Skills

The easiest way to do this would be to use the GYM sitemaps & RSS feeds, you could easily grab the links from the feeds, for example using magpie.

More details here : http://www.phpbb-seo.com/boards/gym-sitemaps/discussions-vt1078.html#8329

++

_________________
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
Visit poster's website
divinemanwah



Joined: 01 Apr 2008
Posts: 28

Need REALLY Good Coding SkillsPosted: Fri Jul 25, 2008 4:33 am    Post subject: Re: Need REALLY Good Coding Skills

yes, but i think that inculdes also the latest replies too.
Back to top
dcz
Administrateur - Site Admin
Administrateur - Site Admin


Joined: 28 Apr 2006
Posts: 14131

Need REALLY Good Coding SkillsPosted: Fri Jul 25, 2008 1:10 pm    Post subject: Re: Need REALLY Good Coding Skills

No, you can chose the feed you want, with or without content, first or last post url.

And the url will be properly rewritten without further efforts.

++

_________________
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
Visit poster's website
Professional
PR1
PR1


Joined: 07 Apr 2008
Posts: 194
Location: 1/2 of the World

Need REALLY Good Coding SkillsPosted: Sat Jul 26, 2008 8:08 am    Post subject: Re: Need REALLY Good Coding Skills

hi i want some help for creat a code.
i installed a ajax chat but it had some problem that after login it some times log out ,and in instruction i shoud add this code:
Code:
if (!$user->data['is_registered'])
{
redirect(append_sid("{$phpbb_root_path}ucp.$phpEx", 'mode=login'));
}


now that problem solved but when i want to go too ACP it happend again,now i want a code like that but after login it redirect to ACP not index.
tnx

i think i shoud change is_registered and that other line.

_________________
انجمن تخصصی موبایل برای ایرانیان
http://www.mobile4persian.com
برنامه موبایل - بازی موبایل - تم موبایل - اخبار موبایل - ترفند موبایل - s60 -s60 3rd- s80-s90-java-pocket pc-palm-ppc-UIQ3-UIQ
Back to top
Visit poster's website
dcz
Administrateur - Site Admin
Administrateur - Site Admin


Joined: 28 Apr 2006
Posts: 14131

Need REALLY Good Coding SkillsPosted: Sat Jul 26, 2008 8:12 am    Post subject: Re: Need REALLY Good Coding Skills

Well this is pretty much off topic. Could you repost with a link to where the mod is available ?

_________________
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
Visit poster's website
Professional
PR1
PR1


Joined: 07 Apr 2008
Posts: 194
Location: 1/2 of the World

Need REALLY Good Coding SkillsPosted: Sat Jul 26, 2008 8:39 am    Post subject: Re: Need REALLY Good Coding Skills

dcz wrote:
Well this is pretty much off topic. Could you repost with a link to where the mod is available ?


sure dear dcz Smile
here is topic:
http://www.phpbb-seo.com/boards/phpbb3-forum/discussions-vt2956.html#18905

_________________
انجمن تخصصی موبایل برای ایرانیان
http://www.mobile4persian.com
برنامه موبایل - بازی موبایل - تم موبایل - اخبار موبایل - ترفند موبایل - s60 -s60 3rd- s80-s90-java-pocket pc-palm-ppc-UIQ3-UIQ
Back to top
Visit poster's website
divinemanwah



Joined: 01 Apr 2008
Posts: 28

Need REALLY Good Coding SkillsPosted: Thu Aug 14, 2008 3:03 am    Post subject: Re: Need REALLY Good Coding Skills

SeO wrote:
The easiest way to do so will be to parse GYM Sitemaps RSS Feeds, otherwise you'll have to share more than just the db connect to do the rewriting with all options.

GYM 2.0.B1 is going to be released soon Wink


well, GYM is out now....

can i get help with this code now?

thanks! Rolling Eyes
Back to top
SeO
Administrateur - Site Admin
Administrateur - Site Admin


Joined: 15 Mar 2006
Posts: 3477

Need REALLY Good Coding SkillsPosted: Thu Aug 14, 2008 12:01 pm    Post subject: Re: Need REALLY Good Coding Skills

Haven't you seen the demo :
http://phpbb3.phpbb-seo.net/demo/rss-links.php
http://phpbb3.phpbb-seo.net/demo/rss-messages.php

It's very easy to display link lists from any RSS feeds on any phpBB page, with and without the description content, take a look at the new GYM install file for more details.

_________________
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
Display posts from previous:   
Post new topic   Reply to topic    phpBB SEO » SEO Forum  » phpBB3 SEO TooLKit  » phpBB SEO Premod
Page 1 of 1

Navigation Similar Topics

Jump to: