WordPress Widget King Login
A Login Widget does not sound very spectacular but still i found a way to add some salt to it. You can set a couple of menu links and the redirect URL for the successful login.
Also brand new is the Options Dump. You can copy/paste your Widget Option stringified from one widget or blog to another. If your friend does not know how to set the right options, just send her yours without having to click through 10 fields.
initial Version 0.5
– set custom Login Redirect URL
– show/hide logout link
– show/hide register Link
– show/hide link to own articles
– Option to dump/read all settings into a string for easy transfer between widgets or blogs
– function to use inside your templates (indipenditly from widget)
– HTML fields to customize HTML before/after widget
– Fully localizable with gettext Translation (German Translation included in framework)
– Set on which Website Area to show the Widget. Options are:
- show "NOT on special page area" which can be combined with "Show in Category" (List/Article)
- show on Home / Search / Archive / Author or 404 page
- show on all or special single Page. You can set the id or slug of the Page where to show
- show on all or special single Article You can set the id or slug of the Article where to show
- show on all or special Category Listing You can set the id of the Category where to show
- Show if inside a Category (with ID). For Category Listings and also Articles
- You find all Options explained in the WordPress Codex in Conditional Tags make sure to definitly read this if you are using those Options!
– based on the king framework
Screenshot / Screencast
English Admin Screens
– Whatever you might suggest…
Of course you should have wordpress widgets installed and activated. If not, you can find the download and install instructions over at automattic.com
– Copy king-login.php into your plugins widget folder -> where your widgets.php is !!!
– Copy the widget Framework (/king-includes Folder) into /plugins (need new version(0.68) from 2.07.2006)!!
– activate in Pluginarea.
– Drag the King Widget on one of your sidebars and then play with it.
The Option to use the slide Open/Close needs some further explanation. Here are the steps to be taken. If you don´t understand those you can simply overlook the swithes in step 1 and 2.
2. go to the login widget options and activate "Use Sliding Box"
3. The difficult part:
You have to fill the custom html options fields. The Box needs to be wrapped in a colappsible elemet(div/li/p) with special ID and you have to give the click event to some element. Since this can vary with your blogtemplate i left this up to you .
Standart Options which should work with the default Template: (please check the " when copy/paste)
HTML Before Widget: <li>
HTML before widget Title: <h2 onClick="loginslide1.toggle();" ><li>
HTML after widget Title: </h2><div id="login1">
HTML after widget: </div></li>
Check out the third screenshot to see the default config. When you have multiple Boxes you just have to adapt the numbers in loginslide1.toggle -> loginslide1.toggle and of course the id login1->login2
Please don´t hesitate to give me a feedback if this is usefull or if you think you found a bug!