In this tutorials I want to explain how you can optimize search engine results by using SEO friendly URL's for articles, news and the photogallery. Based on the SEO mod by web-bureau.com we can easily transform the ugly readarticle.php?article_id=x URL's.
With this tutorial you can implant the SEO friendly URL mod to your articles, news and photogallery. I will explain how to convert your files OR you can simply download the pre-modded files. (located in the article footer)
If you are going to install all SEO mods, you only have to do step 1 and 3 once.
If you run in any problems, take a look
here.
<b>Requirements:</b>
-
Seoname.php - PHP-Fusion 6.01.10 or higher.
(probably works on lower version too but only tested with this version and higher)-
.htaccess support on your server.
SEO friendly links for Articles.php (example:
http://www.underground3k.com/articles.php )
| Step 1 |
| Download Seoname.php and upload that file to your includes folder. |
| Step 2 |
Create a new .htaccess file OR open yours if you already got one and paste the following code in it:
## SEO friendly URL by web-bureau.com ## Provided by PHPfusion-mods.net ## Use this if Fusion is installed in your root directory RewriteBase / ## Use the following if Fusion is not installed on your root directory ## RewriteBase /<fusion_path>/ RewriteEngine On ## Articles RewriteRule ^(.*)-a([0-9]*).htm$ readarticle.php?article_id=$2 [L,NC] ## Article categories RewriteRule ^(.*)-d([0-9]*).htm$ articles.php?cat_id=$2 [L,NC] |
If your Fusion isn't in the root, replace 'RewriteBase' to 'RewriteBase /<fusion_path>/' (where <fusion_path> is the folder name).
|
| Step 3 |
Open Maincore.php and find:
'?>'
Above, add the following:
// Search engine friendly URLs // http://www.web-bureau.com/php-fusion-cms-c1.htm require_once INCLUDES."seoname.php"; |
|
| Step 4 |
Open articles.php (original one) and search for: (line 27)
| <a href='".FUSION_SELF."?cat_id=".$data['article_cat_id']."'>".$data['article_cat_name']."</a> |
Replace with:
| <a href='".seoname($data['article_cat_name'])."-d".$data['article_cat_id'].".htm'>".$data['article_cat_name']."</a> |
Find:
| <a href='readarticle.php?article_id=".$data['article_id']."'>".$data['article_subject']."</a> |
And replace with:
| <a href='".seoname($data['article_subject'])."-a".$data['article_id'].".htm'>".$data['article_subject']."</a> |
Save articles.php and upload it. |
End
Everything should work now, if you run in trouble, recheck the steps above. If you still have problems, see the
support thread .
SEO friendly links for Photogallery.php (example: http://www.underground3k.com/photogallery.php )| Step 1 |
| Download Seoname.php and upload that file to your includes folder. |
| Step 2 |
Create a new .htaccess file OR open yours if you already got one and paste the following code in it:
## SEO friendly URL by web-bureau.com ## Provided by PHPfusion-mods.net ## Use this if Fusion is installed in your root directory RewriteBase / ## Use the following if Fusion is not installed on your root directory ## RewriteBase /<fusion_path>/ RewriteEngine On ## Photogallery Albums RewriteRule ^(.*)-c([0-9]*).htm$ /photogallery.php?album_id=$2 [L,NC]
## Photogallery Photo's RewriteRule ^(.*)-r([0-9]*).htm$ /photogallery.php?photo_id=$2 [L,NC] |
If your Fusion isn't in the root, replace 'RewriteBase' to 'RewriteBase /<fusion_path>/' (where <fusion_path> is the folder name).
|
| Step 3 |
Open Maincore.php and find:
'?>'
Above, add the following:
// Search engine friendly URLs // http://www.web-bureau.com/php-fusion-cms-c1.htm require_once INCLUDES."seoname.php"; |
|
| Step 4 |
Open photogallery.php (original one) and search for: (around line 52)
| <a href='".FUSION_SELF."?album_id=".$data['album_id']."'> |
Replace with:
| <a href='".seoname($data['album_title'])."-c".$data['album_id'].".htm'> |
Find: (around line 53)
| <a href='".FUSION_SELF."?photo_id=$photo_id'> |
And replace with:
| <a href='".seoname($data['album_title'])."-r".$data['photo_id'].".htm'> |
Find: (around line 119) | <a href='".FUSION_SELF."?album_id=".$data['album_id']."'> | And replace with: | <a href='".seoname($data['album_title'])."-c".$data['album_id'].".htm'> | Find: (around line 126) | <a href='".FUSION_SELF."?photo_id=".$data['photo_id']."'> | And replace with: | <a href='".seoname($hold_album_title)."-r".$data['photo_id'].".htm'> | Find: (around line 162) | <a href='".FUSION_SELF."?album_id=".$data['album_id']."'> | And replace with: | <a href='".seoname($data['album_title'])."-c".$data['album_id'].".htm'> | Save photogallery.php and upload it. |
End
Everything should work now, if you run in trouble, recheck the steps above. If you still have problems, see the
support thread .
SEO friendly links for News.phpFirst: Download the new
news.php .
| Step 1 |
| Download Seoname.php and upload that file to your includes folder. |
| Step 2 |
Create a new .htaccess file OR open yours if you already got one and paste the following code in it:
## SEO friendly URL by web-bureau.com ## Provided by PHPfusion-mods.net ## Use this if Fusion is installed in your root directory RewriteBase / ## Use the following if Fusion is not installed on your root directory ## RewriteBase /<fusion_path>/ RewriteEngine On ## News categories RewriteRule ^(.*)-nc([0-9]*).htm$ news_cats.php?cat_id=$2 [L,NC]
## News articles RewriteRule ^(.*)-rn([0-9]*).htm$ news.php?readmore=$2 [L,NC] RewriteRule ^(.*)-rn([0-9]*)$ news.php?readmore=$2 [L,NC] |
If your Fusion isn't in the root, replace 'RewriteBase' to 'RewriteBase /<fusion_path>/' (where <fusion_path> is the folder name).
|
| Step 3 |
Open Maincore.php and find:
'?>'
Above, add the following:
// Search engine friendly URLs // http://www.web-bureau.com/php-fusion-cms-c1.htm require_once INCLUDES."seoname.php"; |
|
Step 4
|
Open theme.php and find:
| echo openform("N",$info['news_id']).newsopts($info,"ˇ").closeform("N",$info['news_id']); |
Replace with:
echo openform("N",$info['news_id']).newsposter($info," ˇ") .seonewsopts($info,"ˇ").closeform("N",$info['news_id']); |
|
| Step 5 |
Upload the news.php which you downloaded in the beginning of the tutorial.
|
End
Everything should work now, if you run in trouble, recheck the steps above. If you still have problems, see the
support thread .
obat herbal sakit maag | obat herbal nyeri sendi madu untuk diabetes habbasyifa | habbatussauda cap kurma ajwa | jual madu asli | sari kurma aljazira | sari kurma sahara syamil dates honey | madu anak syamil | madu kelengkeng | herbal pelangsing | sari kurma tamr ramuan herbal kolesterol keladi tikus jakarta madu randu sari kurma al jazira premium obat herbal untuk mengobati kanker payudara herbal penurun panas obat herbal untuk diabetes melitus obat batuk herbal anak sambiloto kapsul