Printing all elements in an array

In php it may sometimes be important to print all of the elements contained inside of an array. In most instances you need to print them out forwards, starting with the element stored in the first array key, but sometimes you may need to print out the contents backwards. This process can be tricky and hard to understand for a lot of people so I tried to simplify it by making a function that will print out all the elements for you. Here it is:

function printAllArray($name,$action){
if($action == “foreward” || $action == NULL || $action == “”){
$amountIn = count($name);
for($x = 0; $x <= $amountIn;$x++){
print($name[$x]);
}
}
if($action == “backward”){
$amountIn = count($name);
for($x = $amountIn; $x >= 0;$x–){
print($name[$x]);
}
}
}


Read More...

Getting the max-width property to work in IE

As you may know, the max-width property is very useful. With it you can set the maximum width of an object; whether it be an image or the body of your website. Most browsers can read this code and produce the correct results.

#footer{
max-width:500px;
}

What that code does is make an element with a maximum width of 500 pixels. The only problem with that code is Internet Explorer versions six and earlier cannot process this. Here is what you need to add to get the same results in those browsers:

#footer{
max-width:500px;
width:expression(this.width > 500 ? “500px” : this.width);
}

That expression makes it so that early versions of IE can understand this crucial property.


Read More...

Making Zombies

this tutorial will teach you how to make people into zombies along with many other valuable Photoshop skills that will help with other types of photomanipulation.

zombie tutorial image

Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Morbi diam quam, sodales at, dapibus eget, condimentum ac, turpis. Mauris sapien elit, faucibus et, blandit eget, fermentum at, neque. Mauris nisi mi, dignissim in, condimentum a, rhoncus a, odio. Sed feugiat urna fermentum lorem. Cras rhoncus consequat nisi. Donec sed nunc ac erat porta adipiscing. Nam commodo, risus sed tempor malesuada, dolor nisl pulvinar enim, nec faucibus nunc est id nisl. Ut malesuada, quam et lobortis pellentesque, dolor metus iaculis eros, id facilisis pede urna at metus. Suspendisse vel augue sed lectus ultricies tristique. Integer tortor. Proin vehicula eleifend risus. Phasellus egestas ipsum. Sed non mauris pretium mauris pellentesque semper. In elit mauris, fringilla eu, consectetuer vel, gravida in, lorem.Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Morbi diam quam, sodales at, dapibus eget, condimentum ac, turpis. Mauris sapien elit, faucibus et, blandit eget, fermentum at, neque. Mauris nisi mi, dignissim in, condimentum a, rhoncus a, odio. Sed feugiat urna fermentum lorem. Cras rhoncus consequat nisi. Donec sed nunc ac erat porta adipiscing. Nam commodo, risus sed tempor malesuada, dolor nisl pulvinar enim, nec faucibus nunc est id nisl. Ut malesuada, quam et lobortis pellentesque, dolor metus iaculis eros, id facilisis pede urna at metus. Suspendisse vel augue sed lectus ultricies tristique. Integer tortor. Proin vehicula eleifend risus. Phasellus egestas ipsum. Sed non mauris pretium mauris pellentesque semper. In elit mauris, fringilla eu, consectetuer vel, gravida in, lorem.


Read More...

Abstract Cinema 4d background

It is a combination of cinema 4d and photoshop; enjoy.

abstract


Read More...
Recently