1
Anonymous
xcgal pagetitle hack ..improve the searchability of your site!
  • 2007/5/8 23:44

  • Anonymous

  • Posts: 0

  • Since:


xcgal Pagetitle hack ..improve the searchability of your site!

The title of your page plays an important role in helping search engines (google,yahoo,msn,..etc) and visitors to determine the content of your site.

xcgal is one of the most popular galleries but it's use name of module as pagetitle for all pages, so this will lead to lose of most vistors and remember: google, yahoo and msn search engines are vistors too!!

This small hack will fix this

Edit displayimage.php and find at the end:
include XOOPS_ROOT_PATH.'/include/comment_view.php';
    include_once 
"../../footer.php";

}

?>


then add before it:

$xoopsTpl->assign('xoops_pagetitle'$myts->makeTboxData4Show($xoopsModule->name()) . ' - ' .$myts->makeTboxData4Show($CURRENT_ALBUM_DATA['title']) . ' - ' .$myts->makeTboxData4Show($CURRENT_PIC_DATA['title']));



The result will be:

$xoopsTpl->assign('xoops_pagetitle'$myts->makeTboxData4Show($xoopsModule->name()) . ' - ' .$myts->makeTboxData4Show($CURRENT_ALBUM_DATA['title']) . ' - ' .$myts->makeTboxData4Show($CURRENT_PIC_DATA['title']));
    include 
XOOPS_ROOT_PATH.'/include/comment_view.php';
    include_once 
"../../footer.php";

}

?>


You can use the following code to display album name in album page (thumbnails.php):

$xoopsTpl->assign('xoops_pagetitle'$myts->makeTboxData4Show($xoopsModule->name()) . ' - ' .$myts->makeTboxData4Show($CURRENT_ALBUM_DATA['title']));
include_once 
"../../footer.php";
?>


Demo: click here

2
wcrwcr
Re: xcgal pagetitle hack ..improve the searchability of your site!
  • 2007/5/8 23:50

  • wcrwcr

  • Home away from home

  • Posts: 1114

  • Since: 2003/12/12


Hi Mowaffak

That?s a great one.
Thanks for sharing it.

Almost doing that, but you did it first and better

Thanks

PS. the only problem is that neither my browser or ME can read in arab

But i believe you...

3
iHackCode
Re: xcgal pagetitle hack ..improve the searchability of your site!

nice.
CBB / LatestNews / Publisher / XM-Spotlight

(ノ◕ヮ◕)ノ*:・゚✧

4
mrphilong
Re: xcgal pagetitle hack ..improve the searchability of your site!

Quote:


PS. the only problem is that neither my browser or ME can read in arab

But i believe you...


It works, see here top left hand side with the format;

Site Name - Module Name - Album Name

very nice thanks Mowaffak.

5
irmtfan
Re: xcgal pagetitle hack ..improve the searchability of your site!
  • 2007/5/9 1:41

  • irmtfan

  • Module Developer

  • Posts: 3419

  • Since: 2003/12/7


Thank you Mowaffak,
i even never think about that before!
and a question: how to show Category name? it seems it is not that easy.

6
wcrwcr
Re: xcgal pagetitle hack ..improve the searchability of your site!
  • 2007/5/9 11:13

  • wcrwcr

  • Home away from home

  • Posts: 1114

  • Since: 2003/12/12


@Mowaffak

Thanks again

@ irmtfan

Quote:
and a question: how to show Category name?


That would be great too

7
ALOOoo
Re: xcgal pagetitle hack ..improve the searchability of your site!
  • 2007/5/9 15:16

  • ALOOoo

  • Just popping in

  • Posts: 41

  • Since: 2004/10/9


Great job my friend, and thanks for sharing

8
martyboy
Re: xcgal pagetitle hack ..improve the searchability of your site!
  • 2007/5/9 16:10

  • martyboy

  • Quite a regular

  • Posts: 256

  • Since: 2004/5/25


Mowaffak, you must read minds, I was just thinking the other day that pagetitles in xcgal would be ideal.

Thankyou very much for this great hack.
Michael Jackson = King Of Pop

Xoops = King Of CMS

9
Anonymous
Re: xcgal pagetitle hack ..improve the searchability of your site!
  • 2007/5/10 20:26

  • Anonymous

  • Posts: 0

  • Since:


Thank you

I'm not use categories in my site so I forgot it

I will try to do it later

10
wcrwcr
Re: xcgal pagetitle hack ..improve the searchability of your site!
  • 2007/5/11 20:23

  • wcrwcr

  • Home away from home

  • Posts: 1114

  • Since: 2003/12/12


Quote:
I'm not use categories in my site so I forgot it


just for remembering you

Login

Who's Online

202 user(s) are online (67 user(s) are browsing Support Forums)


Members: 0


Guests: 202


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Nov 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits