My Immediate feelings after the ZCE exam


I cant help to share the feelings right away with you now. Just came back after we finished the exam.

Its great event of joy for me and my friend Abdullah. Because we sat together on the same day. And I think this is first ever in Bangladesh that two ZCE passed at the same day. To tell you the truth, I had an attempt on 19th February this year but that was kind of rushed sitting and thats why duely failed yet was very close to passing score 😦

But the question is why I decided to go for ZCE anyway? well first and foremost is the inspiration from Hasin Hayder, who is entitled among the BD PHP community as the pioneer and guru and the Geek on PHP. Though I started learning php on 2003, I was not very strong at it until last year. But Hasin bro kept inspiring that, you can become one and you should give it a good try. On that time we (Ferdous [9th ZCE] and me) were beginner level developer at the Saifur’s corporate and started a training on PHP. Most amazingly Hasin bro inspired us making the syllabus one of the best in Bangladesh. We included so many things in it. And we taught the students the best practices in development, design and DB etc. We introduced them with the common CMSs, Forums and even Frameworks. We introduced them PHP and jQuery frameworks too!

One of our students was Sadiqur Rahman(the wonder boy and 8th ZCE!), who enrolled there saying he wants to become a ZCE! 😀

So, it was our challenge from then on. Building our bases to achieve good better best practices in the PHP development industry. We inspired all students to become bloggers, tweeterers and getting fed from the best resources on the web on what they want to excell.

Even this morning at 5am when Hasin bro asked how is the preparation? I said not upto my intentions. He said some inspiring words that I calmed myself little bit. While taking the exam I was semi nervous. Kind of knew I’m winning it, but didn’t make the mistake what I did last time(I submittend the exam in 57 minutes and reviewed only 3 questions and came out 33minutes ago). Today I almost reviewed all 70 of them and started counting. Was little nervous… but when the count reached more than 61! I stopped 😀 and submitted it! et voila I got congratulations from Zend.com

I kind of knew my friend Abdullah(he had an attempt last month and did score near to passing as well!) who started just 40 minutes after me was gonna pass as well, so it was a great feeling indeed.

Hope you guys didn’t mind this long writing. I just want to inspire new comers to PHP. We in Bangladesh should rise up and give it a good try. We need to outsource more of our intellect. We need to have our stand and we need to build a Very Best community. We need to do campaigns like WordCamp, ZendCon, PHPCon and inspire our fellow developers to become ninjas and beat the rest of the world.

I would like to share with you my old blog writing in Bangla you’d notice I wanted to see my name there very much(at least on 10th but oh well I made a milestone by sitting together two old friends together and won it) 😉  here’s the link: https://lenin9l.wordpress.com/2008/12/17/%e0%a6%9c%e0%a7%87%e0%a6%a1%e0%a6%b8%e0%a6%bf%e0%a6%87/

Originally posted at http://tech.groups.yahoo.com/group/phpexperts/message/12724

PHP4 & PHP5


From the PHP script writer’s point of view, the change most likely to impact legacy code is in the way that references are handled in all PHP versions post-dating the PHP 4.4.0 release.
Until and including PHP 4.3, it was possible to send, assign or return variables by reference that should really be returned by value, such as a constant, a temporary value (e.g. the result of an expression), or the result of a function that had itself been returned by value, as here:
[sourcode lang=’php’][/sourcecode]
Although this code would usually work as expected under PHP 4.3, in the general case the result is undefined. The Zend Engine could not act correctly on these values as references. This bug could and did lead to various hard-to-reproduce memory corruption problems, particularly where the code base was large.
In PHP 4.4.0, PHP 5.0.4 and all subsequent PHP releases, the Engine was fixed to ‘know’ when the reference operation is being used on a value that should not be referenced. The actual value is now used in such cases, and a warning is emitted. The warning takes the form of an E_NOTICE in PHP 4.4.0 and up, and E_STRICT in PHP 5.0.4 and up.
Code that could potentially produce memory corruption can no longer do so. However, some legacy code might work differently as a result.
Code that worked under PHP 4.3, but now fails

