Programming Forums
User Name Password Register
 

RSS Feed
FORUM INDEX | TODAY'S POSTS | UNANSWERED THREADS | ADVANCED SEARCH

Reply
 
Thread Tools Display Modes
Old Apr 22nd, 2005, 2:43 PM   #11
Pizentios
Programming Guru
 
Pizentios's Avatar
 
Join Date: May 2004
Location: Brandon, Manitoba, Canada
Posts: 2,023
Rep Power: 7 Pizentios is on a distinguished road
Send a message via ICQ to Pizentios Send a message via MSN to Pizentios
are you getting any errors with this code that you posted? if so post em, cause it makes my life a little easier :-)
__________________
Profanity is the one language that all programmers understand.

Check out my Blog <---updated Nov 30 2007!
Pizentios is offline   Reply With Quote
Old Apr 22nd, 2005, 4:20 PM   #12
dmorales
Programmer
 
Join Date: Feb 2005
Posts: 74
Rep Power: 4 dmorales is on a distinguished road
well they're in french, but I'm sure you'll get the gist.

Erreur de syntaxe près de '.Array[name], 'c:/Program Files/EasyPHP1-7/www/work order files/' à la ligne 2

Everything else works. It inserts into the database and the files upload to where they are supposed to go. I just can't get ht path of the uploaded files to insert into the table also.
__________________
Lorem ipsum dolor sit amet...
dmorales is offline   Reply With Quote
Old Apr 23rd, 2005, 2:59 AM   #13
codetaino
Programmer
 
codetaino's Avatar
 
Join Date: Jan 2005
Location: Bayamon, Puerto Rico
Posts: 71
Rep Power: 4 codetaino is on a distinguished road
the error is an error of syntax for us to be able to help you please publish at least the segment of the code that the error reffer, but trying to gues maybe you are concatenating a string and the part that has the error is an array so what you should do is change Array[name] for Array['name']... again im just giving a shot blinded publishing that line 2 of the php file would help a lot

take care

-codetaino

PS: Any mistake is 4:00am havent sleep, please forgive me
__________________
"God bless u all" :)
codetaino is offline   Reply With Quote
Old Apr 24th, 2005, 9:56 AM   #14
codetaino
Programmer
 
codetaino's Avatar
 
Join Date: Jan 2005
Location: Bayamon, Puerto Rico
Posts: 71
Rep Power: 4 codetaino is on a distinguished road
Im back... now is 10:23AM and i think i found your error... when you reffer to the files in example in this line:[PHP]$add_contents = "insert into wocontents values ('', $master_id, now(), now(), '$_POST[add_work_order_text]',
'c:/Program Files/EasyPHP1-7/www/screenshot files/'.$_FILES[add_work_order_screen][name], 'c:/Program Files/EasyPHP1-7/www/work order files/'.$_FILES[add_work_order][name])";[/PHP] you use a dot after the single quotation this will make the file name stay out of the quotations... also when I reffer to arrays inside strings I use other method... your method works with single arrays but apparently does not work when you have bidimentional arrays... so change the previews line to [PHP]$add_contents = "insert into wocontents values ('', $master_id, now(), now(), '$_POST[add_work_order_text]',
'c:/Program Files/EasyPHP1-7/www/screenshot files/{$_FILES['add_work_order_screen']['name']}', 'c:/Program Files/EasyPHP1-7/www/work order files/{$_FILES['add_work_order']['name']}')";[/PHP] and all the previous lines you reffer to files inside strings without the {}. that in my knowledge should do the trick

-codetaino
__________________
"God bless u all" :)
codetaino is offline   Reply With Quote
Old Apr 25th, 2005, 11:57 AM   #15
dmorales
Programmer
 
Join Date: Feb 2005
Posts: 74
Rep Power: 4 dmorales is on a distinguished road
That is Perfect! Wow, Thanks! I don't think I would have ever figured that out! :p

It works exactly how I wanted it to!
__________________
Lorem ipsum dolor sit amet...
dmorales is offline   Reply With Quote
Old Apr 25th, 2005, 2:08 PM   #16
Pizentios
Programming Guru
 
Pizentios's Avatar
 
Join Date: May 2004
Location: Brandon, Manitoba, Canada
Posts: 2,023
Rep Power: 7 Pizentios is on a distinguished road
Send a message via ICQ to Pizentios Send a message via MSN to Pizentios
glad to hear that we could help you out.
__________________
Profanity is the one language that all programmers understand.

Check out my Blog <---updated Nov 30 2007!
Pizentios is offline   Reply With Quote
Reply

Bookmarks

« Previous Thread in Forum | Next Thread in Forum »

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump




DaniWeb IT Discussion Community
All times are GMT -5. The time now is 11:49 PM.

Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC