I have some lines in a php script that controls the location of images (in this case smileys). Right now there are 2 options the post form and the pop up window.
Okay, so what I want to do is add more pop up windows to store more and different smileys in them.
Currently, one such line looks like this:
Obviously this defines the location var. and as you can see there are only 2 options 'postform' and 'popup' this is evident by the *:* yes?
$location = empty($row['hidden']) ? 'postform' : 'popup';
So I need a way to rewrite this (and the other lines) so I can include 'popup_a', 'popup_b' etc. I have a total of 8 pop ups, (including the original) that need to be included.
Perhaps a nested if/else statement? I am just not sure how to write this out.
I then will need to add something to the MySQL database to accept the different locations wont I? right now it has 3 options 0, 1 and 2 where 0 is the 'postform' and the 2 is the 'popup' and the 1 means hidden.
What would I need to edit there to include 3 - 9 where 3 = 'popup_a' and so on. to 9 = 'popup_g'