1 (edited by kudataz 2016-04-30 13:49)

Topic: How to add more meta tag?

Hy punbb
i have url like this

http://punbb.informer.com/forums/search/?action=search&keywords=zz+zz+zz&search=Search

i want add meta tag for this file only in search.php
code i use is this

$forum_head['moremeta'] = '<meta property="og:type" content="search" />';

but i dont know where must place
how to add meta tag on spesific file like this?
please your help ^^

sorry my BAD english T___T
Have a nice day >.<
(^____^)v

2 (edited by PanBB.Ru 2016-04-30 18:07)

Re: How to add more meta tag?

Open
header.php
After
($hook = get_hook('hd_head')) ? eval($hook) : null;
Add

if (FORUM_PAGE == 'search')
{
    $forum_head['moremeta'] = '<meta property="og:type" content="search" />';
}

Or for all search pages

if (strpos(FORUM_PAGE, 'search') === 0)
{
    $forum_head['moremeta'] = '<meta property="og:type" content="search" />';
}

Why do you need it??? these pages are not indexed...

Re: How to add more meta tag?

Thxx u Mr.Panbb for reply..
but dont work sir
i add like this in header.php

($hook = get_hook('hd_head')) ? eval($hook) : null;

if (FORUM_PAGE == 'search')
{
    $forum_head['moremeta'] = '<meta property="og:title" content="search" />';
}

in search page result not display meta tag in source
please ur help sir ^^

sorry my BAD english T___T
Have a nice day >.<
(^____^)v

4 (edited by PanBB.Ru 2016-05-01 08:30)

Re: How to add more meta tag?

then use that:

if (strpos(FORUM_PAGE, 'search') === 0)
{
    $forum_head['moremeta'] = '<meta property="og:type" content="search" />';
}

Re: How to add more meta tag?

above two code didnt work sir sad
please ur help :3

sorry my BAD english T___T
Have a nice day >.<
(^____^)v

6 (edited by PanBB.Ru 2016-05-01 11:21)

Re: How to add more meta tag?

I have it all works fine...

which put the code ?
on header.php OR search.php?
where you can see?
your list of extensions and forum?