UDC - php script [message #695529] |
Mon, 11 July 2011 23:55 |
Lukas Messages: 6 Registered: July 2011 |
Junior Member |
|
|
Hi,
I need to change UDC upload target to my server, but I've got some problems with that.
First thing, which i done is modification of eclipse.ini file (tell me if everything is ok):
-startup
plugins/org.eclipse.equinox.launcher_1.2.0.v20110502.jar
--launcher.library
plugins/org.eclipse.equinox.launcher.win32.win32.x86_1.1.100.v20110502
-showsplash
org.eclipse.platform
--launcher.XXMaxPermSize
256m
--launcher.defaultAction
openFile
-vmargs
-Xms40m
-Xmx384m
-Dorg.eclipse.epp.usagedata.recording.upload-url=myserver/upload.php
Next, I tried to write php script to upload files: uploadx.csv, but nothing work. Of course I set rights 777 there where i want to upload files.
I used simple upload scripts on my websites before, but this one is too hard for me, and don't know how integrate this with eclipse.
Could you tell me how to write this php script?
Best wishes,
Luke
[Updated on: Mon, 11 July 2011 23:57] Report message to a moderator
|
|
|
Re: UDC - php script [message #695793 is a reply to message #695529] |
Tue, 12 July 2011 14:51 |
Wayne Beaton Messages: 554 Registered: December 2017 |
Senior Member |
|
|
Are you getting any error messages anywhere? Anything in any of the logs?
Do you know if a connection is being made with the server?
There is sample server code on Bug 221104. Have you looked at that?
https://bugs.eclipse.org/bugs/show_bug.cgi?id=221104
Wayne
On 07/11/2011 07:55 PM, Lukas wrote:
> Hi,
>
> I need to change UDC upload target to my server, but I've got some
> problems with that.
> First thing, which i done is modification of eclipse.ini file (tell me
> if everything is ok):
>
> -startup
> plugins/org.eclipse.equinox.launcher_1.2.0.v20110502.jar
> --launcher.library
> plugins/org.eclipse.equinox.launcher.win32.win32.x86_1.1.100.v20110502
> -showsplash
> org.eclipse.platform
> --launcher.XXMaxPermSize
> 256m
> --launcher.defaultAction
> openFile
> -vmargs
> -Xms40m
> -Xmx384m
> -Dorg.eclipse.epp.usagedata.recording.upload-url=myserver/upload.php
>
>
> Next, I tried to write php script to upload files: uploadx.csv, but
> nothing work. Of course I set rights 777 there where i want to upload
> files.
> I used simple upload scripts on my websites before, but this one is too
> hard for me, and don't know how integrate this with eclipse.
> Could you tell me how to write this php script.
>
> Best wishes,
> Luke
|
|
|
|
Re: UDC - php script [message #695893 is a reply to message #695887] |
Tue, 12 July 2011 19:02 |
Wayne Beaton Messages: 554 Registered: December 2017 |
Senior Member |
|
|
Look at the documentation for move_uploaded_file [1]. It moves only one
file, not an array.
Try:
move_uploaded_file($_FILES['uploads']['tmp_name'][0],"/myserver/pliki/".$_FILES['uploads']['tmp_name'][0]);
The order in which you dereference the $_FILES variable is important.
HTH,
Wayne
[1] http://php.net/manual/en/function.move-uploaded-file.php
On 07/12/2011 02:34 PM, Lukas wrote:
> Hi,
>
> Thank you for server files.
> I need to define path, where i can save these uploaded files on my
> server. I needn't database, I just want upload all cvs files to my
> server. Is it possible to do it easy without database?
> I tried to modify uploadmanager.class.php, I paste this code into first
> foreach loop:
> move_uploaded_file($_FILES['name']['tmp_name'],"/myserver/pliki/".$_FILES['tmp_name']['name']);
>
> but it doesn't work.
> Eclipse give me message:
> Usage data uploaded to *****************/server/upload.php in 1281
> milliseconds,
> but there is no files on my server.
>
|
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.05145 seconds