Possible link improvement (1 post)

  1. aguseo
    Posted 3 years ago #

    Plugin works absolutely fine and is cool.
    However, when building WordPress pages on my laptop I use an xampp server, and the sites address is usually

    In this case the admin link would show to which is not good.

    Thus I reco to use the site_url function of wordpress to get it proper everywhere.

    Here's the final code:

    function lynkAdminLinkBox() {
    $url = site_url('/wp-admin', '');
    echo '<div style="position: absolute; top: 0; left: 0; width: 12px; height: 12px; font: 1px; z-index: 76;" onmouseover="document.getElementById(\'lynkAdminBoxOn\').style.visibility=\'visible\';"></div><div style="background: #2e4e73; color: #fff; position: absolute; top: 0; left: 0; width: 12px; height: 80px; z-index: 78; display: block; margin: 0; padding: 0; visibility: hidden; font: 9px Arial; text-align: center; cursor: pointer;" onmouseout="this.style.visibility=\'hidden\';" onclick="window.location.href=\'' . $url . '\'" id="lynkAdminBoxOn">&nbsp;&nbsp; A D M I N</div>';


Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Admin-Link-Box
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic

  • RSS feed for this topic
  • Started 3 years ago by aguseo
  • This topic is not a support question
  • WordPress version: 3.3.1