< ?php
function func(&$arraykey) {
    return $arraykey; // function returns by value!
}
$array = array('a', 'b', 'c');
foreach (array_keys($array) as $key) {
    $y = &func($array&#91;$key&#93;);
    $z&#91;&#93; =& $y;
}
var_dump($z);
?>

Running the above script under any version of PHP that pre-dates the reference fix would produce this output:

array(3) {
[0]=>
&string(1) “a”
[1]=>
&string(1) “b”
[2]=>
&string(1) “c”
}

Following the reference fix, the same code would result in:

array(3) {
[0]=>
&string(1) “c”
[1]=>
&string(1) “c”
[2]=>
&string(1) “c”
}

This is because, following the changes, func() assigns by value. The value of $y is re-assigned, and reference-binding is preserved from $z. Prior to the fix, the value was assigned by reference, leading $y to be re-bound on each assignment. The attempt to bind to a temporary value by reference was the cause of the memory corruption.
Such code can be made to work identically in both the pre-fix and the post-fix PHP versions. The signature of func() can be altered to return by reference, or the reference assignment can be removed from the result of func().
[sourcode lang=’php’][/sourcecode]
In PHP 4.3 $x would be ‘original value’, whereas after the changes it would be ‘function return’ – remember that where the function does not return by reference, the reference assignment is converted to a regular assignment. Again, this can be brought to a common base, either by forcing func() to return by reference or by eliminating the by-reference assignment.
Code that worked under PHP 4.3.x, but now throws an error

< ?php
class Foo {
    function getThis() {
        return $this;
    }
    function destroyThis() {
        $baz =& $this->getThis();
    }
}
$bar = new Foo();
$bar->destroyThis();
var_dump($bar);
?>

In PHP 5.0.3, $bar evaluated to NULL instead of returning an object. That happened because getThis() returns by value, but the value here is assigned by reference. Although it now works in the expected way, this is actually invalid code which will throw an E_NOTICE under PHP 4.4 or an E_STRICT under PHP 5.0.4 and up.
Code that failed under PHP 4.3.x, but now works

< ?php
function &f() {
    $x = "foo";
    var_dump($x);
    print "$x\n";
    return($a);
}
for ($i = 0; $i < 3; $i++) {
    $h = &f();
}
?>

In PHP 4.3 the third call to var_dump() produces NULL, due to the memory corruption caused by returning an uninitialized value by reference. This is valid code in PHP 5.0.4 and up, but threw errors in earlier releases of PHP.

< ?php
$arr = array('a1' => array('alfa' => 'ok'));
$arr =& $arr['a1'];
echo '-'.$arr['alfa']."-\n";
?> 

Until PHP 5.0.5, it wasn’t possible to assign an array element by reference in this way. It now is.
Code that should have worked under PHP 5.0.x
There are a couple of instances of bugs reported under PHP 5.0 prior to the reference fixes which now ‘work’. However, in both cases errors are thrown by PHP 5.1.x, because the code was invalid in the first place. Returning values by reference using self:: now works in the general case but throws an E_STRICT warning, and although your mileage may vary when assigning by reference to an overloaded object, you will still see an E_ERROR when you try it, even where the assignment itself appears to work.
Warnings that came and went
Nested calls to functions returning by reference are valid code under both PHP 4.3.x and PHP 5.1.x, but threw an unwarranted E_NOTICE or E_STRICT under the intervening PHP releases.

< ?php
function & foo() {
    $var = 'ok';
    return $var;
}
function & bar() {
    return foo();
}
$a =& bar();
echo "$a\n";
?> 

ZCE হবেন? PHP শিখুন


Cert. date

Jul 23rd, 2009
Jul 23rd, 2009
Jun 29th, 2009
May 5th, 2009
Mar 24th, 2009
Mar 11th, 2009
Feb 16th, 2009
Jan 28th, 2009
Dec 4th, 2008
Sep 15th, 2008
May 5th, 2008
Jan 29th, 2007
Aug 31st, 2006
Aug 15th, 2006
Jun 6th, 2006

Company

SelfEmployed
ibacs
BJIT
BrainStation-23
RBS

RBS
RBS

Informatix Software
Greenland IT
I2WE Inc
I2WE Inc
TigerIT BD Ltd
I2WE, Inc.
I2WE Inc

___________________________________________

উপরের তালিকাটি দেখে প্রশ্ন জাগছে কেন বা কি? তাইনা?

তালিকাটি হচ্ছে, বাংলাদেশের সব পিএইচপি প্রোগ্রামারের, যারা পিএইচপি’র কোম্পানী(Zend) থেকে পরীক্ষা দিয়ে উত্তীর্ণ হয়েছেন, বিভিন্ন সময়ে। তালিকার সবার শেষে রয়েছে এই ব্লগেরই(প্রথম আলো এবং সামহোয়্যারইন  ব্লগ এ এটি পোস্ট করার জন্য লিখিত) কারিগরী নির্মাতা হাসিন হায়দারের নাম। তার মানে তিনিই প্রথম বাংলাদেশের ছেলে যে এই সার্টিফিকেট এনেছেন। এই সার্টিফিকেটটি এখন অনেক ডিমান্ডিং। দেখতেই পাচ্ছেন, মাত্র ওরা ১৫জন(পোস্টটি প্রথম রচনা করা হয় নভেম্বর ২০০৮, তখন ৬জন জেডসিই ছিলেন বাংলাদেশে) আছে তালিকায়। সুতরাং এখানে নাম লেখাতে পারলে আপনিও হয়ে যাবেন কেউ-কেটা। 🙂

ZCE কী?

Zend Certified Engineer. পিএইপি ভাষাটি প্রথম ডাচ নাগরিক Rasmus Lerdorf অবতারণা করেন। পরে ইজরাঈলী দুই ছাত্র Zeeve Suraski আর Andi Gutmans একে এর বর্তমান রূপ দেন তাদের নামানুসারে পিএইচপি কোম্পানি’র নাম হয়েছে জেন্ড। Continue reading