With Kirby version 2.2.x the adress of the panel pages have changed.
Therefore, the file in Step 1 is as follows:
<?php if (!isset($theTag)) $theTag = 'h1'; // no tag for the page title via the snippet variable "theTag" assigned ?>
<?php if (!isset($thePage)) $thePage = $page; // no "$page" via the snippet variable "thePage" assigned ?>
<?php if (!isset($thePageTitle)) $thePageTitle = $thePage->title(); // no "$page->title()" via the snippet variable "thePageTitle" assigned ?>
<<?php echo $theTag; ?>><?php if (isset($thePageLink)) echo '<a href="' . $thePageLink . '">'; // the url of the link in the title is in "thePageLink" or the variable "thePageLink" is empty for no link ?><?php echo html($thePageTitle); ?><?php if (isset($thePageLink)) echo '</a>'; ?><?php if($user = $site->user() and $user->hasPanelAccess()): // user is logged in and has panel access ?>
<a href="<?php echo $site->url() ?>/panel/pages/<?php echo $thePage->uri() ?>/edit" target="<?php echo c::get('HeinerEF.EditTarget', '_blank'); ?>" title="Edit page data (in new window / tab)" class="admineditlink"><sup class="fa fa-cog admincolor"></sup></a><?php endif; ?>
</<?php echo $theTag; ?>>
Good luck!