Daniel Gafitescu Here was supposed to be a famous quote…not available at the moment!

28Mar/140

Became a Zend Certified Php Engineer

Introduction

At the begging of 2013 I have read the article Become a ZCE in 2013 so I have set myself the goal that by the end of the year I should do be a Zend Certified Engineer. For the next 11 month I have totally forgot about it and in December I saw a tweet that said that Zend has upgraded the certification from Php 5.3 to Php 5.5 & rebranded from Zend Certified Engineer to Zend Certified Php Enginner so I bought a voucher.

The voucher is available for a year long so it gives you plenty of time to prepare for it, but I chosen the second to last day of the year to take it which was in fact the last day that I could schedule that exam. Ever since I have finished the university in 2008 I haven't taken an exam and I missed the thrill of going to one and even if I wasn't 100% sure I'll pass I went anyway. After the first 15-20 questions I was pretty confident that I was going to take it and in the end I wasn't sure on 4 questions , 2 of them were theory questions and the other 2 were code samples.

Advantages of being ZCE

  1. Proof that you are senior developer
  2. your future employ will be easier pursued into hiring you, and you can demand a raise on the current one
  3. looks good on your resume
  4. You will get to put a nice icon on your website ZCE logo to prove that you are certified and link it to Zend Yellow Pages.
  5. fill in the gaps in your Php knowledge and learn new stuff so you can use later

Testing system

I quite liked the testing system which was quite simple and intuitive. You have to answer 70 questions in 90 minutes , so you have around a minute and 30 seconds per question which is quite enought. Most of the time the question that are theoretic can be answer just in few second and you should take the time left to focus on the code sample ones.

If you are not sure of an answer you have the option to mark it for review and go back to it whenever you like, and even if you forget about it when you finish the exam you are asked to check again the marked for review questions. I was given 2 sheets of plastic paper that can be easily erased and 2 markers if you need to write something down other than that you can have anything with you.

As far as I recall around 15-20 question are from the new material starting with Php 5.4. Even if there are 70 questions in one question you are required to know the theory from several topics so they will cover the whole spectrum.

If you fail the exam they give you a report on specific topics that you lack knowledge so that you can improve on them next time but they don't give you the specific questions that you failed.

In order to find a test center you can access Zend Technologies Certification Testing from Pearson Vue but most likely you'll find one if you live in a big city.

Type of questions

There are 3 types of questions:

  1. Single answer. You are given 4 options in which just one is correct. Most of the question are like this type
  2. Multiple answers. You are given at least 4 options in which at least 2 of them are correct.This type of question are marked as multiple and you can easily figure it out because you get checkboxes instead of radio buttons.
  3. Fill in the blanks. You are given a sentence that you have to word or a phrase. In one of the questions I was given it was require to give the name of a function (func_num_args). There are only 2 or 3 questions like this one.

Where to study from ?

  1. The main source is obviously is the official website: php.net
  2. Video training
  1. Books
  1. Blogs that you can find by googling ZCE

Miscellaneous

  1. Don't pay the full price for a voucher

There is always a coupon code that you can use and get at least 10% of the Zend PHP Certification Voucher and you can get it just by doing a simple search on google. I have used the coupon code CJ4ZEND which is around $15 off the total of 195 and the coupon still work today. Also if you fail the exam for the first time, the second time you want to buy the voucher you will have a discount.

  1. Zend Certification Study Guide

You get a pdf file to down in email once you buy the voucher but seems like the file is not there any more http://static.zend.com/topics/PHP-5-3-Study-Guide-v1.pdf . In this draft pdf file you got sample questions devided per chapter but from my point of view they were easier than the one from the actual exam

  1. Read the php docs on the ebook reader/table device

In my case I have download the the php documentation fromhttp://doc.php.net/downloads/epub/php_manual_en.epub as epub format and read it on my kindle where I can make notes with ease.

  1. Test Prep: Zend PHP Certification online course

There is a very expensive test preparation from Zend which cost $1000 including the examn voucher which from my point of view is quite expensive.

  1. Upgrade from PHP 5.3 Certified

In October 2013 at a Zend Conference in Paris the new certification has been announce and it included PHP 5.4 and 5.5 and keeping a lot of the question from the previous exam but you can easily apply for an upgrade if you are allready PHP 5.4 Certified. In my case I have waiting for the new Php 5.5 certification for quite a while and everytime I email Zend they replied that it was a working in progress and they didn't have a release date. The chapters has been upgraded as well and you can found them in Exam information section.

Preparation

They way I prepared was quite simple: I allocated 4 hours per each chapter and I have started with the part that was most familiar with and increase the time on the chapters that wasn't that good at like regular expressions, SPL and Traits in my case. In order to pass the exam you should be flawless on the Php Basics and you must treat all the question here as a trap. Don't always go for the obvious answer especially that you have code that you need to check. In my mind come the example with the strpos function.

if (strpos('abcdefg','abc')){
    echo "found it!";
}else{
    echo "didn't find it..";
} 

