이 플러그인은 최근 3개의 주요 워드프레스 출시와 시험 되지 않았습니다. 워드프레스의 좀 더 최근 버전으로 이용할 때 더 이상 관리되지 않고 지원되지 않고 호환성 문제가 있을 수 있습니다.

Primary Blog Switcher for SuperAdmins

설명

WordPress Multisite network plugin to allow Network Admin to set the “Primary Blog” (aka Primary Site) of a user while editing a user’s profile.

Well, for whatever reasons (usually users fiddling around – I use WP multisite in a school with students grades 4-12), users aren’t attached(or become unattached) to the correct “Primary Blog”.

This isn’t a deal breaker, but annoying when they login and are redirected to a blog that is not their expected primary. It also is annoying when I use other plugins to list user primary blog for display in a member directory, member profiles, etc.

Telling users to reset their primary blog at their own Dashboard->My Blogs is a fix, but the SuperAdmin(Teacher in my case) can head off the confusion first with this plugin. There is no other way(AFAIK) for the Network Admin to set the “Primary Blog” of a user while editing their profile.

Now, I can quickly scan the Network Admin list of users and edit profiles and set primary blogs of any user correctly.

I can also use my Menus plugin to toggle the My Sites menu item so users can no longer fiddle with the Primary Site switcher at all. Problem solved.

참고

The original code for the Primary Site switcher is in wp-admin-includes/ms.php. I’ve basically copied that, but changed get_current_user_id() to $edit_user = (int) $_GET['user_id']; and added it to the “edit_user_profile” hook.

The plugin can be used to add users to a “Special Blog” by uncomment(remove the /* and */) this section in the plugin code and change the $special_blog_id:

<optgroup label="Other Blogs"></optgroup>
<optgroup label="Special Blog">
<?php $special_blog_id = '63'; //
$special_blog = get_blog_details( $special_blog_id ); ?>
<option value='<?php echo $special_blog_id ?>'>http://<?php echo $special_blog->domain.$special_blog->path ?></option>
</optgroup>

설치

This section describes how to install the plugin and get it working.

  1. Upload the plugin to your blog, Network Activate it
  2. Edit user profiles as Network Dashboard->Users->Edit
  3. View Network Dashboard for notices of users who have the main blog set as their primary blog, or no blog at all.

FAQ

  • Can I set the Main blog as a user’s primary? Yes.

  • Can I set the Dashboard blog (if enabled) as a user’s primary? Yes.

  • Can I set Donncha’s Sitewide Tags blog (if enabled) as a user’s primary? Yes.

  • Can I add a user to some other blog “special blog” as their primary? Yes, but see “special blog” comments in the plugin code.

  • Does this plugin filter the list of blogs already listed at a user’s Dashboard->My Sites->Primary Site? No.

  • I can’t change a user’s primary blog, there are no blogs to choose from in the dropdown on their profile? Add the user first to a couple of blogs and try again.

후기

모든 2 평가 읽기

기여자 & 개발자

“Primary Blog Switcher for SuperAdmins”(은)는 오픈 소스 소프트웨어입니다. 다음의 사람들이 이 플러그인에 기여하였습니다.

기여자

자국어로 “Primary Blog Switcher for SuperAdmins”(을)를 번역하세요.

개발에 관심이 있으십니까?

코드 탐색하기는, SVN 저장소를 확인하시거나, 개발 기록RSS로 구독하세요.

변경이력

4.6

  • WP 4.6 tests OK, cleanup php notices