Forums

[Plugin: Contact Form 7] Put all Contactform CSS in style.css theme (3 posts)

  1. binbin
    Member
    Posted 3 years ago #

    Hello,

    To have only one css file, I would like to put all css of contact form 7 in my stlye.css of my theme.

    But how I can change the path to ask him to take the css in my style.css, I have check in wp-contact-form-7.php but can't find the way to do this...

    thanks

    http://wordpress.org/extend/plugins/contact-form-7/

  2. Luke Rumley
    Member
    Posted 3 years ago #

    I posted my response to the wrong thread. So I am really dumb. :)

    To answer this post, I usually copy the CSS to my main stylesheet to override styles, but if you are concerned about performance, you will need to dive into the PHP and edit out the CSS link.

  3. lymdul
    Member
    Posted 3 years ago #

    You can do this by deregistering the plug-in's css and append your custom css in your style.css

    put this code in your theme's function.php:

    add_action( 'wp_print_styles', 'my_deregister_styles', 100 );
    
    function my_deregister_styles() {
    	wp_deregister_style( 'contact-form-7' );
    }

    you can also deregister any javascripts and styles
    http://justintadlock.com/archives/2009/08/06/how-to-disable-scripts-and-styles

Topic Closed

This topic has been closed to new replies.

About this Topic