2 tilqicom Nov 22, 2008 22:20

nice little widget for a multi user site. How hard would it be to include a "remember me" checkbox?
evo will remember you for years .... unless you log out ;)
¥
Thanks for this plugin !!!
If somebody is interested, i have made some modification on this plugin to show avatar and Edit profil in case of the user is login :
just replace :
if ( is_logged_in() )
{}
by :
if ( is_logged_in() )
{
echo '<div class="image_block">';
if ( isset($GLOBALS['avatars_Plugin']) )
{
$GLOBALS['avatars_Plugin']->display_avatar( array(
'type' => 'user', // Avatar type.
'id' => '', // Optional ID. Example: 'id' => 3,
// to display avatar of user/post/category/blog #3
'before' => '<div>', // Before image block.
'after' => '</div>', // After image block.
'style' => '', // Image style e.g. margin:5px.
));
}
$redir_url = url_rel_to_same_host( regenerate_url( '', '', '', '&' ), $htsrv_url_sensitive );
echo '<a href="'.$Blog->get('url').'?disp='.'profile&redirect_to='.rawurlencode( $redir_url ).'">'.T_( 'Edit your profile' ).'</a>';
echo '</div>';
return;
}
and more simple, add a register link whan the user isn't logged :
echo '<div>';
echo '<a href="'.$htsrv_url_sensitive.'register.php?redirect_to='.rawurlencode( $redir_url ).'">'.T_( 'Register form' ).'</a>';
echo '</div>';
You can download my version here : http://kraolil.hd.free.fr/media/laviedukrao/divers/_loginbox.plugin.zip
I'm able to get the plugin to work and even have the borders removed. But I can't get krao69's coding to work. I'm putting it in loginbox.plugin.php, is that correct? And where do you put the coding to add a register link? Thanks for any help given! :)
Nick off Spammer
Sorry my site is down for the moment ... that's why you can't get source code.
I use it on version 2.4 not on 3 for information.
OK, thanks for the info krao69.
And what's with the Nick off Spammer? I just joined this forum and don't understand all the lingo.
@pansygal2...
the "nick off spammer" bit replaced a post with about 75 links to nothing to do with b2evolution and everything to do with spam.
That's why I delete 'em or move 'em to the spamhaus.
It's like if your dog craps on the floor do you put a paper towel over it and leave it there?
Does anybody know Where can I find Login box widget for b2evolution 3.3?
I don't know if there is a 3.3 compatible version of this widget.
You will have to make a few changes to make it compatible with the new version.
1. Put the _loginbox.plugin.php inside your plugins folder.
2. Open the messages.pot file inside the locales folder which is included in the zip file and make a few changes. Copy and paste into the original file on your server in the same location. Code should look like this:
#: ../../../plugins/_loginbox.plugin.php:35
msgid "Provides a widget which displays a simple login box."
msgstr ""
#: ../../../plugins/_loginbox.plugin.php:78
msgid "Lost password ?"
msgstr ""
#: ../../../plugins/_loginbox.plugin.php:87
msgid "Login"
msgstr ""
#: ../../../plugins/_loginbox.plugin.php:88
msgid "Password"
msgstr ""
#: ../../../plugins/_loginbox.plugin.php:89
msgid "Log in!"
msgstr ""
#: ../../../plugins/_loginbox.plugin.php:147
msgid "Box title"
msgstr ""
#: ../../../plugins/_loginbox.plugin.php:148
msgid "Login form"
msgstr ""
#: ../../../plugins/_loginbox.plugin.php:150
msgid "The title to display at the top of the box."
msgstr ""
#: ../../../plugins/_loginbox.plugin.php:153
msgid "Display \"Lost password?\" link"
msgstr ""
#: ../../../plugins/_loginbox.plugin.php:158
msgid "Size of username input field"
msgstr ""
#: ../../../plugins/_loginbox.plugin.php:166
msgid "Size of password input field"
msgstr ""
3. Do the same with the _global.php file inside the de_DE folder. I suggest do a find and only add the lines that are needed as a few of them are all ready included.
4. Then go to the LC_MESSAGES folder and open messages.po and only add in the changed code:
#: ../../../_loginbox.plugin.php:35
msgid "Provides a widget which displays a simple login box."
msgstr "Stellt ein Widget bereit, das eine einfache Loginbox anzeigt."
#: ../../../_loginbox.plugin.php:78
msgid "Lost password ?"
msgstr "Passwort vergessen?"
#: ../../../_loginbox.plugin.php:87
msgid "Login"
msgstr "Benutzername"
#: ../../../_loginbox.plugin.php:88
msgid "Password"
msgstr "Passwort"
#: ../../../_loginbox.plugin.php:89
msgid "Log in!"
msgstr "Einloggen"
#: ../../../_loginbox.plugin.php:147
msgid "Box title"
msgstr "Boxtitel"
#: ../../../_loginbox.plugin.php:148
msgid "Login form"
msgstr "Login"
#: ../../../_loginbox.plugin.php:150
msgid "The title to display at the top of the box."
msgstr "Der Titel, der über der Box angezeigt werden soll."
#: ../../../_loginbox.plugin.php:153
msgid "Display \"Lost password?\" link"
msgstr "\"Passwort vergessen?\"-Link anzeigen"
#: ../../../_loginbox.plugin.php:158
msgid "Size of username input field"
msgstr "Größe des Benutzername-Feldes"
#: ../../../_loginbox.plugin.php:166
msgid "Size of password input field"
msgstr "Größe des Passwortfeldes"
5. In your admin panel activate the widget and log out to see what it looks like.
6. Make additional changes to css file to make it look how you want.
I got it working this morning while trying to wake up and enjoy my coffee....so if I missed something I apologize. I'm not completely awake yet and this is the first time I've messed with this application.
thank you
I got an error
Notice: Undefined variable: Blog in E:\xampp\htdocs\b2evolution\blogs\plugins\loginbox_plugin\_loginbox.plugin.php on line 62
Fatal error: Call to a member function get() on a non-object in E:\xampp\htdocs\b2evolution\blogs\plugins\loginbox_plugin\_loginbox.plugin.php on line 62
help pls
any way to change text and textbox colours?
links dead.. where to download it
thanks cool one, it shouldnt be needed as a plugin already i believe , useful enough though, sorry for such a late reply, i even couldnt find time to stop by for a thank you (: