Need to run URL without opening browser - Overclock.net - An Overclocking Community

Forum Jump: 

Need to run URL without opening browser

Reply
 
Thread Tools
post #1 of 11 (permalink) Old 11-15-2017, 07:12 AM - Thread Starter
New to Overclock.net
 
dseg's Avatar
 
Join Date: Apr 2011
Location: Florida
Posts: 1,461
Rep: 49 (Unique: 46)
I am not a coder in anyway.
But I need a URL to run in the background for my security cameras.
When you enter the URL, it executes a function on the camera but I need to to happen every 5 minutes.

I was able to make a batch file but it would open a browser.
Do I need to download some kind of software program to execute a code like this?

dseg is offline  
Sponsored Links
Advertisement
 
post #2 of 11 (permalink) Old 11-15-2017, 07:20 AM
New to Overclock.net
 
mott555's Avatar
 
Join Date: Sep 2010
Posts: 2,053
Rep: 145 (Unique: 131)
Can you use wget? I assume there's a Windows version via Cygwin or something.



mott555 is offline  
post #3 of 11 (permalink) Old 11-15-2017, 08:27 AM - Thread Starter
New to Overclock.net
 
dseg's Avatar
 
Join Date: Apr 2011
Location: Florida
Posts: 1,461
Rep: 49 (Unique: 46)
Quote:
Originally Posted by mott555 View Post

Can you use wget? I assume there's a Windows version via Cygwin or something.

I found that suggestion too:
https://superuser.com/questions/873561/call-url-from-console-without-opening-in-any-browser

Do you know what my full code would be?

dseg is offline  
Sponsored Links
Advertisement
 
post #4 of 11 (permalink) Old 11-15-2017, 08:47 AM
New to Overclock.net
 
mott555's Avatar
 
Join Date: Sep 2010
Posts: 2,053
Rep: 145 (Unique: 131)
I'm not sure. On Linux it would be
Code:
wget yourUrlHere > /dev/null 2>&1

which would contact that URL and ignore the HTML that comes back (wget normally downloads the results and saves them to a local file). If you use Cygwin on Windows it ought to be pretty similar.



mott555 is offline  
post #5 of 11 (permalink) Old 11-15-2017, 12:37 PM
Software 'Engineer'
 
jakethesnake438's Avatar
 
Join Date: Oct 2008
Location: Noo Zolond
Posts: 876
Rep: 53 (Unique: 48)
do you need to do anything with the result from the server?

Is this still broken?
Xeon machine
(13 items)
CPU
Xeon E5-2667V2
Motherboard
HP Z620 2012
GPU
Sapphire RX 580 4GB
RAM
32GB 1333MHZ
Hard Drive
2x 256GB SATA SSD
Operating System
Windows 10
Operating System
MacOS Mojave
Monitor
Dell P2418D 1440p
Monitor
Dell U2414H 1080p
Keyboard
Apple Kbd
Mouse
Steelseries QCK
Mouse
Logitech G602
Audio
Senheiser HD449
▲ hide details ▲
jakethesnake438 is offline  
post #6 of 11 (permalink) Old 11-15-2017, 02:11 PM - Thread Starter
New to Overclock.net
 
dseg's Avatar
 
Join Date: Apr 2011
Location: Florida
Posts: 1,461
Rep: 49 (Unique: 46)
Quote:
Originally Posted by jakethesnake438 View Post

do you need to do anything with the result from the server?

No, executing the URL runs a function on the camera. I would just need it to run with zero output.

dseg is offline  
post #7 of 11 (permalink) Old 11-15-2017, 02:15 PM
New to Overclock.net
 
Zer0CoolX's Avatar
 
Join Date: Jun 2013
Location: US
Posts: 786
Rep: 52 (Unique: 43)
Have you spoken to the manufacturer of the camera to see what your options are? Maybe they have a tool to accomplish this already or another way to trigger the function.

Also it may help if we knew the make/model of the cameras and the function you are trying to trigger.

On windows I think its possible to open a url in a browser and at least keep it minimized. You could then create a scheduled task to fire it off at whatever interval you like.

Once triggered, does the function require that the url/browser stay open to complete?

EDIT: to clarify are you on Windows or Linux from which you need to do this?
Zer0CoolX is offline  
post #8 of 11 (permalink) Old 11-22-2017, 11:51 PM
New to Overclock.net
 
Tjj226 Angel's Avatar
 
Join Date: Aug 2012
Location: Seattle, WA
Posts: 7,145
Rep: 506 (Unique: 335)
Could you run the browser in headless mode?
Tjj226 Angel is offline  
post #9 of 11 (permalink) Old 11-23-2017, 04:52 PM
 
 
gonX's Avatar
 
Join Date: May 2006
Location: Odense, Denmark
Posts: 29,522
Rep: 1157 (Unique: 647)
Use cURL:
https://curl.haxx.se/download.html

The command is really easy "curl <address>"

Use Windows' own Task Scheduler to run this periodically.

/e: wget will also work, but cURL is more flexible if you ever need to go outside HTTP/FTP territory.

What does OCN offer as a site?
What are infractions and warnings?
How to make quality posts
#well
(19 items)
CPU
Intel Core i7 4770k
Motherboard
Gigabyte Z87X-UD4H
GPU
Sapphire RX 580
RAM
2x G.Skill F3-2400C10-8GTX
Hard Drive
Samsung 840 EVO
Optical Drive
Generic DVD±RW Burner
Power Supply
Corsair TX850
Cooling
Noctua NH-D14
Case
Fractal Design Core 2500
Operating System
Arch Linux
Monitor
Dell U2711
Monitor
Samsung SyncMaster 2233
Monitor
LG W2453TQ
Keyboard
Ducky DK9008G2, Cherry MX Blue, Overclock.net Edition
Mouse
Logitech G303
Mouse
Xtrfy GP3 HeatoN
Audio
Beyerdynamic DT-770 80 Ohm
Audio
AntLion ModMic v3
Audio
M-Audio Fast Track USB
▲ hide details ▲


gonX is offline  
post #10 of 11 (permalink) Old 11-23-2017, 06:22 PM
New001
 
Join Date: Feb 2016
Posts: 2,668
Hey dseg, made a simple java app that can do what you want. (just need to have java8 installed (1.8 latest))

Basically choose http or https,
enter a URL you want to request (ie. www.google.com),
enter the interval of the requests in minutes,
and click start.
Then you can click the x to minimize to system tray so it doesn't bother you.





It logs the successful requests so you can see its running.

I'll put the source code on github in a sec in case you are worried it is doing something suspicious tongue.gif

link to zipped jar file on google drive:
https://drive.google.com/file/d/1eKaYhsBAhbKiXQp0dWY5keYvNooVts54/view?usp=sharing
spinFX is offline  
Reply

Quick Reply
Message:
Options

Register Now

In order to be able to post messages on the Overclock.net - An Overclocking Community forums, you must first register.
Please enter your desired user name, your email address and other required details in the form below.
User Name:
If you do not want to register, fill this field only and the name will be used as user name for your post.
Password
Please enter a password for your user account. Note that passwords are case-sensitive.
Password:
Confirm Password:
Email Address
Please enter a valid email address for yourself.
Email Address:

Log-in



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Show Printable Version Show Printable Version
Email this Page Email this Page


Forum Jump: 

Posting Rules  
You may post new threads
You may post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off