Search found 13 matches

by legoman69
Sun Mar 05, 2006 7:28 pm
Forum: PHP - Code
Topic: Echo and language
Replies: 7
Views: 453

Echo and language

Hi again,
How can I use different languages with the echo command?
For example if I write

Code: Select all

echo "something in Greek language";
it doesn't give the output in Greek..
Any help?

thx
by legoman69
Sun Feb 26, 2006 6:05 am
Forum: PHP - Code
Topic: upload script+html-(complete newbie)
Replies: 22
Views: 1540

Ok guys,i did some major changes,in order to find out what's the problem in the part of the script which checks the extension of each file. So,here's the new version: <? //user defined variables $abpath = "/var/www/vhosts/mysite/subs/images/httpdocs/images"; //Absolute path to where images...
by legoman69
Sun Feb 26, 2006 4:37 am
Forum: PHP - Code
Topic: upload script+html-(complete newbie)
Replies: 22
Views: 1540

I changed the file_exists part to this: @move_uploaded_file($_FILES['img1']['tmp_name'], $abpath . '/' . $_FILES['img1']['name']) ; if (file_exists($abpath . $_FILES['img1']['name'])) { $log .= "File 1 was uploaded<br>"; } and i don't get the "division by zero" error. But still i...
by legoman69
Sat Feb 25, 2006 2:05 pm
Forum: PHP - Code
Topic: upload script+html-(complete newbie)
Replies: 22
Views: 1540

I modified a little bit the script,and now it looks like this: <? //user defined variables $abpath = "/var/www/vhosts/mysite/subs/images/httpdocs/images"; //Absolute path to where images are uploaded. No trailing slash $sizelim = "no"; //Do you want size limit, yes or no $size = ...
by legoman69
Sat Feb 25, 2006 12:58 pm
Forum: PHP - Code
Topic: upload script+html-(complete newbie)
Replies: 22
Views: 1540

The simple version of the script worked fine, but when I modified it this way: <? //user defined variables $abpath = "/var/www/vhosts/mysite/subs/images/httpdocs/images"; //Absolute path to where images are uploaded. $sizelim = "no"; //Do you want size limit, yes or no $size = &q...
by legoman69
Sat Feb 25, 2006 11:39 am
Forum: PHP - Code
Topic: upload script+html-(complete newbie)
Replies: 22
Views: 1540

ohh yeaahh,now we're talking!
It's working,finally! :D

"In the begining I just wanted to use an upload script..Now i think it would be useful to learn some php." (c) Another satisfied customer

thanks a lot feyd :wink:
by legoman69
Sat Feb 25, 2006 11:29 am
Forum: PHP - Code
Topic: upload script+html-(complete newbie)
Replies: 22
Views: 1540

Good question :D
I think from here:

Code: Select all

<form method=POST action=do_upload.php enctype=multipart/form-data>
<p>Files to upload:<br>
<input type=file name=img1 size=30><br>
<input type="submit" name="submit" value="Upload">
by legoman69
Sat Feb 25, 2006 11:10 am
Forum: PHP - Code
Topic: upload script+html-(complete newbie)
Replies: 22
Views: 1540

I modified the script this way,to meet my needs: <? //user defined variables $abpath = "/var/www/vhosts/mysite/subs/images/httpdocs/images"; //Absolute path to upload folder $sizelim = "no"; //Do you want size limit, yes or no $size = "2500000"; //What do you want size ...
by legoman69
Fri Feb 24, 2006 5:40 pm
Forum: PHP - Code
Topic: upload script+html-(complete newbie)
Replies: 22
Views: 1540

i've read your link,but no luck :( I've got this far: move_uploaded_file("$abpath/$_FILES['img1']['name']", $abpath . '/var/www/vhosts/ultratech.gr/subdomains/images/httpdocs' . $_FILES['img1']['name'] ) ; but i still get this: Parse error: parse error, expecting `T_STRING' or `T_VARIABLE'...
by legoman69
Fri Feb 24, 2006 3:39 pm
Forum: PHP - Code
Topic: upload script+html-(complete newbie)
Replies: 22
Views: 1540

I modified this part: move_uploaded_file($img1, "$abpath/$_FILES['img1']['name']") // to $abpath . '/images' . $_FILES['img1']['name'] or $log .= "Couldn't copy image 1 to server<br>"; if (file_exists("$abpath/$_FILES['img1']['name']")) { $log .= "File 1 was upload...
by legoman69
Fri Feb 24, 2006 3:04 pm
Forum: PHP - Code
Topic: upload script+html-(complete newbie)
Replies: 22
Views: 1540

ok,i understand the problem. So,i modified the part which refers to file 1,this way: //begin upload 1 //checks if file exists if ($_FILES['img1']['name'] == "") { $log .= "No file selected for upload 1<br>"; } if ($_FILES['img1']['name'] != "") { //checks if file exists...
by legoman69
Fri Feb 24, 2006 2:22 pm
Forum: PHP - Code
Topic: upload script+html-(complete newbie)
Replies: 22
Views: 1540

thx for the fast reply. I hope by "results",you mean this: PHP Version: 4.3.2 PHP OS: Linux Error Reporting: 2039 (E_USER_NOTICE | E_USER_WARNING | E_USER_ERROR | E_COMPILE_WARNING | E_COMPILE_ERROR | E_CORE_WARNING | E_CORE_ERROR | E_PARSE | E_WARNING | E_ERROR) Register Globals: Off Disp...
by legoman69
Fri Feb 24, 2006 1:00 pm
Forum: PHP - Code
Topic: upload script+html-(complete newbie)
Replies: 22
Views: 1540

upload script+html-(complete newbie)

feyd | Please use and tags where appropriate when posting code. Read: [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url][/color] hi, I've found a script that allows users to upload files to a web folder,but i can't get it work!it's driving me crazy(propably bec...