14 Replies - 1624 Views - Last Post: 11 December 2010 - 08:44 AM Rate Topic: -----

#1 semaz   User is offline

  • D.I.C Head

Reputation: 0
  • View blog
  • Posts: 116
  • Joined: 24-November 08

web-based script to upload a file to the hosting websites

Posted 04 December 2010 - 02:08 PM

hello guys , i need to write a web-based script to upload a file to the following hosting websites, similar to mirrorcreator.com

- Someone inputs a file onto the website, and it uploads it to the following websites:

1) FileDude.com
2) FileApe.com
3) zShare.net
4) Mediafire.com
5) 2shared.com
6) Rocketfile.net
7) rapidshare.com

what i've done is the for the rapidshare.com , here's the code :
<form name="ul" method="post" action="http://rs97l3.rapidshare.com/cgi-bin/upload.cgi?rsuploadid=99619963777997544" enctype="multipart/form-data" onsubmit="document.ul.u.value='Please wait ...';document.ul.u.disabled=true">
Choose your upload-datapath: &nbsp;&nbsp;&nbsp; 

<br>

<div id="files"><input type="file" size="64" name="filecontent"> <input type="submit" name="u" value="Upload!"></div>

</form>



i don't know now what to type for the rest of the hosting files in the action

Is This A Good Question/Topic? 0
  • +

Replies To: web-based script to upload a file to the hosting websites

#2 CTphpnwb   User is offline

  • D.I.C Lover
  • member icon

Reputation: 3839
  • View blog
  • Posts: 14,005
  • Joined: 08-August 08

Re: web-based script to upload a file to the hosting websites

Posted 04 December 2010 - 03:12 PM

A quick search showed this:
http://www.w3schools...file_upload.asp
Was This Post Helpful? 0
  • +
  • -

#3 creativecoding   User is offline

  • Hash != Encryption
  • member icon


Reputation: 931
  • View blog
  • Posts: 3,216
  • Joined: 19-January 10

Re: web-based script to upload a file to the hosting websites

Posted 04 December 2010 - 10:13 PM

Just use Google Chrome's inspector to find where the forms lead to

I got http://srv2.nl1.filedude.com/upload with the method of post for filedude.
Was This Post Helpful? 0
  • +
  • -

#4 semaz   User is offline

  • D.I.C Head

Reputation: 0
  • View blog
  • Posts: 116
  • Joined: 24-November 08

Re: web-based script to upload a file to the hosting websites

Posted 05 December 2010 - 01:55 AM

View PostCTphpnwb, on 05 December 2010 - 12:12 AM, said:

A quick search showed this:
http://www.w3schools...file_upload.asp


I know that page , it only shows me the way to upload a file to a folder in your PC
What i wanna do is to upload to different hosting sites

View Postcreativecoding, on 05 December 2010 - 07:13 AM, said:

Just use Google Chrome's inspector to find where the forms lead to

I got http://srv2.nl1.filedude.com/upload with the method of post for filedude.


I've tried that code , but when uploading a file the browser is directed to filedude.com and displays me that error msg :

Quote

Upload Failed!

You didn't submit a file! Go back and try again.

Was This Post Helpful? 0
  • +
  • -

#5 CTphpnwb   User is offline

  • D.I.C Lover
  • member icon

Reputation: 3839
  • View blog
  • Posts: 14,005
  • Joined: 08-August 08

Re: web-based script to upload a file to the hosting websites

Posted 05 December 2010 - 06:58 AM

I don't think you can set up a form with an action pointing to more than one server at a time. You need to upload the file to your server so that you can then transfer it to the other sites. I haven't tried it, but I believe you can use curl to transfer the file.
Was This Post Helpful? 0
  • +
  • -

#6 semaz   User is offline

  • D.I.C Head

Reputation: 0
  • View blog
  • Posts: 116
  • Joined: 24-November 08

Re: web-based script to upload a file to the hosting websites

Posted 05 December 2010 - 08:07 AM

View PostCTphpnwb, on 05 December 2010 - 03:58 PM, said:

I don't think you can set up a form with an action pointing to more than one server at a time. You need to upload the file to your server so that you can then transfer it to the other sites. I haven't tried it, but I believe you can use curl to transfer the file.


you can take a look at this website : www.mirrorcreator.com

it does exactly what i wanna do
Was This Post Helpful? 0
  • +
  • -

#7 CTphpnwb   User is offline

  • D.I.C Lover
  • member icon

Reputation: 3839
  • View blog
  • Posts: 14,005
  • Joined: 08-August 08

Re: web-based script to upload a file to the hosting websites

Posted 05 December 2010 - 09:19 AM

Without completely deciphering their code I can't be sure, but this line:
	url: "fnvalidator.php?fn="+filename+"&fid="+fid,


seems to indicate that they are uploading the file to their server and from there they send it to the selected sites.
Was This Post Helpful? 0
  • +
  • -

#8 semaz   User is offline

  • D.I.C Head

Reputation: 0
  • View blog
  • Posts: 116
  • Joined: 24-November 08

