Add you own Edit links like Block edit links module

If you have fields you want to add Edit links the same way as Block edit links you can easily hook in by using the the .block (or .node) class in the surrounding div and the .block-edit-link (or .node-edit-link) class around your link.

 

<?php
<div class="cf block">
  <
div class="center"><?php print $footer_message;?>
</div>
  <div class="block-edit-link" style="display: none;">
    <?php if (user_access('administer nodes')) echo l(t('Edit'), '/admin/settings/site-information', array('query' => drupal_get_destination()));?>
  </div>
</div>
?>

This is a part from the jQuery script from the Block edit links module, note the $('div.block, div.node') and the find('.node-edit-link, .block-edit-link')

<?php
....
$(
'.node-edit-link, .block-edit-link').hide();
    $(
'div.block, div.node').mouseover(function() {
      $(
this).find('.node-edit-link, .block-edit-link').css('display', 'block');
    });
....
?>
Knowledge keywords: