Yes finally it’s been a Month!

It was 29th Mar, 2019 7:30 AM when I arrived in Munich International Airport for first time also it was first arrival ever in my life somewhere else from my home country Bangladesh. It was a flight with Singapore Airlines, previously I had no experience of any airlines services, I choose this only for 2 reason, first one is 30% around discounted ticket and another is to see the world most beautiful Changi Airport Singapore. That costs me 23 hours of journey where if I choose some others then the usual flight duration could be only 14 hours!

The first day here in Einsteinstraße München, was a bit learning and knowing each stuffs. Whatever I see and noticed almost everything is new! Faisal Ibrahim one of my ex-colleague from Aan-Nahl Software Limited he came here in this city 15 days before my arrival. and on the first day he came to visit me in my apartment. That was really helpful for me, Thanks Faisal bro again. Still now when I am writing this article I am waiting for you 🙂 to have a Khuchuri lunch together!

I leave my home village on 2001 right after my S.S.C exam. It’s around 18 years now, but it was in same country and just a division distance, and now this case it’s another Country and it’s around 7,287 km distance!! So it’s not possible for me to move anytime I want 🙁

While I was in my home country I had really a Luxurious, Easy and Family life. As a Senior Software Engineer with 12+ years of experience it was really easy for me to live in any standard. On top of everything the only issue I was facing the security of my and my family, however Alhamdulillah Allah gave me a chance to change it, that’s why I am here to find a secured and healthy life.

Yeah, I always find myself a bit introvert, even when I was in my home country. I don’t talk first, I don’t make friends first but I look for, whenever I find it’s good to go with I do it. Though it’s a bit time consuming and in some cases I find the other person already started thinking negative about me.

Here in Munich, for at least first 15 days I was feeling too much home sick, too much alone 🙁 It’s not only me, was feeling it’s everyone alone here. They only talk whenever it’s required, they walk whenever there is a reason, they start talking to the point, with no introduction of anything. I was feeling like no this is not for me, this culture is not for me, I didn’t find any reason why I am here 🙁

To find a solution I started talking a lot of my friends who already abroad for a longer time and family members. Everyone was saying like at-least stay for a couple of months so that you know if it is really what you are feeling now. Otherwise you might find guilty when you back here. Then later performed 2 time Istikharah salah and In a result I settled my mind to stay here 🙂 Now, it’s all easy for me. The things I was feeling not for my first few days now I find it’s for me 🙂

Now, I am enjoying staying here, now I can move around without any help. Also found a couple of Asian shops which all are full of Asian foods and stuff. It’s already been a month, expecting to visit my home within next 4/5 months.

Thanks for reading!

Setting up VirtualHost for Symfony Application on Ubuntu

If you are developing a Symfony application on your local machine by default you will get a localhost URL like:

http://localhost/symfony/symfony-test-app/public/

Which is a bit bad looking because the actual front facing application of Symfony is in app-root/public directory. You can make it look like http://symfony-test-app.com depending on your application name just by editing 2 files.

Let’s see how it works in Ubuntu:

The first file you will need to edit is virtual host configuration file or you can create one new. The root directory in this case would be: /etc/apache2/sites-available/

I am going to create a separate file for my app which is symfony-test-app.conf

sudo vim /etc/apache2/sites-available/symfony-test-app.conf

The content of symfony-test-app.conf file would be:

<VirtualHost *:80>
  ServerName symfony-test-app.com
  <IfModule mod_rewrite.c>
    RewriteEngine on
    RewriteCond %{REQUEST_METHOD} ^(TRACE|TRACK)
    RewriteRule .* - [F]
  </IfModule>
  DocumentRoot /var/www/html/symfony/symfony-test-app/public       
  <Directory /var/www/html/symfony/symfony-test-app/public>
    Options Indexes FollowSymLinks MultiViews
    AllowOverride All
    Require all granted
  </Directory>
</VirtualHost>

Just change the ServerName, DocumentRoot and Directory line according to your application path.

The second file you will need to edit is the hosts file. The root directory in this case would be: /etc/

