WordPress.org

Support

Support » Plugins and Hacks » [Plugin: Simple Local Avatars] Using this plugin in a front-end page.

[Plugin: Simple Local Avatars] Using this plugin in a front-end page.

Viewing 15 replies - 1 through 15 (of 15 total)
  • @dominor Novus

    OK, it’s been monthe, and you’ve probably figured this out by now, but I’m doing this also and I thought I’d share how I got it done. Really, you just need to install a plugin called “Front End Users” that creates a front-end profile (among other things) for your users. It will include the avatar field from this plugin, and it works very well.

    Or Theme My Login.

    nicolaelvin

    @nicolaelvin

    @xnau yes Front End Users does display the avatar and upload button, but it doesn’t actually work. When you browse for the file and then click update, it doesn’t save the picture.

    nicolaelvin,

    I have it working on several installations, so the plugin does work. You need to go in and do some debugging: look for errors in your browser console, check your PHP error log.

    nicolaelvin

    @nicolaelvin

    xnau

    Ahh I am past that plugin now. I decided just to hard code all my profile fields in. I don’t know how now though to include the avatar field when I am now doing it by hand.

    Hi Xnau

    Is it also possible to use the “Front End Users” plugin to display the back end page of the “participant database” list of participants in the front end including all functionalities such as filters ?

    nicolaelvin,

    I use a plugin called “Simple Local Avatars” to deal with avatars, and there is a function in the plugin that you can include when you are defining your custom user fields. I don’t remember the code exactly, but the plugin is pretty simple, so it’s not hard to find the function that adds the avatar field.

    tmayombo,

    Since the users in the Participants Database plugin are not WordPress users “Front End Users” won’t be of any help. You kinda need to use one or the other for managing your users. Front End Users works really well for giving your users the ability to do all kinds of things on your website. Participants Database is really more for maintaining a list of people and their data. It doesn’t give those people any ability to log in to the website, and so there is no “profile” as such for those people.

    I had this working before but now it doesn’t save an avatar.

    Front-end Users – Simple local avatars.

    Im using thos code to add the upload box to the front end, but there is no save option. Any ideas?

    '<?php
    $myAv = new simple_local_avatars();
    $myAv->edit_user_profile($profileuser);
    ?>'

    Never mind, I figured it out!

    @florence hi!
    can you please share your solution??
    i am also trying to create this box for my users…
    thanks,
    oren

    Sure! I have a profile using a shortcode so I was looking for a box using a shortcode as well. Here’s how I did it:

    Instal Simple Local Avatars

    Install this plugin http://wordpress.org/extend/plugins/php-code-for-posts/

    Add a new shortcode and enter this code:

    <?php get_header();
    global $user_ID;
    if ($user_ID) {
    $user_info = get_userdata($user_ID);
    $id = $user_info->ID;
    }
     ?>
    
    <?php if(isset($_POST['user_avatar_edit_submit']))
          {
               do_action('edit_user_profile_update', $id);
          }
    ?>
    
    <form id="your-profile" action="" method="post">
        <?php
        $myAv = new simple_local_avatars();
        $myAv->edit_user_profile($user_info);
        ?>
        <input type="submit" name="user_avatar_edit_submit" value="OK"/>
    </form>

    Copy and paste the shortcode onto a page and voilla! There’s your front-end avatar uploader!

    Hi @florence,

    THANKS!

    it works great though i’m trying to add this feature into another profile front-end plugin (which provides avatars only on pro version..).

    BTW, the avatar image, for some reason, is not showing on the page (it DOES get updated on the “backstage”, but the code above keep showing the default avatar..

    thanks,

    oren

    Oh that’s weird… It works for me.. Try turning off your other plugins. Maybe there’s a conflict/

Viewing 15 replies - 1 through 15 (of 15 total)
  • The topic ‘[Plugin: Simple Local Avatars] Using this plugin in a front-end page.’ is closed to new replies.