forum.coppermine-gallery.net

Support => cpg1.4.x Support => Older/other versions => cpg1.4 themes/skins/templates => Topic started by: Icmesa3000 on July 28, 2008, 03:17:25 pm

Title: [Solved]: Shorter title - no recapitulation of the gallery name and category name - how?
Post by: Icmesa3000 on July 28, 2008, 03:17:25 pm
Hello,

I won't display the gallery name on every title. On the thumbnail page there should be only the category name (e.g. My gallery - category 1 ==ONLY==> category 1) and on the display image page only the page name - not with gallery name and category name (e.g. My gallery - category 1/picture 7 ==ONLY==> Picture 7)  ???

Thank you very much 
Title: Re: Shorter title - no recapitulation of the gallery name and category name - how?
Post by: Hein Traag on July 28, 2008, 04:12:18 pm
website address ?
Title: Re: Shorter title - no recapitulation of the gallery name and category name - ho
Post by: Icmesa3000 on July 28, 2008, 04:20:42 pm
http://icmesa.org (not ready jet)
Title: Re: Shorter title - no recapitulation of the gallery name and category name - ho
Post by: Joachim Müller on July 28, 2008, 04:32:57 pm
Are you refering to the individual page's <title>-tag in HTML that determines the name of the browser window/tab?
Title: Re: Shorter title - no recapitulation of the gallery name and category name - ho
Post by: Icmesa3000 on July 28, 2008, 04:45:51 pm
No, but every coppermine has the same title structure? How can I change this?

E.g.: http://coppermine-gallery.net/demo/cpg14x/displayimage.php?album=2&pos=0
Title: Re: Shorter title - no recapitulation of the gallery name and category name - ho
Post by: Joachim Müller on July 28, 2008, 04:52:55 pm
What title are you refering to? I have no idea what you're talking about. Post some real live examples like
Quote
On page XXX I want to see the text YYY replaced by ZZZ
Title: Re: Shorter title - no recapitulation of the gallery name and category name - ho
Post by: Icmesa3000 on July 28, 2008, 05:44:51 pm
No  ;D, I think you misunderstood me . I had made some screenshots.

Red (in Firefox page title) = That should not display in page title
Green (in Firefox page title) = Only that should display page title

Title: Re: Shorter title - no recapitulation of the gallery name and category name - ho
Post by: Joachim Müller on July 28, 2008, 09:58:55 pm
That is the HTML <title>-tag
Title: Re: Shorter title - no recapitulation of the gallery name and category name - how?
Post by: Nibbler on July 28, 2008, 10:02:57 pm
Copy this into your custom theme's theme.php

Code: [Select]
// Function for writing a pageheader
function pageheader($section, $meta = '')
{
    global $CONFIG, $THEME_DIR;
    global $template_header, $lang_charset, $lang_text_dir;

    $custom_header = cpg_get_custom_include($CONFIG['custom_header_path']);

        $charset = ($CONFIG['charset'] == 'language file') ? $lang_charset : $CONFIG['charset'];

    header('P3P: CP="CAO DSP COR CURa ADMa DEVa OUR IND PHY ONL UNI COM NAV INT DEM PRE"');
        header("Content-Type: text/html; charset=$charset");
    user_save_profile();

    $template_vars = array('{LANG_DIR}' => $lang_text_dir,
        '{TITLE}' => strip_tags(bb_decode($section)), // removed gallery name from title
        '{CHARSET}' => $charset,
        '{META}' => $meta,
        '{GAL_NAME}' => $CONFIG['gallery_name'],
        '{GAL_DESCRIPTION}' => $CONFIG['gallery_description'],
        '{SYS_MENU}' => theme_main_menu('sys_menu'),
        '{SUB_MENU}' => theme_main_menu('sub_menu'),
        '{ADMIN_MENU}' => theme_admin_mode_menu(),
        '{CUSTOM_HEADER}' => $custom_header,
        );

    echo template_eval($template_header, $template_vars);
}

If it's already there then I commented the line to change.
Title: Re: Shorter title - no recapitulation of the gallery name and category name - ho
Post by: Icmesa3000 on July 28, 2008, 11:52:28 pm
Thank you very much  ;D :D. There is only one problem: In the picture view (displayimage-....html) is "album name/picture page name" but it should be only picture page name.
Title: Re: Shorter title - no recapitulation of the gallery name and category name - how?
Post by: Nibbler on July 29, 2008, 11:03:49 am
Edit displayimage and change

Code: [Select]
pageheader($album_name . '/' . $picture_title, $meta_keywords, false);
to

Code: [Select]
pageheader($picture_title, $meta_keywords, false);
Title: Re: Shorter title - no recapitulation of the gallery name and category name - ho
Post by: Icmesa3000 on July 29, 2008, 12:31:32 pm
Thank you very much  :o. I just like the shorter title better. What about SEO, Baidu, Google, and Yahoo?
Title: Re: [Solved]: Shorter title - no recapitulation of the gallery name and category
Post by: Joachim Müller on July 29, 2008, 01:17:09 pm
What about the nephews of Donald Duck (I don't remember their names)? In other words: what is your question for. Are you asking on the impact that your changes will have on SEO?
Title: Re: [Solved]: Shorter title - no recapitulation of the gallery name and category
Post by: Icmesa3000 on July 29, 2008, 03:52:47 pm
Yes,  I hope that isn't a big drawback for my page?
Title: Re: [Solved]: Shorter title - no recapitulation of the gallery name and category
Post by: Joachim Müller on July 29, 2008, 07:18:40 pm
Frankly: I have no idea, but I don't guess so.
Title: Re: [Solved]: Shorter title - no recapitulation of the gallery name and category
Post by: Icmesa3000 on July 30, 2008, 09:31:28 pm
I see that my mainpage is now named "Home", how can I change "home" into my gallery name (only for my mainpage)?