sudo vim /etc/hosts

The content you need to add is just a single line like:

127.0.0.1       symfony-test-app.com

You can add it before or after the default localhost line like:

127.0.0.1       localhost

That’s it, You are ready to go by enabling your newly created virtual hosts configuration file and restarting your Apache like this:

sudo a2ensite symfony-test-app.conf
sudo service apache2 restart

If you did it all good then now you can visit your in development Symfony application by http://symfony-test-app.com/ instead of using that old ugly URL with /public at the end.

Thanks for reading.

আমি এখন টেপ এর পানি না ফুটিয়ে পান করি!

ঢাকায় প্রথম থাকা শুরু করি ২০০৮ এর জানুয়ারি থেকে, শুরু থেকে ই বাসায় পানি ফুটিয়ে ফিল্টার করে পান করতাম যদিও পরিশুধন এর কাজটা প্রথমে কাজের খালা করতো আর পরে বউ করতো, পানি ফুটানো এর ঝামেলা নিজে তেমন নেই নাই, আর কখনো বুঝতাম ও না, তাছাড়া একরকম জন্মগত ভাবে ই মনে হত টেপ এর পানি কি আবার খাওয়া যায়? দেশের টপ লেভেল শিক্ষা গ্রহণ করেও নিজের এই অধিকারটার কথা কখনো মাথায় আসেনি যদিও কত বড় বড় কম্পিউটার প্রব্লেম / প্রোগ্রাম সল্ভ করলাম / লিখলাম জীবনে । কিন্তু জীবনে একবার এর জন্য ও মনে হয় নাই টেপ এর পানি কোনরকম পরিশুধন না করে খাওয়া যায় । ঢাকার জীবন (স্পষ্ট করে “ওয়াসা”) আমাকে এমন শিক্ষা ই দিয়েছে যে নিজের গ্রামের বাড়ী কুমিল্লা এর বানাশুরা গিয়েও কখনো টেপ এর পানি এমনি পান করি নাই, টিওব-ওয়েল এর পানি পান করতাম অথবা ডাইরেক্ট মটর এর ।

এখানে জার্মানি আসার দিন প্রথম এ পানি পান করতেছিলাম না, ভাবতেছিলাম পরে ব্যবস্থা করবো, আপাতত বাইরে থেকে মিনারেল কিনে নিব কয়েকদিন এর জন্য, পরে যখন Faisal Ibrahim ভাই রুম এ আসলো বিকালে, তখন উনি বললেন টেপ এর পানি খাওয়ার যাবে, উনি নিজে খেয়ে ও দেখালেন, তাতেও নিশ্চিত হতে পারছিলাম না, যদিও ভয়ে ভয়ে খেয়েছি, ভাবতেছিলাম উনি হয়তো আমার মত এত কেয়ারিং / সতর্ক না অথবা অবিবাহিত তাই । পরের ২য় দিন যখন অফিস এ দেখালাম সবাই টেপ এর পানি পান করে তখন নিশ্চিত হলাম । আর আমিও নিশ্চিন্তে টেপ এর পানি পান করে যাচ্ছি এখানে ।

যদিও আমি ফেইসবুক এ তেমন একটিভ না, তাছাড়া সকল রকম নেগেটিভ খবর এড়িয়ে চলি পড়তে চাইনা, শেয়ার করি না, ইদানীং কিছু খবর দেখে মাথায় আসল, আমাদের দেশে পানি নিয়ে এই সমস্যা এর একটা সমাধান হয়তো সরকার অথবা জনগণ করতে যাচ্ছে, তাই লিখলাম, ভাবলাম তাদের বোঝার সুবিধার্থে অথবা আমার মত যারা ভাবে তাদের ভুল ভাঙ্গানুর জন্য। দোয়া করি এক এক করে দেশের সকল সমস্যা এর সমাধান আসুক ।

সবাই ভাল থাকুন, ভালবাসা অবিরাম! সুদূর জার্মানি থেকে।

Flying to Munich, Germany – My first time ever Abroad Travel Experience!

