karimali831
Members-
Posts
436 -
Joined
-
Last visited
Everything posted by karimali831
-
@ TeddyKiller: thanks got it and if you look closely, it's not. @ oni-kun: if clanID is 2147483647 this means team on a tournament has been taken off so therefore I don't want it selected when I'm using this query to get all matches by clanID. It works.. so why does it matter?
-
Hi, With this query: SELECT * FROM ".PREFIX."cup_matches WHERE clan1='$getteam' || clan2='$getteam' && (clan1 != '0' && clan2 != '0') && (clan1 != '2147483647' && clan2 != '2147483647') or SELECT * FROM ".PREFIX."cup_matches WHERE clan1='$getteam' || clan2='$getteam' && (clan1 != '0' && clan2 != '0') && (clan1 != '2147483647' || clan2 != '2147483647') is still picks up records where clan2 = 2147483647 and I don't want it to. So do not select if clan1 = 2147483647 OR clan2 = 2147483647. Thanks for help also.
-
I fixed it now. The validation was below the select query and suppose to be above it if I'm making sense.
-
I think there is a bug. Everytime I use if (strlen($_POST['score1']) > 0 && is_numeric($_POST['score1'])) {$score1=TRUE;} else {$score1=FALSE; $message_score1=" *Error! Please input a numeric value for score 1!";} if (strlen($_POST['score2']) > 0 && is_numeric($_POST['score2'])) {$score2=TRUE;} else {$score2=FALSE; $message_score2=" *Error! Please input a numeric value for score two!";} if (($_POST['score1'] == $_POST['score2']) && (strlen($_POST['score1']) > 0) && (strlen($_POST['score2']) > 0)) {$scorecheck=FALSE; $message_scorecheck=" *Error! Please ensure that score one and two are not the same!";} else {$scorecheck=TRUE; } if ($message_score1) die("$message_score1"); if ($message_score2) die("$message_score2"); if ($message_scorecheck) die("$message_scorecheck"); and I enter for example, 1 for score1 and 0 for score2, in database it shows score1 is 0 and score2 is 0? when i don't use the above it's fine.
-
I've got it, thanks very much once again.
-
Thanks very much Got the validations to work but not the form submit. The template is on a HTML file so I can't use php?
-
Hi, Here is the HTML: <form action="?site=cupactions&action=score&clan1=$clanID&matchID=$matchID&cupID=$cupID" method="post" name="post"> <table width="100%" cellspacing="0" border="0" cellpadding="2" bgcolor="$border"> <tr> <td bgcolor="$pagebg"></td> </tr> <tr> <td bgcolor="$bg1"> <table width="100%" border="0" align="center" cellpadding="2" cellspacing="0"> <tr> <td>%your% Score:</td> <td><input name="score1" type="text" class="form_off" id="score1" onFocus="this.className=\'form_on\'" onBlur="this.className=\'form_off\'" size="3"></td> <td>%opponent% Score: <input name="score2" type="text" class="form_off" id="score2" onFocus="this.className=\'form_on\'" onBlur="this.className=\'form_off\'" size="3"></td> </tr> <tr> <td colspan="3" align="right" ><input name="submit" type="submit" value="%submit%"></td> </tr> </table> </td> </tr> </table> </form> For validations I want numeric values only and if score1 is equal/same as score 2, there will be an error. Thanks for your help
-
Hi I want to prevent a user from submitting a form if a value in a text field is the same in another text field. anyways of doing this? thanks for help.
-
This does work if(memin($userID,$teamid)) $variable = ''; elseif(memin($userID,$oppid)) $variable = ''; else $variable = '';
-
what about if I wanted to use this: if(memin($userID,($teamid ||$oppid))) $variable = ''; else $variable = ''; I know that's wrong.. I want $userID and ($teamid or $oppid) I thought if(memin($userID,$teamid,$oppid)) may of worked but didn't. If I just used $teamid or $oppid it won't get all so I need to use both.
-
Lol ok thanks very much. Works
-
Take a look at attatchment. I want to select all only from cupID 19 and (clan1 = 340 or clan2 = 340) not cupID = 19 OR clan2 = 340 only clan1 = 340 or clan2 = 340 anyway? thanks for help. [attachment deleted by admin]
-
no one knows?
-
xD I know that. Ok, I'll show you what I mean. $variable = $asleader <?php $asleader = ' <tr bgcolor="'.$bgcolor.'"><td> <table width="100%" cellpadding="1" cellspacing="2"> <td width="30%"><img src="images/icons/go.png"> <b>'.$teamname2.'</b></td> <td width="70%"><img src="images/icons/manage.gif" width="10" height="10"> <a href="?site=clans&action=show&clanID='.$clanID2.'">View/Manage Team</a></td></tr> </table></td></tr>'; ... eval("\$profile = \"".gettemplate("profile")."\";"); echo $profile; ?> the profile.html template: <tr bgcolor="$bg1"> <td bgcolor="$pagebg">$asmember</td> </tr> Output: 1 result -- row from table. If I used this: echo ' <tr bgcolor="'.$bgcolor.'"><td> <table width="100%" cellpadding="1" cellspacing="2"> <td width="30%"><img src="images/icons/go.png"> <b>'.$teamname2.'</b></td> <td width="70%"><img src="images/icons/manage.gif" width="10" height="10"> <a href="?site=clans&action=show&clanID='.$clanID2.'">View/Manage Team</a></td></tr> </table></td></tr>'; It will display all rows but at top of the page so that's why I am using this variable $asleader and putting it in my html table to position it, but it only shows one row/result?
-
Hi folks, I'm having a problem with this, hope someone can help. When I use echo ''; I receive all outputs correctly but when I use $variable = '';, I only receive one row? $asmember = ' <tr bgcolor="'.$bgcolor.'"><td> <table width="100%" cellpadding="1" cellspacing="2"> <td width="30%"><img src="images/icons/go.png"> <b>'.$teamname2.'</b></td> <td width="70%"><img src="images/icons/manage.gif" width="10" height="10"> <a href="?site=clans&action=show&clanID='.$clanID2.'">View/Manage Team</a></td></tr> </table></td></tr>'; and my HTML file <tr bgcolor="$bg1"> <td bgcolor="$pagebg">$asmember</td> </tr> By using echo, it will show the results but will position it from the php file so I need to use variable.
-
I FIXED IT!!!! I LOVE YOU!! THANK YOOOOS OOOOOOOOOOOOOOOOOOOOO MUCH!! been trying to do it all day, much appreciated :D
-
Thanks!! but <?php echo $dl['ID']; ?> in input breaks the page?
-
does money sound good to anyone?
-
No one? is there something else I can use then? java links for dropdowns.. ? so I can type in my own custom URL without these annoying "?" getting on the way. :( more complicated now than simple. Closest: index.php?site=325&action=clanregister&cupID=24&clanID=325 <CORRECT ID> <option value="'.$dm['clanID'].'">'.getclanname($dm['clanID']).'</option> Or... index.php?site=clans&action=clanregister&cupID=24&clanID=<INCORRECT ID> because option value is not $dm['clanID'] <option value="clans">'.getclanname($dm['clanID']).'</option> understand better?
-
Something new.. $teamID = $dm['clanID']; <form action="index.php"><select name="site">'.$clan.'</select> <input type="hidden" name="action" value="clanregister"><input type="hidden" name="cupID" value="'.$dl['ID'].'"> <input type="hidden" name="clanID" value="'.$teamID.'"><input type="submit" value="Go"></form> $clan .= '<option name="clanID" value="clans">'.getclanname($dm['clanID']).'</option>'; Everything is ok except clanID is incorrect because option value is not $dm['clanID']
-
Now I get index.php?site=325&cupID=23 needs to be index.php?site=clans&action=clanregister&cupID=23&clanID=325 There are multiple clanIDs and generates a list of clanIDs.
-
Can you show how I can do this? when you select : <option value="'.$uri.'"> It will open $uri = 'clans%26action%3Dclanregister%26cupID%3D'.$dl['ID'].'%26clanID%3D'.$dm['clanID'].''; $uri = urldecode($uri); and show as clans%26action%3Dclanregister%26cupID%3D21%26clanID%3D325 so it don't work on dropdown
-
$uri = 'clans%26action%3Dclanregister%26cupID%3D'.$dl['ID'].'%26clanID%3D'.$dm['clanID'].''; $uri = urldecode($uri); $clan .= '<option value="'.$uri.'">'.getclanname($dm['clanID']).'</option>'; Thanks for your help... but still no luck with the above code It does decode but not from option value?
-
You can not decode URL on a option value for a dropdown?