Re: web-based script to upload a file to the hosting websites

Posted 05 December 2010 - 09:28 AM

View PostCTphpnwb, on 05 December 2010 - 06:19 PM, said:

Without completely deciphering their code I can't be sure, but this line:
	url: "fnvalidator.php?fn="+filename+"&fid="+fid,


seems to indicate that they are uploading the file to their server and from there they send it to the selected sites.



if your idea is true , so what's the use of those hosting sites since they host everything on theirs ?
Was This Post Helpful? 0
  • +
  • -

#9 CTphpnwb   User is offline

  • D.I.C Lover
  • member icon

Reputation: 3839
  • View blog
  • Posts: 14,005
  • Joined: 08-August 08

Re: web-based script to upload a file to the hosting websites

Posted 05 December 2010 - 12:06 PM

I don't believe that they're storing it permanently on their site. They upload it to their site and then use some method (possibly curl) to transfer the file to the site(s) that the user chooses, then they probably delete the file from their site. It's hard to be sure without knowing what their server code looks like, but that's my guess based on their html and javascript.

This post has been edited by CTphpnwb: 05 December 2010 - 12:07 PM

Was This Post Helpful? 0
  • +
  • -

#10 semaz   User is offline

  • D.I.C Head

Reputation: 0
  • View blog
  • Posts: 116
  • Joined: 24-November 08

Re: web-based script to upload a file to the hosting websites

Posted 06 December 2010 - 02:00 AM

View PostCTphpnwb, on 05 December 2010 - 09:06 PM, said:

I don't believe that they're storing it permanently on their site. They upload it to their site and then use some method (possibly curl) to transfer the file to the site(s) that the user chooses, then they probably delete the file from their site. It's hard to be sure without knowing what their server code looks like, but that's my guess based on their html and javascript.


ok ,now we're back to the same point

how can i do that using PHP , or curl ?

i mean to upload the file to the chosen hosting sites
Was This Post Helpful? 0
  • +
  • -

#11 CTphpnwb   User is offline

  • D.I.C Lover
  • member icon

Reputation: 3839
  • View blog
  • Posts: 14,005
  • Joined: 08-August 08

Re: web-based script to upload a file to the hosting websites

Posted 06 December 2010 - 07:01 AM

See the curl command.
Was This Post Helpful? 0
  • +
  • -

#12 semaz   User is offline

  • D.I.C Head

Reputation: 0
  • View blog
  • Posts: 116
  • Joined: 24-November 08

Re: web-based script to upload a file to the hosting websites

Posted 11 December 2010 - 06:24 AM

View PostCTphpnwb, on 06 December 2010 - 04:01 PM, said:



i'm not good in using curl :(

can you please only tell me how to update my HTML code to upload to those hosting site ?
Was This Post Helpful? -1
  • +
  • -

#13 CTphpnwb   User is offline

  • D.I.C Lover
  • member icon

Reputation: 3839
  • View blog
  • Posts: 14,005
  • Joined: 08-August 08

Re: web-based script to upload a file to the hosting websites

Posted 11 December 2010 - 06:57 AM

This topic has been open for a week and you still have no php code posted. Show a serious effort and we can help you with your code.
Was This Post Helpful? 0
  • +
  • -

#14 semaz   User is offline

  • D.I.C Head

Reputation: 0
  • View blog
  • Posts: 116
  • Joined: 24-November 08

Re: web-based script to upload a file to the hosting websites

Posted 11 December 2010 - 07:41 AM

View PostCTphpnwb, on 11 December 2010 - 03:57 PM, said:

This topic has been open for a week and you still have no php code posted. Show a serious effort and we can help you with your code.


man , i don't need a php code now

all what i wanna know is how to edit that HTML code ( i.e. action = "" ) to redirect the page to the other hosting sites like that HTML does with rapidshare.com

i've noticed that while uploading something on any host site i saw the status bar in the bottom telling me that it's try to connect to rs97l3.rapidshare.com ( if it's rapidshare.com )

so i tried this way with zshare.net , changed the HTML code to
<form name="ul" method="post" action="http://dl056.zshare.net/cgi-bin/upload.cgi" enctype="multipart/form-data" onsubmit="document.ul.u.value='Please wait ...';document.ul.u.disabled=true">
Choose your upload-datapath: &nbsp;&nbsp;&nbsp; 

<br>

<div id="files"><input type="file" size="64" name="filecontent"> <input type="submit" name="u" value="Upload!"></div>

</form>



but in vain
Was This Post Helpful? 0
  • +
  • -

#15 JackOfAllTrades   User is offline

  • Saucy!
  • member icon

Reputation: 6259
  • View blog
  • Posts: 24,028
  • Joined: 23-August 08

Re: web-based script to upload a file to the hosting websites

Posted 11 December 2010 - 08:44 AM

This is just a long-winded "g1v3 m3 t3h c0d3z" request. You are going to need to do the research to figure out how each of those stupid sites expects to receive upload requests. We are NOT going to do that for you. Perhaps you need to hire someone for that, in which case I refer you to the Post a Job forum.

Closed.
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1