For personal blogging I am still new, though I was writing technical articles or mostly programming tutorials since a decade. This is first time I am far-far-away of my home and I feel like writing it all is the only way to keep a footprint so that later in future I can spend time reading this all or my kids. That’s why writing this article late around 30 days of my travel, though for content organization I will put the date around mid of Mar, 2019. I wish in near future I will find it easy to write day to day event or stories.

The journey started at 8:30 AM from Dhaka, Bangladesh, everyone of my family already started feeling my absence. It was most painful and loving for my beloved wife, because that time she started to know how it is the meaning of absence, even on top of everything if it is the first person. On the other hand my little angel “Abiyat Tuhra – Umamah” she was a bit not much more, it’s may be because she is only 4 years old. She was feeling something only because the surroundings! But I know, she knows I am leaving them behind for a bit longer time than the usual.

I had almost everyone of my Family that day on my apartment, It was great to feel how important I was in my family and I was not alone in my family life there. My parents, siblings, mother-in-law, brother-in-law and on top of everyone Uncle Yeakub-UL Islam, the most senior Guardian of our family who came only to see-off me from 300 KM away!! Thanks everyone, I miss you all!

@Hazrat Shahjalal International Airport on 28.03.2019, I wish you can guess who is this all here 🙂

After getting inside of the Airport I was feeling like, now it’s my turn to feel what I am leaving behind!!! Yes it’s everyone and it’s one by one. On top of everyone my cute angel, my daughter!!! About my parents, first time I had that same feeling on 2001 that’s 18 years ago! when I choose to move on other city (Beanibazar, Sylhet) for my Education and Career. For my loving wife, she has the skill and passion on my Ambitions so we both need to be confident of what we are doing.

When I was in check-in counter, I had to wait for around 30 mins for my papers verification. It was a bit panic for me and my father! Why they should keep us waiting while the embassy did their job? Who they are to confirm my validity? A flight agency will verify my papers? Am I looking false? However, it was all good and the officer also explained me why they did it all 🙂

Now it’s time to start for the long journey and the lonely life. When I was hugging you all, I was really crying by heart! According to the living standard difference between Bangladesh and Germany it was not possible for me to avoid this opportunity and it’s better to feel that. and it’s better to say you all bye at-least for 4/6 months. Then I wish to see you all again on home 🙂

A shot from Singapore Airlines lounges @ Hazrat Shahjalal International Airport

Yes, it’s already started! the things I was previously used to see by television / video camera, I started seeing them everything one by one by the built-in camera of my creator my OWN Eye. Everything feeling like new and first time ever! On the other hand, I was feeling the absence of my family members on a corner of my heart! Where the are now, what they are doing, how they are thinking about me now?

My departure was 12:40 PM from DAC (Hazrat Shahjalal Internaitonal Airport) – SIN (Changi Airport Singapore) for 5 hours transit and then – MUC (Franz Josef Strauses, Germany) where the arrival time was 06:30 AM of next morning.

The plane started it’s journey in time at 12:40 PM but there was a bit flight traffic on that day, that took almost 30-45 mins to fly us up!

My Bangladeshi brother Ibrahim Bin Shake, A friendly always smiley facing person. I was glad to have him with me 🙂

I was lucky to meet my Bangladeshi brother Ibrahim Bin Shake home district Brahmanbaria, He is living in South Korea for around a decade and bachelor! Making money for his future!!! You can say we both found us special and tour guide in some cases. He has a lot of travel experiences but very little ability to speak English, so he started teaching me the pros and cons of a flight and lonely life 🙂 Also on transit time we both had same amount of time like 4/5 hours. Had dinner together and he was the only person paying all the costs. However, I honored him by one thousand Bangladeshi new notes.

This is what you will see when you left cloud behind you!

After having two different flight, one for 6 hours and another for 10 hours long, I arrived on Munich Franz Josef Strauses Airport at 7:30 AM on 29.03.2019, it took only 10-15 mins for me to complete my entry and finding my luggage’s. Both of the Airport Changi and Munich was fully armed with modern technology stuffs.

