• Would adding this to a template page have any security issues?

    <?php
      global $blog_id , $user_ID;
      get_currentuserinfo();
      $userid = $user_ID;
      $blogid = $blog_id;
      $role = 'subscriber';
      if ( add_user_to_blog( $blogid, $userid, $role ) ) {
        echo 'Added user '.$userid.' as '.$role.' to blog '.$blogid.'.';
      } else {
        echo 'Failed to add user '.$userid.' as '.$role.' to blog '.$blogid.'.';
      }
    ?>
Viewing 1 replies (of 1 total)
  • Thread Starter Alan

    (@holo-alan)

    Just thought this won’t work any way, as it will change all users to subscriber, when they hit the page with it on, not just the unassigned users..

    back to the drawing board I guess..

Viewing 1 replies (of 1 total)
  • The topic ‘Any Security Issues??’ is closed to new replies.