Could someone help me with this simple IF/ELSE argument

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
tyler.pomroy
Forum Newbie
Posts: 8
Joined: Mon Sep 29, 2008 1:49 pm

Could someone help me with this simple IF/ELSE argument

Post by tyler.pomroy »

help me out

I've got the following code that I'm trying to make into an IF/ELSE argument...can anybody help me out with it?

I've tried several things and can't seem to make it work.

Code: Select all

<li class="<?php if (1 == comment->user_id) ddcomment = "authcomment"; echo ddcomment; ?>" id="comment-<?php comment_ID() ?>">
<li class="<?php if (1 !=comment->user_id) ddcomment = "othrcomment"; echo ddcomment; ?>" id="comment-<?php comment_ID() ?>">
Post Reply