Forum Replies Created

Viewing 2 replies - 1 through 2 (of 2 total)
  • big24fan

    This has the changes recommended by jakobneander

    https://rauliweb.com/user-photo.php.txt

    copy and paste the text into an empty text document and save as user-photo.php using notepad or something similar then rename the old user-photo.php file in its plugins folder, then upload to the same folder and test it.

    If it don’t work your theme might interefere with it, as I discovered with the Easel theme I am using on one project.

    Enjoy it while its up!

    Rauli

    (@rauli)

    The New Post column layout by default is 2 if the usermeta data for this setting is otherwise (which can only be 1) does not exist in the database.

    The following code added to your themes functions.php should update the currently logged in users meta data (if the field does not already exist) to set the column layout of the New Post screen to 1. In this way all new registrations default to that 1 column layout immediately:-

    <?php
    /*Set the default column layout in the New Post section to one column for new users*/
    global $current_user;
    get_currentuserinfo();
    $user_id = $current_user->ID;
    $prev_value = NULL;
    update_user_meta($user_id, screen_layout_post, 1, $prev_value);
    ?>

    [Please post code snippets between backticks or use the code button.]

    I put this code right at the bottom (after the last ‘?>’)of my functions.php of my mystique theme.

    Hope this helps, I spent ages looking for this and had to work it out myself.

    Regards,
    Rauli

Viewing 2 replies - 1 through 2 (of 2 total)