At first glance you would say that it will echo "found it" but if you pay closer attension the strpos will return 0 which will be cased to a false boolean so in fact it will show "didn't find it..".

For the SPL which I never used before I study from the php|architect's Mastering the SPL Library and was just frustrated that I didn't used this before but after looking and studying it now everything that I can do with SPL I am using it. Regular expressions were another chapter that I wasn't that familiar with and I payed more attention to it and to the php functions.

All the function regarding strings, array & file management you need to lean by heart if you don't know them by now and also the operator priority list is another part that you need to be familiar with.

For the XML chapter you got to deal with SimpleXml , DOM and for this the best aproach was to get a xml file and play with all the function and methods so you can get more familiar with it. I have got 5 question involving XML so practicing was very importing on this matter.

Where to go next

Working in our field where thing change with such a pace and new technologies and framework emerge so often it's hard to settle for a certain version or framework. You always have to learn & research so you be up to date, and this sort of certification prove that you do that and you are always trying to improve and move forward.

There are a lot of other test/certification that you can take. The most appealing for me right now it's the Sensio Labs's Symfony certification specially if you are working with Symfony 2. There is also the Zend Framework 2 certification that you can take also from Zend. There is also ThePHP Curriculum which look really promising and the fact that Sebastian Bergmann ( the PhpUnit creator) is behind the project.

Anyway if you are looking forward to take the exam good luck with it and if you allready have passed it please share your experience in the comments below.

27Oct/130

The Healthy Programmer: Get Fit, Feel Better, and Keep Coding – book review

healthyFor the past few month I've been having back problems and I saw someone mention on tweeter about a book dedicated for programmers on health & well being. It's The Healthy Programmer: Get Fit, Feel Better, and Keep Coding written by Joe Kutner .

Even if I was reluctant at first once I have start reading it and I have finish it within a week.

On my case to prevent back problems it offered exercises that were even recommended to JFK which couldn't  keep his child in his arm because of it.

Here is a list of quick things that I pick up from it:

- we need to do at least 10 000 steps per day ...and they are gadgets to help you keep track of that NIKE+ SPORTBAND

- staying indoor every day can weaken your immune system so is better to stay out in the sun for 10 minutes ...hunt for D vitamin.

- weight is a factor that you need to watch on a daily basis, heart pressure once a month.

- a day a week don't each meat ...it will try to do that twice a week starting next year.

 

These are just a few tip that I pick up from the book and there are plenty there backed up by a lot of research links.

I recommend the book to all people who  work every day at a desk and with a computer.

 

23Jun/130

PHP 5.5 First Look

A short title from Lynda.com about the new features of the Php 5.5 done by Jon Peck

The title will cover :

- installing the Php 5.5 on a VirtualBox machine

- generators using the yield operator

- dereferencing
Ex:
echo "abcd"[2] ==> b

- finally keyword on the try/catch statement for cleanup operations

- password hashing using the functions  password_hash , password_verify & password_get_info

- Opcache  included by default, previously knows as commercial Zend Optimizer +

- usage of list in foreach statement

- check if a function return empty result using empty function and not throw an error

- normalizing a bunch of different functions like boolval , pack & unpack

- what has been removed/deprecated on the latest Php version

Filed under: Programming No Comments
23Jun/130

Cassis

I short visit to Cassis, France.

Filed under: Travel No Comments
16Jun/130

Avignon

Yesterday I went to Avignon.
The city it's known for being the "City of Popes" and in 2000 was European City of Culture.

Here is a playlist of short videos I took with my camera "on the run" mainly from The Popes's Palace & Avignon Bridge which are part of Unesco World Heritage

Tagged as: No Comments
3Jun/130

Laravel: Code Bright


Just finish reading Laravel: Code Bright , or better say what has been written so far since it's on going process and I had found it as an excellent start if you want to learn Laravel4.
Dayle Rees has written before "Code Happy" which was an online book that you can order the print from https://leanpub.com but this one it's on Leanpub exclusive.
So if you are on the working with Laravel4 in my opinion it's a must read.

Filed under: Books No Comments
1Jun/130

Laravel4 snippets

1. Web server configuration

For Apache , Nginx & lighttpd

https://github.com/daylerees/laravel-website-configs

 

2. Optional route parameter

 

Route::get('/country/{country_name?}',function($country_name="Romania")
{ 
 return "Returning info from  {$country_name} ."; 
});

So when the url will be

 /country - I will display

Returning info from Romania

 /country/USA - I will display

Returning info from USA

3. Multiple filters

You can call multiple filter using the | pile line.


Route::get('/safe',array(
	'before' => 'auth|is_allowed', function()
  	 return View::make('gold'); }
));
5Mar/131

Sublime Text 2

For the last couple of months I have been using Sublime Text 2 as my text editor and there is no way back to Netbeans I'm afraid, and here's why :

  • it's written in Python so it's much faster than Netbeans or any other IDE written in Java
  •  it's leightweight (20 MB)
  •  it's cross-platform
  •  can be easily extended using plugins
  •  has multiple color schemes and themes that support antialiasing fonts

