Ubuntu move content to parent directory — October 3, 2017

Ubuntu move content to parent directory

It’s super simple. For example you want to move content.txt from folder2 to folder1 content.txt

cd folder1/folder2/
mv * ../
CSS add overlay with content and spinner — September 29, 2017

CSS add overlay with content and spinner

            background-color: rgba(255, 255, 255, 0.8);
            position: fixed;
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            z-index: 9999;
            background-position: center center;
            background-repeat: no-repeat;
            top: 0px;
            left: 0px;
            width: 100%;
            height: 100%;
            background-size: 91px;

Just add anything in div with class ‘overlay’, like text , image and it will appear in center of page.

ACF get Taxonomy Term meta — September 27, 2017
Ubuntu Secure Boot error “Image failed to verify with *ACCESS DENIED* on startup — September 19, 2017

Ubuntu Secure Boot error “Image failed to verify with *ACCESS DENIED* on startup

After updating GRUB in Ubuntu I got this error and I was so afraid of this. But a YOUTUBE video helped me to recover from this. May this post can help you too.

I was using SAMSUNG laptop. Here is what we need to do.


You will see an option ‘SECURE BOOT’ and you need to disable it. Also when you disable it you will see an other option appears named as ‘OS MODE SELECTION’. If you disable ‘SECURE BOOT’ and your OS still cant boot then you need to change the options given in ‘OS MODE SELECTION’.

Codeigniter HMVC cross module call controller->method — September 13, 2017

Codeigniter HMVC cross module call controller->method

to call module01/controller01/method00:

//method 1 CORRECT:
$ctlObj = modules::load('module01/controller01/');
//or you could use chaining:

//method 1 WRONG:
modules::load('module01/controller01/method00');  //this will only load contructor

//method 2 CORRECT:
modules::run('module01/controller01/method00');   //no trailing slash!

//method 2 WRONG:

//method 3 CORRECT:

if you want more information you can follow this thread.

acf_form() after form submit handler — September 4, 2017

acf_form() after form submit handler

Here is one filter which can help you

add_filter('acf/pre_save_post' , 'my_pre_save_post' );
function my_pre_save_post( $post_id ) {
    //do whatever u want to do here
    //dont forget to return $post_id
    return $post_id;

For better information check this link.

Also need to make it more selective otherwise this will work for all acf_forms

add_filter('acf/pre_save_post' , 'my_pre_save_post' );
function my_pre_save_post( $post_id ) {
	$current_user = wp_get_current_user();
	$user_id = $current_user->ID;
	if($GLOBALS['acf_form']['post_id'] == 'user_'.$user_id)
		$GLOBALS['acf_form']['return'] = site_url().'/owners-add-new-property/?step=started';
		update_user_meta($user_id, "current_profile_step", 4);
	return $post_id;

You can see some unique info in ‘$GLOBALS[‘acf_form’]’ which will be unique for this post request. If still u have question add comment , will try to reply :).

WordPress check if user meta exists with same value for any other user except current user —