[Solved] Can I add new meta lines in overall_header.php

Download and support for PhpBB3 Forum SEO
master412160
BBCoder II
BBCoder II
Posts: 39
Joined: 04 Jun 2011, 14:17

[Solved] Can I add new meta lines in overall_header.php

Post by master412160 »

When I view source of index:

<meta name="keywords" content="" />
<meta name="description" content="" />

that display, so I was thinking onl for viewtopic and viewforum the meta tags are used.

So is it possible for me to add under the two meta's the same meta's again but fill them up.
Last edited by master412160 on 31 Oct 2011, 15:24, edited 1 time in total.
Hello please check out my Interview Site, Interviewed You
User avatar
Stoker
Site Admin
Site Admin
Posts: 3521
Joined: 12 May 2008, 23:26
BBCodes: 239
Favourite BBCode: Anipro
Favourite MOD: PrettyPhoto
Location: Denmark
Contact:

Can I add new meta lines in overall_header.php

Post by Stoker »

Forum SEO only covers viewforum.php and is displayed when viewing a forum.
Board rules! No PM support
master412160
BBCoder II
BBCoder II
Posts: 39
Joined: 04 Jun 2011, 14:17

Can I add new meta lines in overall_header.php

Post by master412160 »

I know that very well. But my question is can I just add the meta tag for keywords and description twice in the overall_header.php

Without causing the seo mod not to work, so the meta is useless due being used twice.

So it would look like this:

Code: Select all

<meta name="keywords" content="<!-- IF SCRIPT_NAME == "viewforum" -->{FORUM_SEO_KEY}<!-- ELSEIF SEO_KEY -->{SEO_KEY}<!-- ENDIF -->" />
<meta name="description" content="<!-- IF SCRIPT_NAME == "viewforum" -->{FORUM_SEO_DESC}<!-- ELSEIF SEO_DESC -->{SEO_DESC}<!-- ENDIF -->" />
<meta name="keywords" content="keyword 1, kewyrod 2," />
<meta name="description" content="This is a description for the index." />
Hello please check out my Interview Site, Interviewed You
master412160
BBCoder II
BBCoder II
Posts: 39
Joined: 04 Jun 2011, 14:17

Can I add new meta lines in overall_header.php

Post by master412160 »

I was hoping to have got a reply by now?
Hello please check out my Interview Site, Interviewed You
User avatar
Stoker
Site Admin
Site Admin
Posts: 3521
Joined: 12 May 2008, 23:26
BBCodes: 239
Favourite BBCode: Anipro
Favourite MOD: PrettyPhoto
Location: Denmark
Contact:

Can I add new meta lines in overall_header.php

Post by Stoker »

Close. You have to wrap the second instance with: <!-- IF SCRIPT_NAME == "index" --> to make sure its only displayed on index.
Board rules! No PM support
master412160
BBCoder II
BBCoder II
Posts: 39
Joined: 04 Jun 2011, 14:17

Can I add new meta lines in overall_header.php

Post by master412160 »

Alright.
<!-- IF SCRIPT_NAME == "index" -->
<meta name="keywords" content="keyword 1, kewyrod 2," />
<meta name="description" content="This is a description for the index." />
<! ENDIF -->

like that?
Hello please check out my Interview Site, Interviewed You
User avatar
Stoker
Site Admin
Site Admin
Posts: 3521
Joined: 12 May 2008, 23:26
BBCodes: 239
Favourite BBCode: Anipro
Favourite MOD: PrettyPhoto
Location: Denmark
Contact:

Can I add new meta lines in overall_header.php

Post by Stoker »

exactly :thumb:
Board rules! No PM support
master412160
BBCoder II
BBCoder II
Posts: 39
Joined: 04 Jun 2011, 14:17

Can I add new meta lines in overall_header.php

Post by master412160 »

Alright now I tried to put that code on some places now, but it doesn't work.

Were to put it?
Hello please check out my Interview Site, Interviewed You
User avatar
Stoker
Site Admin
Site Admin
Posts: 3521
Joined: 12 May 2008, 23:26
BBCodes: 239
Favourite BBCode: Anipro
Favourite MOD: PrettyPhoto
Location: Denmark
Contact:

Can I add new meta lines in overall_header.php

Post by Stoker »

Board rules! No PM support
master412160
BBCoder II
BBCoder II
Posts: 39
Joined: 04 Jun 2011, 14:17

Can I add new meta lines in overall_header.php

Post by master412160 »

I tried this and it didn't work:

<meta name="keywords" content="<!-- IF SCRIPT_NAME == "viewforum" -->{FORUM_SEO_KEY}<!-- ELSEIF SEO_KEY -->{SEO_KEY}<!-- ENDIF -->" />
<meta name="description" content="<!-- IF SCRIPT_NAME == "viewforum" -->{FORUM_SEO_DESC}<!-- ELSEIF SEO_DESC -->{SEO_DESC}<!-- ENDIF -->" />
<!-- IF SCRIPT_NAME == "index" -->
<meta name="keywords" content="keyword 1, kewyrod 2," />
<meta name="description" content="This is a description for the index." />
<! ENDIF -->
Hello please check out my Interview Site, Interviewed You
Locked