Geekzone: technology news, blogs, forums
Guest
Welcome Guest.
You haven't logged in yet. If you don't have an account you can register now.




635 posts

Ultimate Geek
Inactive user


#153760 7-Oct-2014 07:12
Send private message

Hi All,

I need to find a way to progmatically and regularly (probably via cron) upload a file to a website which requires a login.

I cant see any php or aspx - looks all like html from this end.

Any thoughts on how to do this, like what language etc?

Regards

-Al


Create new topic
16206 posts

Uber Geek

Trusted
Subscriber

  #1148841 7-Oct-2014 07:41
Send private message

More details. Client, server, authentication type, file type. It's probably just a script doing basic auth, you can probably find something online.

1819 posts

Uber Geek

Trusted

  #1149030 7-Oct-2014 11:48
Send private message

If you can only see the HTML side of things then a Javascript/greasemonkey might be what you need.
But like Timmmay said, more details please.

 
 
 
 


160 posts

Master Geek


  #1149120 7-Oct-2014 13:23
Send private message

You need CURL for that. But what kind of authentification there?
Is this http auth or sending some request to login and then receiving cookie?

Here example of curl upload command line:

 

curl -i -F name=test -F filedata=@localfile.jpg http://example.org/upload

16206 posts

Uber Geek

Trusted
Subscriber

  #1149377 7-Oct-2014 18:22
Send private message

Sometimes you can use something like  http://username:password@example.com/ to authenticate. Otherwise just a basic script that does the type of login required.

66 posts

Master Geek


  #1149465 7-Oct-2014 20:16
Send private message

You could try autoit if it can run on a windows machine. https://www.autoitscript.com
It can be scripted to open a browser, go to a web page log in and then fill out a form.

66 posts

Master Geek


  #1149530 7-Oct-2014 21:31
Send private message

If you want something php based you may be able to simple http://simpletest.org/en/download.html I have used it a few times to browse site and fill in forms. 
It makes Php pretend to be a web browser interact with pages. I havent tried it to do uploads though.

I think the class has lots of other functionality but I havent used that.



635 posts

Ultimate Geek
Inactive user


  #1152103 12-Oct-2014 11:12
Send private message

curl is what I need.

I have been trying with curl without much success.

Any curl experts here?

 
 
 
 


160 posts

Master Geek


  #1152204 12-Oct-2014 14:33
Send private message

Not an expert, but I think I could help.
So, if you need to login to system and then upload file, first question is what kind of login used on web site?
There could be http auth used and regular login/pass via post used by most sites.

Create new topic




News »

Freeview On Demand app launches on Sony Android TVs
Posted 6-Aug-2020 13:35


UFB hits more than one million connections
Posted 6-Aug-2020 09:42


D-Link A/NZ extends COVR Wi-Fi EasyMesh System series with new three-pack
Posted 4-Aug-2020 15:01


New Zealand software Rfider tracks coffee from Colombia all the way to New Zealand businesses
Posted 3-Aug-2020 10:35


Logitech G launches Pro X Wireless gaming headset
Posted 3-Aug-2020 10:21


Sony Alpha 7S III provides supreme imaging performance
Posted 3-Aug-2020 10:11


Sony introduces first CFexpress Type A memory card
Posted 3-Aug-2020 10:05


Marsello acquires Goody consolidating online and in-store marketing position
Posted 30-Jul-2020 16:26


Fonterra first major customer for Microsoft's New Zealand datacentre
Posted 30-Jul-2020 08:07


Everything we learnt at the IBM Cloud Forum 2020
Posted 29-Jul-2020 14:45


Dropbox launches native HelloSign workflow and data residency in Australia
Posted 29-Jul-2020 12:48


Spark launches 5G in Palmerston North
Posted 29-Jul-2020 09:50


Lenovo brings speed and smarter features to new 5G mobile gaming phone
Posted 28-Jul-2020 22:00


Withings raises $60 million to enable bridge between patients and healthcare
Posted 28-Jul-2020 21:51


QNAP integrates Catalyst Cloud Object Storage into Hybrid Backup solution
Posted 28-Jul-2020 21:40



Geekzone Live »

Try automatic live updates from Geekzone directly in your browser, without refreshing the page, with Geekzone Live now.


Support Geekzone »

Our community of supporters help make Geekzone possible. Click the button below to join them.

Support Geezone on PressPatron



Are you subscribed to our RSS feed? You can download the latest headlines and summaries from our stories directly to your computer or smartphone by using a feed reader.

Alternatively, you can receive a daily email with Geekzone updates.