When, I was getting out of the airport, I starting feeling the Modern Age the technology world, I was looking for something will amaze me! Yet, it’s there! Just in front of the Airport I found her!

You guess who she is!!!

I knew this city Munich as the birthplace of BMW, and when I saw her, I admitted yes it is true! and I loved her way of welcoming everyone on arrival of Munich.

Yes, it’s all for now, thanks for reading.

Install WordPress via WP-CLI

If you are a bash lover I wish you will find WP-CLI is the best approach to install WordPress for your project. WP-CLI provides a command-line interface for many actions you might perform in the WordPress admin where doing those same thing via WP-Admin will cost you some extra time.

To install WP-CLI on your machine depending on your Operating System there are some requirements, please check for that here https://wp-cli.org/

Here I am going to show how to move forward with Linux with PHP version 7.0.

Installing WP-CLI

Open you terminal with CTRL + ALT + T and execute below commands one by one. If things go right I hope you are ready to test the power of WP-CLI.

curl -O https://raw.githubusercontent.com/wp-cli/builds/gh-pages/phar/wp-cli.phar
php wp-cli.phar --info
chmod +x wp-cli.phar
sudo mv wp-cli.phar /usr/local/bin/wp
wp --info

How to Install a fresh WordPress instance

To install a fresh WordPress instance move into your work directory and create a directory with your project name. For example phpfarmer.com in my case. Then change directory into it and run below commands one by one.

In the meantime I will create a database with below info:
Database name: phpfarmer
Database Username: juyal
Database User Password: 123456$$!

Also I am expecting my newly installed WordPress admin credentials will be:
Username: phpfarmer
Password: 123farmer$$
Email: juyal@phpfarmer.com

# Download and Configure WordPress   
wp core download   
wp core config --dbhost=localhost --dbname=phpfarmer --dbuser=juyal --dbpass=123456$$!   

# Configure wp-config.php   
chmod 644 wp-config.php   
wp core install --url=yourwebsite.com --title="Your Blog Title" --admin_name=phpfarmer --admin_password=123farmer$$ --admin_email=juyal@phpfarmer.com   

# Enable File Uploading   
cd wp-content   
mkdir uploads   
chgrp web uploads/   
chmod 775 uploads/   

If everything went right then that’s all! Isn’t it easy and fast enough? Let’s see it in action just visit – http://localhost/phpfarmer.com

Try some action with WP-CLI

May be all of them you can do via WP-Admin but clicking, page loading, navigation will wast your time for them. So here you are going to skip them to speed up your development.

wp plugin list
wp plugin update akismet
wp theme list
wp theme update twentyfifteen

Thanks for reading!

This is how I make my Development Environment Ready!

Each Time I start with a fresh Linux Ubuntu distro I faced a lot of software installation and configuration is repeating because you know we software engineers are preferred to use only those applications which is we are used to.

That’s why to get my machine fully armed from a fresh start for web application development I wrote a gist to expedite the process.. If you are a Linux Ubuntu lover I wish you will find it useful – https://gist.github.com/tojibon/6a67e8fce63e65971be2374fef2e8cfd

