Title: Few modifications
Last modified: August 20, 2016

---

# Few modifications

 *  Resolved [madri2](https://wordpress.org/support/users/madri2/)
 * (@madri2)
 * [13 years, 2 months ago](https://wordpress.org/support/topic/few-modifications/)
 * Hello,
 * I’m trying this plugin and i see that the new registration page doesn’t use the
   localisations of the wordpress core.
    Can you use the same sentances that the
   original register page and use the localisation of wordpress core ?
 * And also, unfortunately, even on a subsite, the page says “get a user accounts
   on *name of the network*” instead of *name of the subsite*
 * And another problem, is that when i go on the wp-login page, if i clic on the
   register link, it redirect me to the main site instead of that new registration
   page.
 * [http://wordpress.org/extend/plugins/join-my-multisite/](http://wordpress.org/extend/plugins/join-my-multisite/)

Viewing 15 replies - 1 through 15 (of 30 total)

1 [2](https://wordpress.org/support/topic/few-modifications/page/2/?output_format=md)
[→](https://wordpress.org/support/topic/few-modifications/page/2/?output_format=md)

 *  Plugin Author [Ipstenu (Mika Epstein)](https://wordpress.org/support/users/ipstenu/)
 * (@ipstenu)
 * 🏳️‍🌈 Advisor and Activist
 * [13 years, 2 months ago](https://wordpress.org/support/topic/few-modifications/#post-3563852)
 * The strings had to be changed because not all of the form gets used. It’s not
   a 1-1 copy from wp-signup.php in order to prevent collisions and errors when 
   running with certain themes. If you want to submit a translation, the plugin 
   is localized so I’m happy to take any files. I used MOST of the same sentences(
   whenever I could), but localized per the plugin. That’s what happens when you
   strip out the site creation stuff.
 * And that is also the reason why it still says “get a user accounts on *name of
   the network*” instead of *name of the subsite* you see 🙂 I didn’t override the
   defaults.
 * Finally, why the wp-login page still sends you to the default… is because I have
   no way to easily detect you came from there. You’ll have to handle that on your
   own, by .htaccess redirects per site.
 *  Thread Starter [madri2](https://wordpress.org/support/users/madri2/)
 * (@madri2)
 * [13 years, 2 months ago](https://wordpress.org/support/topic/few-modifications/#post-3563868)
 * while looking at the code, i found in singuppage.php, function validate_user_signup,
   
   this code
 *     ```
       if ( 'blog' == $_POST['signup_for'] ) {
       		signup_blog($user_name, $user_email);
       		return false;
       	}
       ```
   
 * but i don’t want users to be able to create a blog
 * the form does not contain the menu to choose between a blog or just a username,
   but if the user modify the request manually, he will be able to create a blog
   anyway, while it shouldn’t
    this is quite a big security bug
 *  Thread Starter [madri2](https://wordpress.org/support/users/madri2/)
 * (@madri2)
 * [13 years, 2 months ago](https://wordpress.org/support/topic/few-modifications/#post-3563877)
 * for some reason unknown to me,
    $current_site return the main site and $current_site-
   >blog_id is wrong but the global var blog_id return the right blog id
 * on function signup_user you should use :
    global $blog_id; $blog_details = get_blog_details(
   $blog_id);
 * instead of
    $blog_details = get_blog_details($current_site->blog_id);
 *  Plugin Author [Ipstenu (Mika Epstein)](https://wordpress.org/support/users/ipstenu/)
 * (@ipstenu)
 * 🏳️‍🌈 Advisor and Activist
 * [13 years, 2 months ago](https://wordpress.org/support/topic/few-modifications/#post-3563878)
 * If you don’t want users to create a blog, you turn off the option in the network
   for that. It’s not the scope of the plugin and it’s not a security bug or a bug
   at all. Are you trying to only allow -some- blogs to allow users to create blogs?
   Otherwise, just turn it off and move on.
 * > $current_site return the main site and $current_site->blog_id is wrong but 
   > the global var blog_id return the right blog id
 * I’ll check but it was working fine for me.
 *  Thread Starter [madri2](https://wordpress.org/support/users/madri2/)
 * (@madri2)
 * [13 years, 2 months ago](https://wordpress.org/support/topic/few-modifications/#post-3563879)
 * the option to prevent the users to create a blog is checked, but i think that
   “
   signup_blog()” does not take into account that parameter i think the parameter
   is only here to check if that function should be called or not i only want that
   the super admin can create a blog
 * also, i’ve found out how to redirect the registration button to the page you 
   defined in the settings
 * in shortcode.php, at the beggining, add :
 *     ```
       function jmm_signup_location($val) {
       	$jmm_options = get_option( 'helfjmm_options' );
       	if ( !is_null($jmm_options['perpage']) && $jmm_options['perpage'] != "XXXXXX"  )
       		{ return get_permalink($jmm_options['perpage']); }
       	return $val;
       }
       add_filter('wp_signup_location', 'jmm_signup_location');
       ```
   
 * because when the url /wp-login.php?action=register
    is get, the filter wp_signup_location
   is hooked to checked if we want a special location for the registration.
 * By default, it will redirect to network_site_url(‘wp-signup.php’) which will 
   use “$current_site” to know the path, but current_site equals the main site, 
   not the current blog… so it redirect to the main site
 * edit1:
    signup_blog (in case wpmu_signup_blog) will not do any parameter verification
   [http://codex.wordpress.org/WPMU_Functions/wpmu_signup_blog](http://codex.wordpress.org/WPMU_Functions/wpmu_signup_blog)
   [http://wpseek.com/wpmu_signup_blog/](http://wpseek.com/wpmu_signup_blog/)
 * so you should verify the setting before calling that function
 * edit2:
    i don’t really understand why you didn’t used the localisations from 
   wordpress. Remove the ‘helfjmm’ at every translation and it will work. I don’t
   see any reason to not work with some themes. Also, the button to register is 
   labelled as “Register” and not “Sign Up” in the wordpress registration page
 * edit3:
    here is a diff with the changes I proposed: [http://uptobox.com/n66h0w71go9a/diff.html](http://uptobox.com/n66h0w71go9a/diff.html)
 *  Thread Starter [madri2](https://wordpress.org/support/users/madri2/)
 * (@madri2)
 * [13 years, 2 months ago](https://wordpress.org/support/topic/few-modifications/#post-3563880)
 * signup_blog (in case wpmu_signup_blog) will not do any parameter verification
   
   [http://codex.wordpress.org/WPMU_Functions/wpmu_signup_blog](http://codex.wordpress.org/WPMU_Functions/wpmu_signup_blog)
   [http://wpseek.com/wpmu_signup_blog/](http://wpseek.com/wpmu_signup_blog/)
 * so you should verify the setting before calling that function
 *  Thread Starter [madri2](https://wordpress.org/support/users/madri2/)
 * (@madri2)
 * [13 years, 2 months ago](https://wordpress.org/support/topic/few-modifications/#post-3563883)
 * edit4:
    oh, and it’s printf( __( ‘Get your own %s account in seconds’), $blog_details-
   >blogname ) instead of printf( __( ‘Get a user account on %s in seconds’), $blog_details-
   >blogname )
 *  Plugin Author [Ipstenu (Mika Epstein)](https://wordpress.org/support/users/ipstenu/)
 * (@ipstenu)
 * 🏳️‍🌈 Advisor and Activist
 * [13 years, 2 months ago](https://wordpress.org/support/topic/few-modifications/#post-3563885)
 * > the option to prevent the users to create a blog is checked, but i think that“
   > signup_blog()” does not take into account that parameter
 * I cannot reproduce this. I installed on a fresh instance of WP, set up my network
   to ONLY permit users to create accounts, and the signup page is not only just
   for accounts, but it keeps the user on the page, on that site. Works exactly 
   as expected (with an empty param warning I’ll fix).
 * You’ll need to explain, in clearer detail, what your setup is on the network (
   what registration option did you pick), and what ones you picked on the site,
   if you want me to debug this fully. Right now, using the plugin as I intended,
   it does what I intended, so I can only guess you’re doing something unexpected
   🙂 That’s not BAD, but I want to make sure it’s within the scope of what I want
   to support and maintain.
 * What I did:
 * 1) Network settings – Users can register
    2) Network activated the plugin 3) 
   Per site: manual registration, checked ‘per site’ and picked my page ‘join.’ 
   4) Put the shortcode in join
 * Then as a logged out user, I went to join and it correctly showed me just what
   I should see: [http://cl.ly/image/3z0M1s3x2O3i](http://cl.ly/image/3z0M1s3x2O3i)
 * > Also, the button to register is labelled as “Register” and not “Sign Up” in
   > the wordpress registration page
 * That brings up **exactly** why I use helfjmm.
 * The reason I’m using helfjmm is that if WP changed and I wasn’t, everything would
   break. On the other hand, if I use my own and people submit language packs, I’ll
   add them and no one will break. I’m not going to change it back right now, it
   works the way I want it to. If you want to submit a language pack, I’ll add it
   and credit you 🙂
 * In the next version of WP it will be Signup (one word).
 * I’m fixing the param warning, and cleaning the translation. Submissions always
   welcome.
 *  Thread Starter [madri2](https://wordpress.org/support/users/madri2/)
 * (@madri2)
 * [13 years, 2 months ago](https://wordpress.org/support/topic/few-modifications/#post-3563886)
 * there is an empty input containing
    <input id=”signupblog” type=”hidden” name
   =”signup_for” value=”user” />
 * if by example, you save the page in your hard drive and change it to value=”blog”(
   or you can use the plugin tamper data in firefox to change it on the fly to blog),
   your plugin will interpret it as a blog creation
 * did you looked at my code to redirect automatically to the right page and to 
   display the name of the blog instead of the main site ?
 * for the strings, then the best thing to do will be to extract the strings from
   the default language pack and import them to your project 🙂
 *  Plugin Author [Ipstenu (Mika Epstein)](https://wordpress.org/support/users/ipstenu/)
 * (@ipstenu)
 * 🏳️‍🌈 Advisor and Activist
 * [13 years, 2 months ago](https://wordpress.org/support/topic/few-modifications/#post-3563887)
 * > for the strings, then the best thing to do will be to extract the strings from
   > the default language pack and import them to your project 🙂
 * That’s subjective. I don’t want to, I would rather use them as a starting point,
   to allow me to customize both layout and language. Take it or leave it.
 * > there is an empty input containing
   >  `<input id="signupblog" type="hidden" name
   > ="signup_for" value="user" />`
 * That’s supposed to be there. It’s required (and if you read wp-signup.php, you’ll
   see it’s there too):
 *     ```
       <p>
       		<?php if ( $active_signup == 'blog' ) { ?>
       			<input id="signupblog" type="hidden" name="signup_for" value="blog" />
       		<?php } elseif ( $active_signup == 'user' ) { ?>
       			<input id="signupblog" type="hidden" name="signup_for" value="user" />
       		<?php } else { ?>
       			<input id="signupblog" type="radio" name="signup_for" value="blog" <?php checked( $signup_for, 'blog' ); ?> />
       			<label class="checkbox" for="signupblog"><?php _e('Gimme a site!') ?></label>
       			<br />
       			<input id="signupuser" type="radio" name="signup_for" value="user" <?php checked( $signup_for, 'user' ); ?> />
       			<label class="checkbox" for="signupuser"><?php _e('Just a username, please.') ?></label>
       		<?php } ?>
       		</p>
   
       		<p class="submit"><input type="submit" name="submit" class="submit" value="<?php esc_attr_e('Next') ?>" /></p>
       ```
   
 * Plugin don’t work without it, I tried.
 * > did you looked at my code to redirect automatically to the right page and to
   > display the name of the blog instead of the main site ?
 * I did and again, I can’t reproduce it NOT redirecting correctly. If you’re not
   willing to give me the info I asked for, I can’t help you with that. When I make
   a custom registration page, I’m always redirected to where I expect.
 * Are you still on about how going to domain.com/site/wp-login.php and clicking
   register THERE sends you to the wrong place?
 * As for the name of the blog vs main site, I’m thinking about it.
 *  Thread Starter [madri2](https://wordpress.org/support/users/madri2/)
 * (@madri2)
 * [13 years, 2 months ago](https://wordpress.org/support/topic/few-modifications/#post-3563890)
 * okay, i was wrong about the modification to value=blog
 * for the redirection, sorry for the lack of details
    my params: Network settings–
   Users can register
 * the plugin conf:
    Membership : none Registration Per-Site and a custom registration
   page configured
 * the “register” button on wp-signup looks like that :
    [http://www.subsite.com/wp-login.php?action=register](http://www.subsite.com/wp-login.php?action=register)
   and redirect to : [http://www.mainsite.com/wp-signup.php](http://www.mainsite.com/wp-signup.php)
 * mainsite.com is the blog 1 and the site 1
    subsite is the blog 2 and is in the
   site 1
 *  Plugin Author [Ipstenu (Mika Epstein)](https://wordpress.org/support/users/ipstenu/)
 * (@ipstenu)
 * 🏳️‍🌈 Advisor and Activist
 * [13 years, 2 months ago](https://wordpress.org/support/topic/few-modifications/#post-3563891)
 * You’re on the wrong page: [http://subsite.com/](http://subsite.com/)**custompage**
 * Why are you going to [http://www.subsite.com/wp-signup.php](http://www.subsite.com/wp-signup.php)?
 *  Thread Starter [madri2](https://wordpress.org/support/users/madri2/)
 * (@madri2)
 * [13 years, 2 months ago](https://wordpress.org/support/topic/few-modifications/#post-3563892)
 * oops i mean wp-login instead of “the register button on wp-signup” -> “the register
   button on wp-login”
 * i go on [http://www.subsite.com/wp-login.php](http://www.subsite.com/wp-login.php)
   
   i click on register button, which redirect on the [http://www.mainsite.com/wp-signup.php](http://www.mainsite.com/wp-signup.php)
 *  Plugin Author [Ipstenu (Mika Epstein)](https://wordpress.org/support/users/ipstenu/)
 * (@ipstenu)
 * 🏳️‍🌈 Advisor and Activist
 * [13 years, 2 months ago](https://wordpress.org/support/topic/few-modifications/#post-3563895)
 * Same answer. You’re going to the _wrong page_ 🙂
 * Go to subsite.com/custompage
 * You know that page you said you made when you said “and a custom registration
   page configured”? Go there.
 * This plugin does not change /wp-login.php nor does it change wp-signup.php
 *  Thread Starter [madri2](https://wordpress.org/support/users/madri2/)
 * (@madri2)
 * [13 years, 2 months ago](https://wordpress.org/support/topic/few-modifications/#post-3563896)
 * yes but imagine you are a guest, browsing the site
    you click on “login”, and
   then you see that you don’t have an account, then you click on register to register
   on the website. but the url is not the custompage.
 * I provided you some code to replace the link of “wp-signup” to “custompage” automatically!

Viewing 15 replies - 1 through 15 (of 30 total)

1 [2](https://wordpress.org/support/topic/few-modifications/page/2/?output_format=md)
[→](https://wordpress.org/support/topic/few-modifications/page/2/?output_format=md)

The topic ‘Few modifications’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/join-my-multisite_e0d5c8.svg)
 * [Join My Multisite](https://wordpress.org/plugins/join-my-multisite/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/join-my-multisite/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/join-my-multisite/)
 * [Active Topics](https://wordpress.org/support/plugin/join-my-multisite/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/join-my-multisite/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/join-my-multisite/reviews/)

 * 30 replies
 * 2 participants
 * Last reply from: [madri2](https://wordpress.org/support/users/madri2/)
 * Last activity: [13 years, 1 month ago](https://wordpress.org/support/topic/few-modifications/page/2/#post-3563986)
 * Status: resolved