After this part of the hack code:
if ($Match == "Username") {// profile "Show all user's posts" search link fix
$Match = "";
$ByUsername = $Words;
$Words = "";
}
add this:
$EByUsername = rawurlencode($ByUsername);
And add the variables to the navigation links in the dosearch.tmpl file:
<a href="{$config['phpurl']}/dosearch.php?Cat=$Cat&Forum=$URLForum&Words=$URLWords&Match=$URLMatch&Searchpage=$prevpage&Limit=$Limit&Old=$Old">
and
<a href="{$config['phpurl']}/dosearch.php?Cat=$Cat&Forum=$URLForum&Words=$URLWords&Match=$URLMatch&Searchpage=$nextpage&Limit=$Limit&Old=$Old">
would be:
<a href="{$config['phpurl']}/dosearch.php?Cat=$Cat&ByUsername=$EByUsername&Forum=$URLForum&Words=$URLWords&Match=$URLMatch&Searchpage=$prevpage&Limit=$Limit&Old=$Old">
and
<a href="{$config['phpurl']}/dosearch.php?Cat=$Cat&ByUsername=$EByUsername&Forum=$URLForum&Words=$URLWords&Match=$URLMatch&Searchpage=$nextpage&Limit=$Limit&Old=$Old">
Not sure if this will work. Just guessing.