Friday, June 20, 2014

PHP Basic Concepts: Flag-like

Someone asked me, how to code this flag-like image. So, here is the code. I hope the sample script helps.


Note: These materials are used for basic web programming class of AMACDO, section A3/B3. 

PHP Basic Concepts Part1: Binary and Multiplication Table

These sample programs were coded using PHP scripts. If-Else statement and Looping statements were applied to these samples.



The first sample program used binary concepts; that all odds have a value of 1 and 0 for evens. In order to get this easily, use  modulus.

The second sample program used multiplication table concepts. The codes applied table tag of html for alignment purposes. 


Note: These materials are used for basic web programming class of AMACDO, section A3/B3.