[PHP] RE: Quotes in form textarea fields
Yes, the magic quotes will get you, but they are meant to protect you. Either 1. Go into php.ini and disable them 2. Create an include file that you include in each script, in it, use ini_set() to disable magic quotes at run time http://us2.php.net/manual/en/function.ini-set.php -Original Message- From: Sam Smith [mailto:[EMAIL PROTECTED] Sent: Fri 10/8/2004 6:22 AM To: PHP Cc: Subject:Quotes in form textarea fields I swear I googled for an hour first. A user enters in a textarea field of FORM1.php: Bob is high Submitted to FROM2.php we get: Bob is \high\ In a hidden field in FROM2.php we store the value: type=hidden, value=? echo stripslashes($_POST['textarea']); ? Value now Bob is high Then from FROM2.php we Submit BACK to FROM1.php and enter it back into the textarea field with: type=textarea, value=? echo $_POST['hidden']); ? we have; Bob is Everything after the first double quote is clobbered. I can fix this by putting this in FORM2.php: $APParea1 = $_POST['textarea']; $APParea1 = str_replace(\,[QT],$APParea1); and then back by putting this in FORM1.php: $APParea1 = $_POST['hidden']; $APParea1 = str_replace([QT],\,$APParea1); type=textarea, value=? echo $APParea1; ? BUT THIS must have happened many times a long long time ago to many good people and some smart function was developed, right? Thanks
[PHP] RE: displaying blob images from a mssql db
Most often, when people are storing an binary file in a db, they are storing the absolute path to the file on the file system instead. So it should be as simple as extracting the file path from the database, using the copy() function to copy that file from the original file path to a location somewhere under the public_html/www/inetpub directory so it's accessible to the web server (make sure the directory, such as images, has the proper write permissions so that the script can write a file into that directory) and then generate the img tag pointing to the new file location. -Original Message- From: blackwater dev [mailto:[EMAIL PROTECTED] Sent: Wed 10/6/2004 8:49 AM To: [EMAIL PROTECTED] Cc: Subject:displaying blob images from a mssql db Ok, I know images shouldn't be saved in the db but this isn't my db so I can't change that. Does anyone know of a good tutorial to show me how to grab these blog jpg's and display them in a browser? Thanks!
[PHP] Naming conventions
What do you use for your naming conventions for variables functions classes I'm trying to tell my students what the standard is currently. Are people using camel case or underscores or both? -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Fri 10/1/2004 11:16 AM To: [EMAIL PROTECTED] Cc: Subject:[BULK] - php-general Digest 1 Oct 2004 18:16:29 - Issue 3028 php-general Digest 1 Oct 2004 18:16:29 - Issue 3028 Topics (messages 198379 through 198445): php script run by cron job 198379 by: Merlin 198388 by: Nick Wilson Re: Zend PHP Certification test 198380 by: Curt Zirzow 198391 by: Greg Donald 198436 by: Jay Blanchard How do I produce a random database query for each day or week? 198381 by: I.A. Gray 198383 by: Merlin 198386 by: Graham Cossey 198413 by: -{ Rene Brehmer }- Zend Optimizer not installed 198382 by: Ox 198384 by: Graham Cossey 198387 by: Wee Keat 198404 by: Dan Joseph 198432 by: Ox Re: list of Months 198385 by: Marek Kilimajer 198408 by: afan.afan.net 198439 by: Paul Bissex Re: mail() and Verizon 198389 by: Sam Smith 198443 by: Sam Smith How I can get x509 certificate distinguished name? 198390 by: Diavolo PHP (anti) crash policy? 198392 by: Olaf van der Spek 198393 by: Marek Kilimajer 198394 by: Manuel Lemos 198395 by: Olaf van der Spek 198396 by: Christophe Chisogne 198397 by: Manuel Lemos 198398 by: Marek Kilimajer 198399 by: Olaf van der Spek 198401 by: Christophe Chisogne 198403 by: Manuel Lemos 198405 by: Olaf van der Spek 198409 by: Manuel Lemos 198410 by: Olaf van der Spek 198412 by: Olaf van der Spek 198417 by: Manuel Lemos 198418 by: Manuel Lemos 198420 by: Olaf van der Spek 198421 by: Olaf van der Spek 198423 by: Olaf van der Spek 198424 by: Manuel Lemos 198425 by: Manuel Lemos 198426 by: Olaf van der Spek 198427 by: Manuel Lemos 198429 by: Manuel Lemos 198430 by: Olaf van der Spek 198431 by: Olaf van der Spek 198433 by: Olaf van der Spek 198434 by: Manuel Lemos 198435 by: Manuel Lemos 198438 by: Marek Kilimajer Re: Suggestion for IN() 198400 by: Daniel Schierbeck 198402 by: Christophe Chisogne 198406 by: Daniel Schierbeck 198415 by: Ford, Mike successive imap_open calls result in failure 198407 by: felix.compsoc.nuigalway.ie 198411 by: raditha dissanayake 198419 by: felix.compsoc.nuigalway.ie 198422 by: Michael Sims Re: World time convertor 198414 by: -{ Rene Brehmer }- Re: UNSUBSCRIBE 198416 by: -{ Rene Brehmer }- Question about error_reporting() 198428 by: Al 198437 by: Greg Donald 198440 by: Al 198442 by: Greg Donald PHP Host with PayFlow Pro 198441 by: Neal Carmine Image Manipulation 198444 by: GH PHP sandbox discussion 198445 by: Jason Davidson Administrivia: To subscribe to the digest, e-mail: [EMAIL PROTECTED] To unsubscribe from the digest, e-mail: [EMAIL PROTECTED] To post to the list, e-mail: [EMAIL PROTECTED] --