php type casting

Access an object as an array in PHP

Have you ever been in that position when you are working with an PHP object and you need only one single peace of the data it contains and you want to skip all that iteration part and access that data directly. I have.

Easy PHP II: Variables 6

Easy PHP II: Variables

In the previous introductory PHP tutorial we talked about what PHP looks like and in what kind of environment it runs. To sum up, we said that we write PHP code between tags that look like this: “<?php … ?>” and we end every command line must and in semicolon (;). We use “echo” or “print” in order for PHP to show things to us.