Forums
This topic is locked
PHakt and uploading images
Posted 29 Nov 2001 12:13:03
1
has voted
29 Nov 2001 12:13:03 Oli Wilkinson posted:
Using MySQL/PHP and the PHakt extension for DW.I want to give people the ability to upload images. However, in dreamweaver, in the insert records option, the image can only be submitted as the following types:
Text
Numeric
Date
Date MS Access
Checkbox Y,N
Checkbox 1,0
Checkbox -1,0
Checkbox MS Access
How can I get the image to upload properly?
FYI - My column in MySQL is a "blob"
Cheers
Oli Wilkinson
Replies
Replied 29 Nov 2001 15:33:39
29 Nov 2001 15:33:39 Keith Slater replied:
Tim actually made an extension to upload files, you can get it here: www.udzone.com/go?730
Keith Slater
Keith Slater
Replied 29 Nov 2001 18:35:14
29 Nov 2001 18:35:14 Oli Wilkinson replied:
Many Thanks for that!
Replied 29 Nov 2001 19:44:02
29 Nov 2001 19:44:02 Oli Wilkinson replied:
I'm having a few probles with this - when i try to upload a file i get an error message:
Unable to copy file. Check Permissions of Target Directory.
I'm confused....again!
Unable to copy file. Check Permissions of Target Directory.
I'm confused....again!
Replied 29 Nov 2001 23:46:07
29 Nov 2001 23:46:07 Keith Slater replied:
make sure the directory your writing to has 755 permissions, if you try it and that dont work give it 777 permissions if your webserver allows you to
Keith Slater
Keith Slater
Replied 30 Nov 2001 10:58:50
30 Nov 2001 10:58:50 Oli Wilkinson replied:
I've tried that, but still no joy - I'm getting the same error message! Little bit stumped on this...
Replied 30 Nov 2001 12:03:56
30 Nov 2001 12:03:56 enquest enquest1 replied:
Where do you place the picture... Make sure you follow the instructions of Tim
Replied 30 Nov 2001 12:09:34
30 Nov 2001 12:09:34 Oli Wilkinson replied:
I place the picture in my normal "images" folder. Might have to try and redo the form page again...?
Replied 30 Nov 2001 15:13:22
30 Nov 2001 15:13:22 Keith Slater replied:
I have that problem all the time... I found that with the PHP.ini if I change the tmp_upload_folder to the directory that your having everything upload to then it'll work. I'm sure it isnt supposed to be that way and its supposed to stay at /tmp but that works for me
Keith Slater
Keith Slater
Replied 30 Nov 2001 16:31:12
30 Nov 2001 16:31:12 Oli Wilkinson replied:
Cheers Keith - may have to try that - where is the php.ini file to be found?
Replied 30 Nov 2001 17:54:59
30 Nov 2001 17:54:59 Oli Wilkinson replied:
I have narrowed it down to my php.ini settings, because there is "no value" specified for the "upload_tmp_dir".
But this is on a remote server - so how do I adjust the php.ini?
Cheers
But this is on a remote server - so how do I adjust the php.ini?
Cheers
Replied 30 Nov 2001 19:57:58
30 Nov 2001 19:57:58 Keith Slater replied:
Well it depends.. Is your server on windows or linux.. Is this your server or a hosting companies?? If its a hosting companies then their probably gonna have to do it and a lot of companies wont. The whole upload tmp dir is weird, It works right on some servers and others I cant get it to work.
Keith Slater
Keith Slater
Replied 30 Nov 2001 20:51:54
30 Nov 2001 20:51:54 Bruno Mairlot replied:
<BLOCKQUOTE id=quote><font size=1 face="Verdana, Arial, Helvetica" id=quote>quote:<hr height=1 noshade id=quote>
Cheers Keith - may have to try that - where is the php.ini file to be found?
<hr height=1 noshade id=quote></BLOCKQUOTE id=quote></font id=quote><font face="Verdana, Arial, Helvetica" size=2 id=quote>
Try this little script, and search for ".ini", you'll find it <img src=../images/dmxzone/forum/icon_smile_wink.gif border=0 align=middle>
<?php
echo phpinfo()
?>
--- Better to die trying, than never try at all ---
Cheers Keith - may have to try that - where is the php.ini file to be found?
<hr height=1 noshade id=quote></BLOCKQUOTE id=quote></font id=quote><font face="Verdana, Arial, Helvetica" size=2 id=quote>
Try this little script, and search for ".ini", you'll find it <img src=../images/dmxzone/forum/icon_smile_wink.gif border=0 align=middle>
<?php
echo phpinfo()
?>
--- Better to die trying, than never try at all ---
Replied 05 Dec 2001 12:13:58
05 Dec 2001 12:13:58 Tim Green replied:
To temporarily change a value in the PHP.ini you can use the ini_set command.
At the very top of your page try:-
<?php
ini_set("upload_tmp_dir","path/to/directory"
?>
If you cannot upload and your target directory has the correct permissions, it is likely that your temporary directory does not have the correct permissions. So setting the temp directory permissions to 755 or 777 can solve this problem.
Of course, that won't help if there is no entry for the upload_tmp_dir in the first place.
Tim Green
Extension & PHP TalkZone Manager
<font size=1>-------------------------------------------
<i>Please read the Forum FAQ before posting
a question to this TalkZone.</i>
-------------------------------------------
www.UDzone.com : A dynamic Dreamweaver,
Ultradev and Fireworks site for developers
by developers.
-------------------------------------------</font id=size1>
At the very top of your page try:-
<?php
ini_set("upload_tmp_dir","path/to/directory"
?>
If you cannot upload and your target directory has the correct permissions, it is likely that your temporary directory does not have the correct permissions. So setting the temp directory permissions to 755 or 777 can solve this problem.
Of course, that won't help if there is no entry for the upload_tmp_dir in the first place.
Tim Green
Extension & PHP TalkZone Manager
<font size=1>-------------------------------------------
<i>Please read the Forum FAQ before posting
a question to this TalkZone.</i>
-------------------------------------------
www.UDzone.com : A dynamic Dreamweaver,
Ultradev and Fireworks site for developers
by developers.
-------------------------------------------</font id=size1>