```
sudo apt-get install -y build-essential
sudo apt-get install curl -y
sudo apt-get install libpng-dev libjpeg-dev -y
sudo apt-get install pngquant -y
sudo apt-get install git -y
sudo apt-get install openssh-server -y
sudo apt-get install unrar -y
# Fix local issue: https://askubuntu.com/questions/162391/how-do-i-fix-my-locale-issue

# installing VIM
sudo apt-get update
sudo apt-get install vim -y

# installing zsh
sudo apt-get update
sudo apt-get install git-core zsh
zsh --version
chsh -s $(which zsh) ============OR=========== chsh -s /bin/zsh
wget --no-check-certificate http://install.ohmyz.sh -O - | sh
vim .zshrc
alias ll='ls -l --color=auto'
alias la='ls -la --color=auto'
ZSH_THEME=amuse
reboot

# installing SDKMAN - http://sdkman.io/install.html
curl -s "https://get.sdkman.io" | bash
source "$HOME/.sdkman/bin/sdkman-init.sh"
sdk version
sdk install java
sdk current java
sdk install maven
sdk current maven

# installing Docker   
sudo ls   
curl https://gist.githubusercontent.com/tojibon/fadd13d9b1cc5a42f38112911c43b4d6/raw/0f369720ac0109885ffbdc2fc4840b0e50389909/install_docker.sh | bash   
docker -v
docker-compose -v   
   
# installing LAMP7 - https://www.storagecraft.com/blog/install-lamp-server-linux-mint-18-command/
sudo apt-get update && sudo apt-get dist-upgrade -y
sudo reboot
sudo apt-get install lamp-server^ -y
xdg-open http://localhost
sudo nano /var/www/html/info.php
sudo service apache2 restart
sudo apt-get install phpmyadmin -y
sudo service apache2 restart
xdg-open http://localhost/phpmyadmin
sudo apt-get install php-intl

#installing Composer
curl -sS https://getcomposer.org/installer | php
sudo mv composer.phar /usr/local/bin/composer
sudo chmod +x /usr/local/bin/composer
composer -V
sudo composer self-update

# installing Spring-STS - https://gist.github.com/tojibon/9e521a276cf93ac79650c8a3f68e03fe

# installing Intellij IDEA - https://www.jetbrains.com/idea/download/download-thanks.html?platform=linux
# https://www.jetbrains.com/help/idea/2017.1/installing-and-launching.html
cd Downloads/
sudo tar xf ideaIU-2017.1.3.tar.gz -C /opt/
cd /opt/idea-IU-171.4424.56/bin
./idea.sh
# https://confluence.jetbrains.com/display/IDEADEV/Inotify+Watches+Limit

#installing nodejs - https://nodejs.org/en/download/package-manager/
curl -sL https://deb.nodesource.com/setup_7.x | sudo -E bash -
sudo apt-get install -y nodejs

# installing yarn - https://yarnpkg.com/en/docs/install
curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add -
echo "deb https://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list
sudo apt-get update && sudo apt-get install yarn

# installing JHipster- https://jhipster.github.io/
sudo npm install --global gulp-cli 
sudo npm install -g bower
sudo npm install -g yo
sudo yarn global add generator-jhipster
 
# Generating SSH Key
ssh-keygen
cat .ssh/id_rsa.pub

sudo apt-get install php-curl
sudo apt-get install poedit

# Installing Zeal
sudo add-apt-repository ppa:zeal-developers/ppa
sudo apt-get update
sudo apt-get install zeal

# Installing WP Cli http://wp-cli.org/#installing   
curl -O https://raw.githubusercontent.com/wp-cli/builds/gh-pages/phar/wp-cli.phar
chmod +x wp-cli.phar
sudo mv wp-cli.phar /usr/local/bin/wp
wp --info

# Installing PlayOnLinux https://askubuntu.com/questions/770687/how-to-install-playonlinux-on-ubuntu-16-04   
sudo add-apt-repository ppa:noobslab/apps   
sudo apt-get update   
sudo apt-get install playonlinux

sudo apt install gnome-clocks -y
```

After installing all of these here are some software to be installed from Ubuntu software:

```
1. Kazam 
2. Kdenlive
3. Skype 
4. Shutter
```

Become AWS Certified Developer – Associate Level

As a software engineer I’ve been working on Web Application development career for around 10+ years, so it’s been above a decade!!

On this long career I’ve been working with AWS platform for a lot of applications and also currently managing a couple of AWS root / non-root admin account as a developer.

I was never concerned about any certification related to my career but recently I’ve found it’s really imported to get certified from some internationally popular vendors like AWS, Google, Zend etc. and In the meantime I’ve found one of my peer Shudarshon Chaki who is very keen on getting certified like Linux, AWS etc. I was inspired from him and started studying for AWS Associate Level Developer certification from may be Mar / Apr, 2018 and finally got the badge on Nov, 2018.

It’s first time I’ve received a proof of my work knowledge on any platform, the feeling is really awesome, this actually boosted up my confidence level. Now a days I am planning to start for other certifications like Solution Architect, Docker, Scrum etc certification and Expecting to own at least on within 2019.

