Skip to main content

Posts

Straight-forward Pure CSS Social Icons

This is a chunk of code I use on a lot of sites.  It uses Font Awesome to supply the fonts, but everything else is handled via CSS. Font Awesome To start, you'll need a Font Awesome account / link to use to import your font files (which will be used to show the social network icons). They will provide you with a script link you can put into your header.php, load into your functions.php and/or download locally and link locally...really, it's up to you how you load the script. The HTML code is just a simple list: <ul class="social-media-icons"> <li><a class="facebookBtn smGlobalBtn" href="https://www.facebook.com/yoursitehere" target="_blank"></a></li> <li><a class="linkedinBtn smGlobalBtn" href="https://www.linkedin.com/in/yoursitehere" target="_blank"></a></li> <li><a class="twitterBtn smGlobalBtn" href="https://twit
Recent posts

A Very Useful Script For Updating Your Wordpress Database After Migration

In PHPMyAdmin, you can run this to update the database to it's new destination: SET @oldsite='http://oldsite.com'; SET @newsite='http://newsite.com'; UPDATE wp_options SET option_value = replace(option_value, @oldsite, @newsite) WHERE option_name = 'home' OR option_name = 'siteurl'; UPDATE wp_posts SET post_content = replace(post_content, @oldsite, @newsite); UPDATE wp_links SET link_url = replace(link_url, @oldsite, @newsite); UPDATE wp_postmeta SET meta_value = replace(meta_value, @oldsite, @newsite); UPDATE wp_posts SET guid = replace(guid, @oldsite, @newsite); Don't forget to update the table names to match those in your database.

Failed to load resource: the server responded with a status of 412 - Fix

Recently, I ran into an issue with a Divi install I was running on a new server.  For whatever reason, it suddenly wasn't loading any of the scripts necessary. I tried rolling back the theme, but that didn't do anything.  I then tried re-installing Wordpress, but that didn't fix anything. A Google search led me to this article - https://wordpress.org/support/topic/failed-to-load-jquery-at-load-scripts-php/ Which led to this extremely quick fix: Try adding define('CONCATENATE_SCRIPTS', false); to your wp-config.php file just below the define('DB_HOST' line. After adding that to my wp-config file, everything worked as expected.

Disable on-screen keyboard that appears in Adobe products

So, I had an issue with Adobe inDesign on my Windows 10 PC. The onscreen keyboard kept popping up whenever I tried to edit text because the program couldn't tell that while I am on a touch screen enabled device, I do not have touch screens nor do I want an onscreen keyboard. To disable: Run: services.msc (windows key + R) Find the service called:  Touch Keyboard and Handwriting Panel Service (TabletInputService) Double click it to open up the Properties dialog You will want to not just stop the service, but disable it. Now, I still ran into a problem with the service restarting.  To fix this, click on the Recovery tab and change all the failure actions to Take No Action

Divi Theme - Remove pause 'on hover' of the full width slider

In the Divi theme, open up /js/custom.js Comment out the following code (around line 144) if ( settings.slideshow && et_slides_number > 1 ) { $et_slider.hover( function() { $et_slider.addClass( 'et_slider_hovered' ); if ( typeof et_slider_timer != 'undefined' ) { clearInterval( et_slider_timer ); } }, function() { $et_slider.removeClass( 'et_slider_hovered' ); et_slider_auto_rotate(); } ); }

Removing comments from the Wordpress Twenty Fourteen theme

To permanently remove comments from the Wordpress Twenty Fourteen theme, the file you will want to edit is: /themes/twentyfourteen/single.php Within this file, you will find the following code which you can either delete or comment out: // If comments are open or we have at least one comment, load up the comment template. if ( comments_open() || get_comments_number() ) { comments_template(); } Now, there is also meta  info for each content type which will list the number of comments next to the date the post was posted on under the title of each post.  You'll like want to remove this reference as well (otherwise, they will all say 0 comments). To do so, open up the content- .php  file in the theme folder.  For example, on a site I did this on, I edited the content-image.php  file. Look for the div with the class " entry-meta " and delete the line referencing " comments " within that div.  Just cull those lines.