comparing mutual exclusive input text value

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
crimsonluv
Forum Newbie
Posts: 9
Joined: Tue Mar 23, 2004 9:10 pm
Contact:

comparing mutual exclusive input text value

Post by crimsonluv »

hai. i am new in php programming. i hope anyone can help me or give me a few resources.

here is the problem i faced :

i have 2 variable $a and $b . these are from 2 different text box. i wan to compare these 2 values. one value will be null and the other must not be and vice versa. the non null value will be passed to another variable, $c. and i wan to check again if the $c value is not in database to avoid duplicate record.

thanks !

:?
Zorth
Forum Commoner
Posts: 76
Joined: Fri Feb 20, 2004 8:00 pm

Post by Zorth »

You can't just do == ? I was actually wondering something like this myself and what if you want it to be case sensitive or not...
crimsonluv
Forum Newbie
Posts: 9
Joined: Tue Mar 23, 2004 9:10 pm
Contact:

Post by crimsonluv »

it's case sensitive. i tried to use javascript like :
<script type = "text/javascript">
function check() {
if (<?php echo $a> !=="" )
var $c == <?php echo $a>
}
</script>

but it's not working. i tried lots of methods but nothing works :(
Post Reply