<?php
$pagetitle = $modx->resource->get('pagetitle');
$get = $modx->sanitize($_GET);
if (ISSET($get['tag'])){
$tag=$get['tag'];
return 'Posts tagged with'.$tag;
}
if (ISSET($get['arc_year'])){
return 'Articles posted during '.date( 'F', mktime(0, 0, 0, $get['arc_month'])).' '.$get['arc_year'];
}
if(ISSET($pagetitle)) {
return $pagetitle;
}
This question has been answered by rx2. See the first response.
<?php
$get = $modx->sanitize($_GET);
if (ISSET($get['tag'])){
$tag= preg_replace('/[^a-zA-Z0-9]+/', ' ', $get['tag']);
return 'Posts tagged with '.$tag;
}