Archives: Tutorials

How to use CRON wget?

/usr/bin/wget -O -q ‘http://http://www.renzramos.com/your-script.php?key=test’

Read more

Validate Form Fields using jQuery

function validateField(element, e){ var restriction = element.attr(‘data-restriction’); var errorText = element.attr(‘data-error-text’); var required = element.attr(‘data-required’); var name = element.attr(‘name’); var label = element.siblings(‘label’).html(); var tagName = element.prop(‘tagName’).toLowerCase(); var value = element.val(); if (typeof restriction !== ‘undefined’){ if (restriction == ‘numeric’){ if (typeof e !== ‘undefined’){ // Allow: backspace, delete, tab, escape, enter and . if […]

Read more

Cryptocurrencies Converter

https://github.com/renzramos/cryptocurrency-calculator-converter

Read more

Generate sitemap for WordPress GTranslate

https://github.com/renzramos/generate-sitemap-for-wordpress-gtranslate

Read more

Easy Transient integration for WP Query

What is Transient API? The Transients API is very similar to the Options API but with the added feature of an expiration time, which simplifies the process of using the wp_options database table to temporarily store cached information. Reference: https://codex.wordpress.org/Transients_API Function Add this yo your functions.php // wp query transient function wp_query_transient($transient_key, $args){ $query = […]

Read more

WordPress – Remove query version string from static resources

Add to theme functions.php // remove query string from static files function remove_script_version_query_string( $src ) { if( strpos( $src, ‘?ver=’ ) ) $src = remove_query_arg( ‘ver’, $src ); return $src; } add_filter( ‘style_loader_src’, ‘remove_script_version_query_string’, 10, 2 ); add_filter( ‘script_loader_src’, ‘remove_script_version_query_string’, 10, 2 );

Read more