How to limit characters in widget titles

How to limit characters in widget titles

Recently I had a request from a client to “make the titles in widget shorter”.

The thing that bummed me out was that the widget “recent posts” was a core file from wordpress. The problem with this was the fact that if you modify wordpress core file, at the next update, the file would get rewritten… So after some research on how to get this done, i’ve decided to take a break, as i couldn’d find a solution that woked. At a later time and with a fresh mind i took another aproach on this.

I tought that it must be some plugin that i can use in order to have a new widget with the same functions that the core file has, and to write that down. I found Custom Recent Post Widget can do this for me and i was so happy. Now all i had to do was to find the files that i needed to edit and to write some code over there… and that is what i’ve done.

Here is an example of how i did just that

1. Install and activate Custom Recent Post Widget
2. With your FTP client search inside the plugin folder search for includes>crpw-cat.php and open this file
3. Now you shoud find the class crpw-item, and inside that search for the tag (about line 52) like in the code below

<br />
<!--?php the_title(); ?--><br />

4. Replace the code above with this one

<br />
<a class="crpw-title" title="Permanent link to <?php the_title_attribute(); ?>" href="<?php the_permalink(); ?>" rel="bookmark"><!--?php if ( get_the_title() ) { $t = get_the_title(); $t = substr($t, 0, 40); /// if this doesn't work } echo mb_strimwidth(get_the_title(), 0, 50, '...'); ?--></a><br />

the next text

How to upgrade to PHP7 version from .htaccess

How to upgrade to PHP7 version from .htaccess

In case that you can’t use the PHP Version Manager in cPanel, you can change your PHP version by adding a line of code to your .htaccess file of your wordpress website.

To apply these changes you can use a FPT software like FileZilla (this is what i usually use). Locate your .httaccess file and at the top of the document add the following line of code:

AddType application/x-httpd-php71 .php

Or this line of code if the first one doesn’t work for you

Action application/x-httpd-php71 /cgi-sys/php71-fcgi-starter.fcgi

Here is an example

That’s all there is to it.

Windows 10 KB4056892 (16299.192) fails to install with error 0x80073715

Windows 10 KB4056892 (16299.192) fails to install with error 0x80073715

If you found this article there is no doubt that you already heard of Meltdown and Spectre security flaws, so i’m going to get straight to the point.

On my first atempt to install the patch KB4056892 Microsoft roled out for Windows 10, i’ve got the error 0x80073715.  I found articles on what to do and how to update the software, but nothing related to this specific error with this update and what is the connection between them. And i’ve starded to digg around so you don’t have to. Ultimately i tought that i might apply the simplest solution: Do a disk cleanup.

First let me share with you what i have tried and didn’t worked for me:

  1. Quick check from command line to see if the system is affected
  2. Troubleshoot > Windows Update > Run the troubleshoot – FAIL!
  3. Manualy download&install from online catalog the Cumulative Update for Windows 10 version 1709 for x64-based Systems – FAIL!
  4. Manualy download&install the Delta Update for Windows 10 version 1709 for x64-based Systems – FAIL!
  5. Edit the registry  (but if you’re not comfortable doing this YOU SHOULD NOT DO IT) – FAIL! (the registry was fine, it didn’t needed to be edited)

If you’d like to try more solutions, have a look at this article from lifehacker. Before you start it might be a good idea to backup first or at least make a restore point for Windows.

The simplest solution that worked for me and didn’t think of it the first time (why?? :)) )

  1. Search for Disk Cleanup tool in your system.
  2. Select the drive where your Windows 10 is ( this is C:\ in most cases)
  3. Click Clean up system files and select your C:\ drive again
  4. Check Windows Update Cleanup
  5. Hit OK and wait for the process to finish
  6. Go to Windows Update Settings and hit update again.

It might be a good ting to update all your drivers to the latest versions.

Now glad that it worked out. Sometimes we tend to complicate things and forget to try out the simplest solutions first. This is what happen this time… i’ve did the complicated things first without thinking that i should try the basic ones.

This reminded me of the  first rule of IT.  Turn it off and turn it back on again! 

Share this with firends, you might be able to help them out.

How to change WordPress directory name

How to change WordPress directory name

WordPress has alot of flexibility when it comes to moving it’s core file and folder structure, or  like in our case, to change the Wordpress directory name. For example, you may have a wordpress installation like and you want to change that to There are a few options out there, but I will show you two solutions on how to achive this. 

The most important thing before anything: Backup First! 

Solution #1 – A fast way to do it (but not so safe in my opinion)

If you are a developer and you operate on non-live enviroment like localhost or a test server, then this is a solution for you.  If you’re not comfortable with this, go ahead and look for my other solution.  

  1. Open your FTP software (I use FilleZilla), navigate to your installation folder /myblog and change the folder name /mynewblog. 
  2. Open and browse for the tool named “Search and replace” and get your download from this non-affiliate link 
  3. Now extract the php file whitin the zip file you recived and as a precaution, rename the file with something unique (geodajk.php for example). Upload this file to your folder (the one you just renamed). 
  4. Open the browser and enter the URL of the file uploaded in step 3. It should look similar to this: “”.  
  5. Once the page loads, click “Submit” and enter your database details in the text fields. On the next page, insert the old URL in the “search for” text field and the new URL in the “Replace with” text field. To continue, click the “Submit Seach String” button. 
  6. Once this is done, go to your FTP program and delete the Search and Replace tool you’ve uploaded in the first place. 

Solution #2 – Cloning your wordpress installation 

If you don’t want to get messy with my previows solution, here is something that you can use to achive the same result (is not that complex as it looks).  

  1. Login to your website, go to Plugins>Add new and search for “WP Clone by WP Academy”. Install, activate the plugin and navigate to Dashboard> WP Clone 
  2. Click “Create Backup” and wait for the process to complete. After the process is complete, click “Copy URL” and save it for later use.  
  3. Open your FTP software (I use FileZilla) and search for your root folder. Over there create a new folder with the desired name like /mynewblog and install wordpress as you normaly do. If you are a cPnel or Plesk user, use that to make a new worpress install (I will not get into that in this article). 
  4. In your new wordpress installation add the WP Cone plugin like we did in step 1 
  5. Now that you have installed the plugin, go to WP Clone, select “Restore from URL”, enter the URL saved in step 2 and click “Restore Backup” 
  6. After the process is complete, you might need to instal a new plugin called “Better Search and Replace”. In “Search for” paste the old link and in “Replace with” enter the new path like Select all databases and If you’d like to skip de “dry” replacement, uncheck the last checkbox and click “Run Search/Replace” 
  7. Now you can delete the old folder installation with FTP. Be aware not to uninstall and delete the old database as it is used for the new installation. 
  8. Now you’re good to go! 
How to fix “Divi Builder Timeout” Error

How to fix “Divi Builder Timeout” Error

In this article i’m going to show you how to fix the divi builder timeout error with a simple line of code. By adding a mod_substitute directive to your .htaccess, you encrease the processing memory for the Divi Builder. Before you start, keep in mind that you should backup your file, before you make any changes.

Go ahead and locate your .htaccess file, open it, and insert the following code at the top of the document.

# BEGIN FIX divi builder timeout error
<IfModule mod_substitute.c>
SubstituteMaxLineLength 10M
# END FIX divi builder timeout error

You can read more about mod_substitute directive in apache’s documentation.