Re: [WebDNA] Need some PHP help
This WebDNA talk-list message is from 2009
It keeps the original formatting.
numero = 103514
interpreted = N
texte = Pat, not sure if you got this covered. I was tempted to do this for you several times.. just can't carve out the time. Crazy busy here. Just writing to acknowledge your post.I have no idea your own PHP skills.. if mediocre-decent (like mine) and you attempt it, and get stuck, then ask a smaller question about that, and maybe we can hack it together.-Govinda> Here's a question for PHP folks:>> I'm trying to incorporate jQuery Uploadify (http:// > www.uploadify.com/) into a WebDNA site. Uploadify uses a PHP script > on a page that handles the file uploads.>> This PHP script will be called one or more times by a .swf file that > sends it individual files. The flash part can do multiple files. I > need to perform the functions in this PHP script using WebDNA. Is > anyone able to translate this to equivalent WebDNA?>>> -------------------------------------> if (!empty($_FILES)) {> $tempFile = $_FILES['Filedata']['tmp_name'];> $targetPath = $_SERVER['DOCUMENT_ROOT'] . $_REQUEST['folder'] . '/';> $targetFile = str_replace('//','/',$targetPath) . > $_FILES['Filedata']['name'];> > // $fileTypes = str_replace('*.','',$_REQUEST['fileext']);> // $fileTypes = str_replace(';','|',$fileTypes);> // $typesArray = split('\|',$fileTypes);> // $fileParts = pathinfo($_FILES['Filedata']['name']);> > // if (in_array($fileParts['extension'],$typesArray)) {> // Uncomment the following line if you want to make the directory > if it doesn't exist> // mkdir(str_replace('//','/',$targetPath), 0755, true);> > move_uploaded_file($tempFile,$targetFile);> echo "1";> // } else {> // echo 'Invalid file type.';> // }> }> ?>
Associated Messages, from the most recent to the oldest:
Pat, not sure if you got this covered. I was tempted to do this for you several times.. just can't carve out the time. Crazy busy here. Just writing to acknowledge your post.I have no idea your own PHP skills.. if mediocre-decent (like mine) and you attempt it, and get stuck, then ask a smaller question about that, and maybe we can hack it together.-Govinda> Here's a question for PHP folks:>> I'm trying to incorporate jQuery Uploadify (http:// > www.uploadify.com/) into a WebDNA site. Uploadify uses a PHP script > on a page that handles the file uploads.>> This PHP script will be called one or more times by a .swf file that > sends it individual files. The flash part can do multiple files. I > need to perform the functions in this PHP script using WebDNA. Is > anyone able to translate this to equivalent WebDNA?>>> -------------------------------------> if (!empty($_FILES)) {> $tempFile = $_FILES['Filedata']['tmp_name'];> $targetPath = $_SERVER['DOCUMENT_ROOT'] . $_REQUEST['folder'] . '/';> $targetFile = str_replace('//','/',$targetPath) . > $_FILES['Filedata']['name'];> > // $fileTypes = str_replace('*.','',$_REQUEST['fileext']);> // $fileTypes = str_replace(';','|',$fileTypes);> // $typesArray = split('\|',$fileTypes);> // $fileParts = pathinfo($_FILES['Filedata']['name']);> > // if (in_array($fileParts['extension'],$typesArray)) {> // Uncomment the following line if you want to make the directory > if it doesn't exist> // mkdir(str_replace('//','/',$targetPath), 0755, true);> > move_uploaded_file($tempFile,$targetFile);> echo "1";> // } else {> // echo 'Invalid file type.';> // }> }> ?>
Govinda
DOWNLOAD WEBDNA NOW!
Top Articles:
Talk List
The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...
Related Readings:
[NT] ie 4.0 required (1997)
test message 4 (2000)
Protect vs Authenicate (1997)
Sort Order on a page search (1997)
database visibility (2000)
WebDNA Writer Needed (1997)
Pithy questions on webcommerce & siteedit (1997)
MacAuthorize hub, no modal password dialog? (1997)
RE: Multiple Stores and WebCatalog Prefs (1997)
UPDATE PROBLEM (1997)
Question on lineitems (2002)
RE: E-mailer error codes (1997)
Error Msg (1998)
from outside to inside store direct frame template link? (2000)
WebCat2: Items xx to xx shown, etc. (1997)
Multiple Users.db Possible? (1997)
Running WebCat from a CD-ROM (1997)
Opinion: [input] should be called [output] ... (1997)
Duplicate Cart Numbers (1999)
Programmers.org (2004)