There is one downside that Xdebug doesn't work as good as it does on Netbeans.

There are online video tutorials that can get you started  Perfect Workflow in Sublime Text , Up and Running with Sublime Text 2 or videos from Stuart Herbert from his youtube channel.

 

 

 

 

Filed under: Uncategorized 1 Comment
22Sep/120

Goodbye ExtJs/Sensha , Hello KendoUi

I loved ExtJs (new Sensha)  for a long time , but now seeing what KendoUI can do I think I will stick with it.

Maybe Introduction To Kendo UI from http://pluralsight.com can convince you too.

Tagged as: , No Comments
17Sep/120

Git Cheat Sheet

I have been working with Git for few months and even if at the start was kind of difficult to grasp it after switching from SVN.

Here is a list of most used commands :

Configuring

Cloning the repository
> git clone git://url

>  git config --global user.name “Firstname Lastname”

> git config --global user.email “user@email.com”

> git config --global color.ui true

> git config --global alias.st "status" -  define an alias to git status : > git st

List the configuration

> git config --list - list all the configuration

Setup a project in the root directory

>  git init

Look inside the git file

> tree .git

Add all files to repository

> git add .

Commit files to the repository
> git commit -m “First import”

Commit all changes that have done to the project ( ask for a message)

> git commit -a

Add a single file to the commit (is qued up for commit)
> git add {filename} - add the file
> git rm {filename} - delete the file
> git mv {first_file} {second_file} - rename

See prev change ( DIFF between changes)
git diff {filename} - see the difference between changes

get information about the tracked files , changed or new files  
> git status

See log
> git log
> git log --until=2012-06-14
> git log --since=2012-05-12
> git log --author=”James”
> git log --grep=”Init”
> git log --online

HEAD - last state of the repository , what was last checked out

git show {sha} - show the commit information
git diff {sha} - show a diff from a previous commit
git diff {sha1}..{sha2}  show a diff between 2 commits
git diff {sha1}..{sha2}  {filename} - show a diff between 2 commits on a file

git diff --stat --summary
git log --graph --oneline --decorate --all

Branches

- master is the main branch ( ~ trunk in the svn)

Branch listing

> git branch

Create a new branch

>  git branch human => (create the “human” branch )

To switch to the human branch we need to log out from the master branch

> git checkout human ( swich to the human branch )

If I want to get the master changes in the human branch

> git rebase master

Merge human to master

First you want to see the changes

1) git checkout master

2) git diff master .. new_feature - compare 2 branches

3) git merge new_feature - merge the branch with the name new_feature ( I am in the master branch)

To check if the branch is merged you can do a diff between branches git diff master..new_feature

If we want to go back before the merge

4) git reset --hard ORIG_HEAD

If we have conflicts on merge make changes and then commit

> git branch --merged - show which branches are merged

> git branch -m {old_branch_name} {new_branch_name}- rename the branch
> git branch -d {branch_name} -
delete a branch

> git push origin :{branch_name} - delete a remote branch

> git push origin --delete {branch_name} - also deletes a remote branch

Repositories

When you work on the public server you need to push the commit to live server.

> git push

Donwload the last changes

> git pull

Git Architecture:

2-tree architecture - repository & working copy (svn use)
3-tree architecture - repository , stagging index & working copy (git use)

working copy -> git add file.txt ->  staging index -> git commit file.txt -> repository

Undone changes

- undo changes to the working directory

git checkout {filename}  or
git checkout -- {filename}

- unde changes to the staging directory

git reset HEAD {filename}

- change the commit message or add new change to a file that is already on staging directory
git commit --amend -m “Change the files  already staged”

- changes to the older commits
git checkout {hash} -- {filename}

- revert a commit
git revert {hash}

- rever multiple commits ( move the HEAD pointer)
git reset
-- soft (move the pointer but doesn’t change the staging index or working directory)
-- mixed (default) = move the head pointer to the specified commit and change the staging index but doesn’t change the working directory
-- hard - move the HEAD , change the staging index and working directory

git clean -f   - remove the untracked files

 

Stashing

- store changes temporary , only visible for you
git stash save “config changes” -
save the files to stash
git stash list
- show the stash lists with the name of the changes
git stash show stash@{0}
- show the file changes in specified stash (to see more add -p option)
git stash pop {stash_item}
- get and remove changes from stash , if a stash item is not specified get the last one
git stash apply {stash_item} -
get the changes from the stash

git stash drop stash@{0} - delete a stash item
git stash clear - remove all stash items

Ignoring files

/proect_dir/.gitignore - add all the files and directories that will be ignored by git.

Sample file:
# comment
test.txt - ignore file test.txt
*.tmp   - ignore all the files that have the extension .tmp
*.gz
log/*.log
assets/photoshop/
assets/video
!assets/video/tour_*.mp4

If you want to ignore specific files you need to alter .gitignore_global file located in the user directory

If you want to track an empty directory , create a empty file .gitkeep in that specific directory