How to use internal css in WordPress

One of the way to load CSS in your WordPress plugin. You no need to worry about caching while developing your code and no need to separate one more file.

function my_style_inline() {
  $content = file_get_contents(ABSPATH . 'wp-content/plugins/PLUGINNAME/CSSFILENAME.css');
  echo '<style type="text/css">' . "\n";
  echo $content;
  echo "</style>\n";
add_action('wp_head', 'my_style_inline');

Use CSS to do fade text from Black to White at tail.

I found out that using this way to white fade out the text.

[code lang=”html”]
<div style="font-size: 6pt;
overflow: hidden;
text-decoration: none;
position: relative;
white-space: nowrap;
-webkit-mask-image: -webkit-linear-gradient(left, rgba(0, 0, 0, 1), rgba(0, 0, 0, 1), rgba(0, 0, 0, 1), rgba(0, 0, 0, 0) 99%);">
Fade away my text</div>

How to remove ver from js and css in WordPress ?

Remove the ver=date behind the JS and CSS in wordpress.

// Load in any own plugin
function juz_remove_wp_ver_css_js( $src ) {
if ( strpos( $src, ‘ver=’ ) )
$src = remove_query_arg( ‘ver’, $src );
return $src;
add_filter( ‘style_loader_src’, ‘juz_remove_wp_ver_css_js’, 9999 );
add_filter( ‘script_loader_src’, ‘juz_remove_wp_ver_css_js’, 9999 );

Remove ver version number for JS and CSS in WordPress

The varnish load so much of different version in my wordpress, so I would like to remove all the ver from the source.

    53.76 RxURL          /wp-content/themes/responsivepro/core/js/responsive-modernizr.js?ver=2.6.1
    51.22 RxURL          /wp-content/themes/responsivepro/core/js/responsive-scripts.js?ver=1.2.4
    16.12 RxURL          /wp-includes/js/jquery/jquery.js?ver=1.10.2
    15.70 RxURL          /wp-includes/js/jquery/jquery-migrate.min.js?ver=1.2.1
    15.59 RxURL          /wp-content/themes/responsivepro/core/css/style.css?ver=
    15.59 RxURL          /wp-content/themes/responsivepro/pro/lib/css/style.css?ver=1.0
    15.58 RxURL          /wp-content/plugins/RadControl/js/adclk.js?ver=2013-06-21
    15.56 RxURL          /wp-content/themes/responsivepro/style.css?ver=
    15.56 RxURL          /wp-content/plugins/jetpack/modules/widgets/wid

Solution to solve

Add this into your functions.php in your theme.
You can access from Apperance –> Editor
Then you try to to put this code to update the file.

function _remove_script_version( $src ){
$parts = explode( '?', $src );
return $parts[0];
add_filter( 'script_loader_src', '_remove_script_version', 15, 1 );
add_filter( 'style_loader_src', '_remove_script_version', 15, 1 );