Jump to content

.josh

Staff Alumni
  • Posts

    14,780
  • Joined

  • Last visited

  • Days Won

    43

Everything posted by .josh

  1. You have a problem with your logic. The email function gets called no matter what, even if user gets 1 or more error messages. You need to rewrite your conditions to add error messages to a variable, and then only call the mail function if there is no error message variable. (and echo the variable if there is). But that's not why you are not getting an email. You have your arguments all wrong. Read the manual entry for mail to see what the arguments are supposed to be.
  2. ajax is a javascript method where you use some js functions to make a request to a server-side script and receive results, whenever events on the page occurs, like element clicks, focus, blur, etc...
  3. cast it as an int. it will chop it all off. $x = (int) (111/7); or you can use floor to always round down to whole number. or if you want to round up you can use ceil. or round will round up or down, to nearest whole number.
  4. javascript can't hide the data if javascript isn't enabled...
  5. jack got it all wrong. It's like this: $text = str_replace(array('<', '>'), '', $text);
  6. those examples are the complete code. Slap script tags around one of them and paste to your page.
  7. well if you have a login system in place, then you already have code that does stuff based on user logging in/out. you just put it on your login/logout landing page(s). So when they load up, the js code gets executed.
  8. woulda looked better on a hummer.
  9. also it looks like your variables are empty. Make sure you are using the proper $_GET['varnamehere']. Make sure you are sending them via the GET method in the first place (are they coming from a form via POST method, for instance? Should be $_POST['varnamehere'])
  10. remove all those \
  11. that's what you get for not being around forever
  12. your syntax highlighting shows you the problem. You're closing out the string with those double quotes. Use single quotes around all your vars in your query '$firstName%'
  13. why do you think there are so many zombie movies? It's an attempt to prepare the masses for it, without coming right out and saying it and freaking everybody out. Same with all the other end of the world movies with comets and aliens and shit. The govt. would rather keep it all a secret but they know it's only a matter of time before all hell breaks loose, so they push the movie industry to make movies about them, so people will know what to do instead of running around all panicky.
  14. inside your iframe code, you can use window.parent to target the parent window (using js). So if you want to "refresh" the page, you can do for instance window.parent.href='urlhere' or window.parent.reload() etc.. You can target elements etc.. doing window.parent.getElementById('idhere') etc...
  15. basically it means you can't do a subquery selecting data from the same table you are updating. To get around it, you have to create a temp table and/or temp vars. I don't personally know how to write that for you; that's beyond my sql knowledge. I'll move this to the sql forum where you'll get a more specific answer.
  16. First, decide whether you want your wordwrap to create a new line in the middle of a word or not. If you do NOT want it to start a new line in the middle of a word, set the 4th argument to 0 or false. If you DO want it to start a new line, regardless of whether the line length specified in the 2rd argument is in the middle of a word, set it to 1 or true. 2nd: imagestring does not recognize your newline characters. In order to achieve your wordwrap using it, after you wordwrap, you must explode at the \n and run imagestring for every array element from the explode, making sure to increment the y coord by your font size. There is an alternative method of doing this, with imagettftext, which does recognize line breaks. Read the documentation/user notes from the link, or you can check out this tutorial that makes use of it.
  17. change your die to: die(mysql_error() . "<br/>query: " . $query); it will post what the actual error is and what you are trying to send to the db. Maybe you mispelled a table/column name (they are case sensitive even).
  18. Also, $dbc = mysql_connect('location', 'username', 'password', 'database_name') or die('Error connecting to MySQL server.'); I hope that you just changed the location, username and password arguments to that for posting purposes, because you need to put the real info in there for it to work. Also, the 'database_name' does not go in the mysql_connect. You need to specify the database name with mysql_select_db after the mysql_connect
  19. you use it for elements like file type. But your OP did not show that other stuff in there. All you had was a text field, hence PFM's question.
  20. google ajax uploaders
  21. you could try using ob_flush
  22. so... $_POST['F'] doesn't work for you?
  23. Anything that bleeds for 5-7 days and doesn't die should be killed. It may be a zombie. Just remember that. You think I'm playin' around about zombies. That shit is gonna happen for real. Some idiot scientist out there is gonna make some virus because he feels it is more important to find out whether it can be done than thinking about whether it should be done, and he's going to foolishly think it can be contained. Or someone will steal it and use it for dastardly things. And then the scientist will be like hey, it's not my fault, I just created it. I'm not the one who used it. Wtf kind of reasoning is that? Fuck that noise. I'd smite him twice. Expose him to his own virus. I'd be like, "how do you like them apples?" Hopefully the virus will be named after an apple so that phrase would be all the more impressive.
  24. Well, you know, its my time of the month, so I'm having very little tolerance for trolls right now.
  25. well I definitely agree that the better method would be to put your terms and definitions into a database, but it's sounding like nobody wants to go through that effort, so we're exploring the best alternative.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.