Page 1 of 1

customising wp-login

PostPosted: June 24th, 2010, 3:45 am
by accessart
Hi, I'd like to do this:
If you would like to have Customers register before checkout, you can turn on Open Registration.
See: s2Member -> General Options -> Open Registration.
You will need s2Member v3.0.6+

Once you turn on Open Registration, you can allow Customers to register first, for FREE. Then hit them with a payment button on the Login Welcome Page. You could use some of s2Member's Advanced Conditionals to tailor this specifically for your needs. s2Member also comes with a full set of WordPress Hooks/Filters embedded into its source code; giving you the ability to modify routines if you need to; and without modifying the original source code.

That being said, you really won't need to do this, unless you want to. Placing a PayPal Button on the Login Welcome Page for Free Subscribers, will allow a User ( who just registered ) to proceed through the checkout process, and s2Member will "update" their account, instead of asking them to register for a new one. s2Member handles this automatically, just in case you're wondering.


Pls can you tell me where //how I should customise wp-login? I knwo i need to get it to refer to the css of my theme, but where is s2member telling wp-login to have the s2member header/banner?

Many thanks

Re: customising wp-login

PostPosted: June 25th, 2010, 7:03 am
by k4yti

Re: customising wp-login

PostPosted: June 25th, 2010, 7:34 am
by accessart
thank you.
Pls can you clarify
Your stylesheet data goes here.


I'm sorry, specifically how do i refer or call to my style sheet?

Many thanks

Re: customising wp-login

PostPosted: June 26th, 2010, 1:45 am
by Jason Caldwell
You would just type your CSS declarations directly into that slot.
CSS tutorial here: http://www.w3schools.com/css/

Here is an example:
Code: Select all
<?php
add_filter
("ws_plugin__s2member_login_header_styles""my_login_styles");
function 
my_login_styles($s2member_styles)
    {
        echo 
'<style type="text/css">';
        
?>

         html, body { background: #000000; }
         div#login { width: 600px; }

        <?php
         
echo '</style>';

         return 
'';
    }
?>

Re: customising wp-login

PostPosted: June 26th, 2010, 1:46 am
by Jason Caldwell
If you wanted to load an external stylesheet, you could do this:
Code: Select all
<?php
add_filter
("ws_plugin__s2member_login_header_styles""my_login_styles");
function 
my_login_styles($s2member_styles)
    {
        echo 
'<style type="text/css">';
        include 
"/path/to/my/stylesheet.css";
        echo 
'</style>';

        return 
'';
    }
?>

Re: customising wp-login

PostPosted: June 26th, 2010, 2:32 am
by accessart
thanks!

Re: customising wp-login

PostPosted: July 20th, 2010, 12:52 am
by jambon
Jason Caldwell wrote:If you wanted to load an external stylesheet, you could do this:
Code: Select all
<?php
add_filter("ws_plugin__s2member_login_header_styles", "my_login_styles");
function my_login_styles($s2member_styles)
    {
        echo '<style type="text/css">';
        include "/path/to/my/stylesheet.css";
        echo '</style>';
    }
?>



That didn't work for me...

However I tried this and it seemed to work well:

<?php
add_filter("ws_plugin__s2member_login_header_styles", "my_login_styles");
function my_login_styles($s2member_styles)
{
echo "<link href='link to css file' rel='stylesheet' type='text/css' />";

}
?>

Re: customising wp-login

PostPosted: July 22nd, 2010, 7:49 am
by Jason Caldwell
Thanks for reporting back on this.
~ I see. It looks like I left the return statement out of my sample.
Sorry about that.

Here is the correct version:
Code: Select all
<?php
add_filter
("ws_plugin__s2member_login_header_styles", "my_login_styles");
function my_login_styles($s2member_styles)
    {
        echo '<style type="text/css">';
        include "/path/to/my/stylesheet.css";
        echo '</style>';

        return '';
    }
?>