v9:pages
{php parse_str($_SERVER['QUERY_STRING'], $vars)}
{php preg_match_all('/<a(.*?)href="(.*?)"(.*?)>/', $pages, $matches);}
<!--
{php $replace = array()}
{if $matches[2]}
{php foreach($matches[2] as $v):}
{php $str = substr($v, strpos($v, '?')+1)}
{php parse_str($str, $aimChanged)}
{php $vars['page'] = $aimChanged['page']}
{php $arr = array_merge($vars, $aimChanged)}
{php $query = http_build_query($arr)}
{php $replace[] = '?'.$query}
{php endforeach;}
{if $replace}
{php $pages = str_replace($matches[2], $replace, $pages)}
{/if}
{/if}
-->
{template 'content', 'tpl_pages'}
{php $pages = preg_replace('/<a (.*?)>/', '<a target="_self"$1>', $pages);}
{$pages}
{preg_replace('/<a (.*?)>/', '<a target="_self"$1>', $pages)}