Please upgrade here. These earlier versions are no longer being updated and have security issues.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.

Remove register button - sidebars jsconnect with wordpress

Hi guys,

Could anyone please let me know how to remove the register button on the sidebar of Vanilla - Wordpress embed forum?
File path please. It's ok if I need to modify core files of vanilla.

Cheers!

Best Answer

  • HalfCatHalfCat ✭✭
    Answer ✓

    At the end of this file: themes/EmbedFriendly/design/custom.css. And it is not necessary to have the !important part. Also I am not sure why it should be input#Form_Signup.Button. Maybe I'm missing something but this is what I would add:

    a.Button.RegisterLink, a.Button.ApplyButton {
        visibility:hidden;
        display:none;
    }
    

Answers

  • vrijvlindervrijvlinder Papillon-Sauvage MVP

    input#Form_SignUp.Button{display:none!important;}

  • Hi vrijvlinder,

    Could you please let me know where I need to add that please?
    Thank you.

  • HalfCatHalfCat ✭✭
    Answer ✓

    At the end of this file: themes/EmbedFriendly/design/custom.css. And it is not necessary to have the !important part. Also I am not sure why it should be input#Form_Signup.Button. Maybe I'm missing something but this is what I would add:

    a.Button.RegisterLink, a.Button.ApplyButton {
        visibility:hidden;
        display:none;
    }
    
  • vrijvlindervrijvlinder Papillon-Sauvage MVP

    That is what works for me HC, they should try everyone to see what they do. I use important because sometimes it will not work without it. But if it works without it then don't use it.

    Let us know ttce what happened...

  • businessdadbusinessdad Stealth contributor MVP

    I don't think that relying on CSS alone is a good idea, unless you are just looking to hide the button, but keep the registration process active. In such case, the solutions you received will work, just keep in mind that any User could look at the page source and open the button links manually.

    A more robust approach is not rendering the buttons at all, and it requires changing the theme code.

  • vrijvlindervrijvlinder Papillon-Sauvage MVP

    Yes true, css alone does not remove it across the board without a trace, it is good to selectively remove something from a specific page . I wonder why they want to remove the register access ?

  • Hi Guys, sorry for the late reply.

    • @HalfCat answer worked perfectly.
    • Solution of @vrijvlinder didn't work for me for some reason. Could you elaborate how or where do I need to add the code in? I tried adding it into custom.css - didn't do a thing.

    @vrijvlinder said:
    Yes true, css alone does not remove it across the board without a trace, it is good to selectively remove something from a specific page . I wonder why they want to remove the register access ?

    To answer the questions above:

    • My site is a Wordpress site with embed vanilla forum
    • I disable the registration process completely (this is a private site)
    • However, the register button is still showing.
    • I want to hide the register button for cosmetic purposes

    @businessdad said:
    I don't think that relying on CSS alone is a good idea, unless you are just looking to hide the button, but keep the registration process active. In such case, the solutions you received will work, just keep in mind that any User could look at the page source and open the button links manually.
    A more robust approach is not rendering the buttons at all, and it requires changing the theme code.

    @businessdad
    Could you please let me know how to modify the theme code so it won't render the register / sign in pop up and apply button?
    (Basically all the thing related to registration process of Vanilla)
    All should show up is jsconnect SignIn Link button.

    So far solution of @HalfCat worked for me. However, like you said, user could look at the page source and open the button links manually.

    BTW, you guys are awesome!

  • businessdadbusinessdad Stealth contributor MVP

    @ttce If you want to disable registration completely, and rely solely on JsConnect, you can do it from Vanilla Admin. Go to Admin -> Users -> Registration and choose "Connect".

  • @businessdad. That's what I'm saying. Even if you do that, the register button is still showing.
    That's the reason I need to use @halfcat code to hide it.
    I don't know why! I disabled registration in both Wordpress and Vanilla, still the same.

  • businessdadbusinessdad Stealth contributor MVP
    via Email
    Sorry for the misunderstanding. In such case, I reckon that modifying the
    theme files will solve the issue once for all.
    As for which file (s) to change, I reckon that @peregrine or @kasperisager
    could answer faster than me (I'm not the best with themes).
  • If you select "Connect" as Registration method in the Dashboard, the register button actually points to the location you specified in your jsconnect settings. If you just let it point to nowhere, there shouldn't be an issue with anyone registering be re-enabling the button with css.

    It is of course cleaner if you don't render it in the first place but to achieve that, you need to dig deep in the themehooks of which I am no expert.

  • vrijvlindervrijvlinder Papillon-Sauvage MVP
    edited December 2012

    What you could do is change the definition of the button to say connect instead of register , since the link goes to connect. If you used display:none only someone bent on finding hidden links would look at the page source, the hidden links appear greyed out.

    You could also make an entry page with only the login form for your members. Only members would have a link to the page to login. The ExtraPage plugin might work for you, or just make a fresh page with only the login form. here is an idea of how to do this :

    http://processwire.com/talk/topic/11-how-do-i-create-private-client-pages-with-login/

    A plugin which allowed to selectively disable and not render something would come in handy...I would call it HideThis ;)

    Also you could disable the panel altogether, the only thing that appears in the panel are the register sign in buttons and the categories. You can use categories2Menu Plugin for a drop down on the menu of the categories.
    There should be a way to disable the guest module. I still searching....

  • businessdadbusinessdad Stealth contributor MVP

    @vrijvlinder I agree with the idea of a plugin which allows to show/hide elements. Unfortunately, the rendering engine is not really the best from this perspective, and often, when themes and plugins render elements conditionally, they just delete them after they have been added to the Content or the Panel. In my opinion, this is not ideal, it's actually quite a rough method.

  • vrijvlindervrijvlinder Papillon-Sauvage MVP
    edited December 2012

    maybe changing the config.php :

    $Configuration['Garden']['Modules']['ShowGuestModule'] = FALSE;

    $Configuration['Garden']['SignIn']['Popup'] = FALSE;

Sign In or Register to comment.