How you can get prepared for AWS certification?

If you want to get it I will advice you to have your own AWS account mostly the trial one for one year, read Whitepapers and FAQ of AWS services. And also follow depend on some video courses provided by LinuxAcademy or A Cloud Guru. While study for certification don’t move forward fast instead try to learn the concepts, advantages, disadvantages and limitations of a feature.

Make some notes of your learning, after a few days of your study take a break for at least one week and then start again, by this way you will find yourself efficient and continuous learning without any break will make you get boring and demotivated 🙁

Also another thing, focus on the syllabus – the subjects / topics of your certification. AWS is a really huge platform, otherwise you will lost yourself! After atleast 3/4 months of study I will advice you to purchase the invoice for exam and finish it within a week!

That’s it for now, If you have any specific query you can put a comment here, I will try to reply you best. Thanks for reading.

Become a Amazing Contributors of TitanFramework!

I’ve been working with WordPress a most popular free and open-source content management system based on PHP & MySQL since 2008. As a senior software engineer I find one this CMS is the best to build simple dynamic websites for my freelance and official small to medium scale projects.

From the beginning I started creating WordPress theme from scratch or building child theme and plugin for it. But then I moved to https://themeforest.net/user/codereactor like marketplaces to sell my developed premium WordPress theme and plugins I’ve found this TitanFramework is the most suitable starter framework for WordPress.

After a couple of theme and plugins development I become a fan of this Framework only for it’s simplicity of developer friendly API. Though that time it was still growing and I planned to contribute a couple of features. The first contribution was about image gallery input API and add more and drop and drop sorting. Also added some other commits. Finally somehow the core team approved my pull requested!

And this is second time my contribution was approved on open source community via Github. The feeling of code contribution pull request accepted is really amazing and on top of that published your photo on any well known website related to your career is something top of everything!!!

If you are WordPress developer I will expect you to try TitanFramework I hope you will fall in love with this!

Thanks for reading.

Auto Fill Input Fields for Unique Page Sidebars

When you are developing a website with WordPress and support for Unique Page Sidebars WordPress Plugins then you may noticed when add a sidebar all the widget parameters inputs are empty. Something like the below image

default-inputs

Here with this code example you can auto fill the widget parameters.

Step 1: include a javascript for WordPress admin interface.

wp_enqueue_script( 'jquery' );
wp_enqueue_script( 'admin-custom-js', get_template_directory_uri() . '/resources/js/custom-admin.js', array( 'jquery' ), '1.2', true );

Step 2: Write below codes on your custom-admin.js

/*
---------------------------------------------------------------------------------------
Auto fill input values for WordPress Unique Page Sidebars when creating a synamic sidebar with default values
---------------------------------------------------------------------------------------
*/

jQuery(document).ready( function($) {

    //Finding all inputs from unique page sidebars when creating a sidebar
    $("input[id^=ups_sidebars]").each( function( k, v ) {

        //Finding current input fields id
        id = $( this ).attr( 'id' );

        //Check if it has a default value already
        if ( $( this ).val() == '' ) {

            //Matching if it is the before_title field
            before_title = id.match(/\bbefore_title/);
            if ( before_title ) {
            $( this ).val( '<h3 class="widget-title">' );
            }

            //Matching if it is the after_title field
            after_title = id.match(/\bafter_title/);
            if ( after_title ) {
            $( this ).val( '</h3>' );
            }

            //Matching if it is the before_widget field
            before_widget = id.match(/\bbefore_widget/);
            if ( before_widget ) {
            $( this ).val( '<div id="%1$s" class="widget %2$s">' );
            }

            //Matching if it is the after_widget field
            after_widget = id.match(/\bafter_widget/);
            if ( after_widget ) {
            $( this ).val( '</div>' );
            }

        }

    });

});

That’s all if everything goes fine you will see a interface as the below image shown when adding a sidebar.
input-pre-values

Note: Don’t forget to widget parameters as your need on javascript what you are using when registering a sidebar for your theme.