Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Plugin: ViewSiteLink
#1
Many people don't understand clicking the title of their site in the admin area will bring them to the home page. This plugin adds a tab called "View Site" in the admin.
http://get-simple.info/extend/plugin/viewsitelink/507/

Known Bugs:
-Showing "View Site" at top of all pages in /admin and front end. (FIXED IN 1.1)
-Causing some problems with the admin interface (FIXED IN 1.1)
-View Site Link not linking to correct location (FIXED IN 1.1)
Reply
#2
That functionality allready exists in the core (at least since GetSimple version 2):

The view button on this screenshot:

[Image: screenshot_editpage.png]

Also, yours doesn't work. it revers to "site adress"/admin/$SITEURL


Edit: Actually this seems to be part of your description:

Quote:Known Bugs:
-View Site Link not linking to correct location (to be fixed in 1.1)

Why do you upload a plugin where the main functionality doesn't work at all yet?
Reply
#3
Why not just stick a link after the title that says view site.

Or a hover tip on the title, its fairly standard to click the title to link to home. But i can see how people do not know this.

use jquery to append to the dom
NEW: SA Admin Toolbar Plugin | View All My Plugins
- Shawn A aka Tablatronix
Reply
#4
Sorry about the bugs,
Version 1.1 will be out very soon!

Its not intended to view the page you just edited. Its simple meant to be used in addition to the big title link, for most clients that aren't computer savvy and don't realize they need t click the title.
Reply
#5
Heres a suggestion since I have already considered this,maybe you will like this solution.

There is a hook for nav-tab

you can insert this ad it will be next to the little pills for settings and support.

Code:
<li class="rightnav"><a class="first" href="" style="
    border-radius: 3px;
    margin-left: 3px;
    border-left: none;
">View Site</a></li>
NEW: SA Admin Toolbar Plugin | View All My Plugins
- Shawn A aka Tablatronix
Reply
#6
OK do you think I should put it there, or in the tabs where I originally put it?
Or both?
Thanks!
Reply
#7
I think it looks better beside the settings and supports buttons.

M
My Github Repos: Github
Website: DigiMute
Reply
#8
Tabs are meant to be pages not really links.
NEW: SA Admin Toolbar Plugin | View All My Plugins
- Shawn A aka Tablatronix
Reply
#9
OK I'll look at it which I think looks best. Thanks for the feedback Smile
Reply
#10
Alright, well now I don't understand why my plugin is breaking the admin interface.

It's not showing its information in the Plugins tab, and it's generally causing problems in the admin interface.

I have a feeling once this plugin is working perfectly, I will have learned more about how GetSimple works so I won't have to ask stupid questions Smile

Here's my code:

Code:
<?php

/*  
    Plugin Name: ViewSiteLink
    Adds an obvious link in admin navigation that opens home page in new tab.
    Version: 1.0
    Author: Michel Staake
    Author URI: http://michelstaake.me/
*/

$viewsitelink=viewsitelink(__FILE__, ".php");

register_plugin(
    $viewsitelink,
    'ViewSiteLink',
    '1.0',
    'Michel Staake',
    'http://michelstaake.me/',
    'Adds an obvious link in admin navigation that opens home page in new tab.',
    'plugin',
    'viewsitelink'
);

add_action('nav-tab','viewsitelink');

function viewsitelink() {
    echo '<li class="rightnav"><a target="_blank" class="first" href="" style="
    border-radius: 3px;
    margin-left: 3px;
    border-left: none;
    ">View Site</a></li>';
}

?>
Reply
#11
Hello,

i think that it should be so:

Code:
<?php

/*  Plugin Name: ViewSiteLink
    Adds an obvious link in admin navigation that opens home page in new tab.
    Version: 1.0
    Author: Michel Staake
    Author URI: http://michelstaake.me/
*/

$viewsitelink=basename(__FILE__, ".php");

register_plugin(
      $viewsitelink,
    'ViewSiteLink',
    '1.0',
    'Michel Staake',
    'http://michelstaake.me/',
    'Adds an obvious link in admin navigation that opens home page in new tab.',
    'plugins',
    'viewsitelink'
);

add_action('nav-tab','viewsitelink');

function viewsitelink() {
    global $SITEURL;
    echo '<li class="rightnav"><a target="_blank" class="first" href="'.$SITEURL.'" style="
    border-radius: 3px;
    margin-left: 3px;
    border-left: none;
    ">View Site</a></li>';
}

?>

Regards.
Reply
#12
Hello, version 1.1 has been released!
Thank you to all who helped, I am now less confused on how this whole thing works!
http://get-simple.info/extend/plugin/viewsitelink/507/
Reply
#13
Version 1.2 has been released. It has no functionality differences, you don't need to update, but some of the text and descriptions have been changed.
Reply
#14
An alternative solution if you use the Custom Admin CSS plugin is the following CSS. It just adds a faux tooltip when you hover the title in the back-end:

Code:
.header h1 a:hover:after {
  z-index: 10;
  margin: .8em;
  position: absolute;
  padding: .5em 1em;
  content: "View website";
  background: rgba(0,0,0,.75);
  font:400 11px/1 'open sans', sans-serif;
}
If it doesn't work at first, you'll just need to use a better browser.
Modern UI Admin for GetSimple
Watch the demo. Install this plugin. Use this CSS. Enjoy.
Reply




Users browsing this thread: 2 Guest(s)