PriMoThemes — now s2Member® (official notice)

This is now a very OLD forum system. It's in READ-ONLY mode.
All community interaction now occurs at WP Sharks™. See: new forums @ WP Sharks™

Removing the default CSS

s2Member Plugin. A Membership plugin for WordPress®.

Removing the default CSS

Postby Stephem » January 2nd, 2012, 12:43 am

I'm trying to remove the default CSS s2Member produces from the head:

Code: Select all

<link rel="stylesheet" id="ws-plugin--s2member-css" href="http://site.com/spa/wp-content/plugins/s2member/s2member-o.php?ws_plugin__s2member_css=1&#038;qcABC=1&#038;ver=111220-111220-1212004154" type="text/css" media="all" />



I searched these forums and found a solution but it simply isn't working.

How can I prevent s2Member Pro from loading it's default CSS?

You can create this directory and file: /wp-content/mu-plugins/s2-hacks.php

Code: Select all

<?php
add_action ("ws_plugin__s2member_after_loaded", "remove_s2_pro_css");
function remove_s2_pro_css ()
    {
        remove_action ("ws_plugin__s2member_during_css", "c_ws_plugin__s2member_pro_css_js::css");
    }
?>




Any idea's as to why it's not being removed?
User avatar
Stephem
Registered User
Registered User
 
Posts: 16
Joined: January 2, 2012

Re: Removing the default CSS

Postby Cristián Lávaque » January 3rd, 2012, 5:54 am

Did you try clearing the cache?
Cristián Lávaque http://s2member.net
Is s2Member working for you? Please rate it Image at WordPress.org. Thanks! :)
User avatar
Cristián Lávaque
Developer
Developer
 
Posts: 6836
Joined: December 22, 2010

Re: Removing the default CSS

Postby thelastminute » January 7th, 2012, 1:07 pm

I'm also having this same issue.

I have cleared all the caches as well.

Any thoughts?
User avatar
thelastminute
Registered User
Registered User
 
Posts: 2
Joined: December 1, 2011

Re: Removing the default CSS

Postby Stephem » January 7th, 2012, 6:55 pm

thelastminute wrote:I'm also having this same issue.

I have cleared all the caches as well.

Any thoughts?


Add this to your functions.php file:

Code: Select all

add_action( 'wp_print_styles', 'my_deregister_styles', 100 );

function my_deregister_styles() {
   wp_deregister_style('ws-plugin--s2member');
}

remove_action("ws_plugin__s2member_during_css", "c_ws_plugin__s2member_pro_css_js::css");

add_filter("ws_plugin__s2member_login_header_styles", "__return_false");



I'm not sure if all that is needed but it works.
User avatar
Stephem
Registered User
Registered User
 
Posts: 16
Joined: January 2, 2012


Return to s2Member Plugin

Who is online

Users browsing this forum: Google [Bot] and 2 guests

cron