WordPress.org

Ready to get started?Download WordPress

Forums

Custom WP Login Widget
Language - some changes (2 posts)

  1. andrenalin
    Member
    Posted 1 year ago #

    Hi,

    i needed some changes and i think if you want to change the language you can better use this in
    clw-form.php

    it is using the core language

    and this plugin works great in my wp 3.5.1 // thanks!

    <?php
    
    add_action ('clw_form', 'clw_form');
    function clw_form ($form_id)
    {
    
    	if ( is_user_logged_in() ) { ?>
    		<? $current_user = wp_get_current_user(); ?>
    		<h3>Hi <? echo $current_user->display_name ?>!</h3>
    		<a href="<?php echo wp_logout_url($_SERVER['REQUEST_URI']); ?>"><?php _e( 'Logout' ); ?></a>
    	<?
    	} else { ?>
    		<!--<h3>Login</h3>-->
    		<form action="<?php echo get_option('home'); ?>/wp-login.php" method="post">
    		<div><?php _e('Username') ?> <input type="text" name="log" id="log" value="<?php echo wp_specialchars(stripslashes($user_login), 1) ?>" size="20" /></div><br>
    		<div><?php _e('Password') ?> <input type="password" name="pwd" id="pwd" size="20" /></div><br>
    		<div>
             <label for="rememberme"><input name="rememberme" id="rememberme" type="checkbox" checked="checked" value="forever" /> <?php esc_attr_e('Remember Me'); ?></label>
    		       <input type="hidden" name="redirect_to" value="<?php echo $_SERVER['REQUEST_URI']; ?>" /><br />
    <input type="submit" name="submit" value="GoOn" class="button" /></div><br>
    		    <!--<p>
    		       <label for="rememberme"><input name="rememberme" id="rememberme" type="checkbox" checked="checked" value="forever" /> Remember me</label>
    		       <input type="hidden" name="redirect_to" value="<?php //echo $_SERVER['REQUEST_URI']; ?>" />
    		    </p>-->
    		</form>
    		<a href="<?php echo get_option('home'); ?>/wp-login.php?action=lostpassword"><?php _e( 'Lost your password?' ); ?></a> <br />
    <a href="<?php echo get_option('home'); ?>/wp-login.php?action=register"><?php _e( 'Register' ); ?></a>
    <?
    	} 
    
    }
    ?>

    http://wordpress.org/extend/plugins/custom-wp-login-widget/

  2. Cibulka
    Member
    Posted 1 year ago #

    Very useful & works, thank you captain!

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags

No tags yet.