-
Posts
5,717 -
Joined
-
Last visited
-
Days Won
6
Everything posted by Adam
-
Probably the editor.. funny line breaks or something? Anyway, it's nice enough but as ILMV said it is a little bland. The green on green in the navigation I'm not keen on either - perhaps go with a v.dark gray or black there? Adam
-
Oops: Basically the sub query returns records that have the userclass_id of 25 or 6 **
-
"You have an error in your syntax near line 2" .. and shows virtually all the query! V. helpful! Adam
-
Without looking too much into the code, this looks like it's your problem: var matchup1 = formObj['1vs8East']; .. Try: var matchup1 = document.forms['1vs8East']; Adam
-
Hi guys. MySQL is certainly not my strongest point! I have a problem in the syntax of this query: delete from auth_user_temp aut where aut.user_id in ( select user_id from user_group where (userclass_id = 25 or userclass_id = 6) group by user_id having count(userclass_id) = 2 ); Basically the sub query returns records that have the userclass_id of 25 or 2, nothing else, and no less. The select sub query works fine by itself. I think the problem is using "aut.user_id in ..." Does any body have an alternative or, perhaps be able to tell me why it's not working? Thanks! Adam
-
Yeah there's absolutely no reason why not. I think the trickiest bit would be creating a smooth interchange whilst loading the images.. Adam
-
Not if called via ajax! Adam
-
change font color when there is text in input field
Adam replied to exhaler's topic in Javascript Help
Place this JavaScript within the <head> of your HTML.. <script type="text/javascript"> function updateText(obj) { if (obj.value != '') { document.getElementById('updateText').style.color = '#00FF00'; } else { document.getElementById('updateText').style.color = '__normal color here__'; } return; } </script> And part of your code with the changes made.. <td valign="middle" align="left" style="width: 210px"> <input type="text" name="firstbranch" size="35" style="font-size: 8pt; font-family: Arial; color: #56443D; background-color:#DCD6C7" onkeyup="updateText(this);"> </td> <td valign="middle" align="left"> <span id="updateText"><b>(for free)</b></span> </td> It's a very basic function but you can build on it if or when you need to. EDIT: Added "else" condition.. Adam -
[SOLVED] script instead of site
Adam replied to Silverado_NL's topic in PHPFreaks.com Website Feedback
I think it's a pretty good idea, suggest it in the "Questions, Comments & Suggestions" forum .. Adam -
Windows allowed me to create the file, but from the UNIX command line it got stuck (probably looking for a second single quote) - I'd definitely advise against it as you're just going to create problems for yourself later. Could you not just use Lenveloppe.html? Adam
-
...eh? That's pretty different code to your first post. Which query exactly are you trying to cycle through? Adam
-
Add: $email_webuser = mysql_real_escape_string($_POST['email_webuser']); ... somewhere before the query in your file. Adam
-
There's no existing function in JavaScript to validate an email (at least to my knowledge) so you'd probably need to use a custom function (there's loads on Google - I'll just use the one from first result) .. <script LANGUAGE="JavaScript"> <!-- function validate(frm) { // // Check the Email field to see if any characters were entered // if (frm.productuse.value.length == 0) { alert("Please tell us why you require this product."); frm.productuse.focus(); return false; } else if (frm.disclaimer.checked == false) { alert("You must read the disclaimer before requesting a quote."); frm.disclaimer.focus(); return false; } else if (is_email(frm.custemail.value) == false) { alert("Please enter a valid email address."); frm.custemail.focus(); return false; } } function is_email(str) { var at="@"; var dot="."; var lat=str.indexOf(at); var lstr=str.length; var ldot=str.indexOf(dot); if (str.indexOf(at)==-1){ return false; } if (str.indexOf(at)==-1 || str.indexOf(at)==0 || str.indexOf(at)==lstr){ return false; } if (str.indexOf(dot)==-1 || str.indexOf(dot)==0 || str.indexOf(dot)==lstr){ return false; } if (str.indexOf(at,(lat+1))!=-1){ return false; } if (str.substring(lat-1,lat)==dot || str.substring(lat+1,lat+2)==dot){ return false; } if (str.indexOf(dot,(lat+2))==-1){ return false; } if (str.indexOf(" ")!=-1){ return false; } return true; } //--> </SCRIPT> Not tested but should work no probs! Adam
-
Where does "$email_webuser" come from? Try using: $r = mysql_query($query) or die(mysql_error()); Adam
-
$src = '../../img/icons/'.$id.'/grav/slides/' .$a; Where does $id come from? Adam
-
Hah oh right - never mind! Adam
-
Try using a different loop.. foreach ($_FILES as $file) { You'd then access the array slightly different.. $filename = $file['userfile']['name']; I've not tested this.. Adam
-
The MySQL behind it.. $rowToGet = 5; // bare in mind results will start at 0 so 5 will return result 6 $query = mysql_query("SELECT * FROM Email_Inb LIMIT ".$rowToGet.", 1"); Hope this helps.. Adam
-
Would it not be possible to have more specific RSS feeds? I don't often go in half the boards here and would be helpful to be able to subscribe to just the boards I want. There's a mod available: http://custom.simplemachines.org/mods/index.php?mod=376 Adam
-
~ 2 months of work, for a mention in the credits? You'll be hard pressed to find someone willing I reckon! When even is the BETA release likely to be? I'll be honest you make it sound like you're doing them a favour, rather than the other way round. I'd suggest a more relaxed approach... Adam
-
Could you paste the code of your login form (in [ code ] tags)? Be able to then see how your system identifies a logged in user then.. Adam
-
I like the header image, though there's no actual logo or title... Color scheme is dark but works well. I'm not keen on the red inputs on the login & register pages - I think you have the gradient the wrong way round; makes them appear outwards rather than inwards.. if you get me? And I'd make them a little more subtle. With the gap you have on the front page I'd probs put a login form, so you don't have to go to login page every time! I think overall it's got the makings of a nice site but at the minute looks very 'templatish'! Try to fill the main content area better rather than having a smaller table in it! Oh and also you're HTML doesn't validate! Adam
-
[SOLVED] Spacing Problem in table when using Paging...
Adam replied to asad_black's topic in PHP Coding Help
I can't see any difference? Adam -
Looks like crypt to me! Very similar output.. Adam
-
Cant manipulate my last database column within php!...pliiiiiz help
Adam replied to joaca's topic in PHP Coding Help
So what does happen if $row["regno"] doesn't equal $row["firstchoice"], and $row["regno"] doesn't equal $row["secondchoice"], and $row["regno"] doesn't equal $row["thirdchoice"] ? Syntactically, if the conditions said above are met there's no reason why the last 'if' statement wouldn't be run. The problem must lye within your own logic - or data. Try adding some debug like (just after: $rowThree = mysql_fetch_array($resultThree);): print $row['regno'] . '<br />'; print_r($rowThree); To see what values are being passed through the 'if' statements.. Adam