Quote:
Originally Posted by Ameise
I try it with the
Code:
<if condition="$show['next']"><link rel="next" href="$address$address2&page=$nextpage</if>
<if condition="$show['prev']"><link rel="prev" href="$address$address2<if condition="$prevpage != 1">&page=$prevpage</if></if>
but the hook is not active in the headinclude
|
Yeah, the problem is that the headinclude template is rendered before any of the page values are calculated. What you might be able to do is a str_replace on the $header variable at some later time. I'd have to know your exact version (and have that source available) to know what's around line 2405 of function.php. But maybe you can use a plugin at hook locaton pagenav_complete to add them, with code something like:
PHP Code:
global $headinclude;
if ($show['next'])
{
$headinclude .= "<link rel=\"next\" href=\"{$address}{$address2}&page={$nextpage}\"/>\n";
}
if ($show['prev'])
{
$headinclude .= "<link rel=\"prev\" href=\"{$address}{$address2}&page={$prevpage}\"/>\n";
}
Edit: (I replaced the above code - I copied the wrong version).