Green

Thursday, August 22, 2013

please help; if and else statement

Hi

This is what i currently have...if user login "you are login"
            how i write a statement if user not login see something else? for example "you are not log-in"

Thanks advance

Opening and closing php at every single line for no good reason makes no sense, at all.

Steve202's answer is pretty much correct, however, using single quotes when echoing a string is far more natural. This is probabaly how you would want this to look like :

(assuming we're within )

When you work with php files, just write at the end. There's no valid reason to exit php within a php file.

You should also work on your grammar. "login" is a noun whereas "log in" is a verb.


View the original article here

0 comments:

Post a Comment