Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I would like to find a way to open a URL without using a web browser (which makes my computer system run very slow).

Is there an easy way to achieve this on a command prompt using SSH to access another network?

share|improve this question
    
I remember reading an essay once where Richard Stallman (the founder of the FSF and the creater of GNU) described how he accesed websites when he was forced to use computers without a free software browser. He would wget the html of the website and just read the source. –  crasic Aug 11 '11 at 5:20
add comment

4 Answers 4

up vote 2 down vote accepted

ok...try this

from your local computer create an ssh connection forwarding local port 8080 to their web server

ssh  -L 8080:destcomputer.domain.com:80 destcomputer.domain.com

then you can run any browser you like on you local computer and connect to

localhost:8080

this should connect you to the webserver destcomputer.domain.com

share|improve this answer
    
It looks promising. I tried to follow the direction here: help.ece.ubc.ca/How_To_Tunnel_Connections_Through_SSH But it's still not very clear as I am having trouble tunneling the connection to my localhost. Any comments? –  stanigator May 10 '10 at 0:45
    
Nvm; set up a SOCKS proxy and solved my problems. –  stanigator May 10 '10 at 0:56
    
glad it worked! –  bryan May 10 '10 at 1:26
add comment

You can always use elinks in your SSH session. It's a great in-session SSH browser.

If you're just looking to download files, you can just wget them (wget http://test.com/file.html).

EDIT

Let's say you need to download http://test.com/file.pdf, but you require some sort of login first (as it sounded in your comment):

You'd login through SSH:

$ localmachine ~> ssh user@machine
user@machine's password: <password>
$ remotemachine ~> (elinks/links/lynx) http://test.com/login

You'd navigate around the site and log in, and when you select the URL of the file you want to download, links/elinks should ask you where you want to save the file. You can save that file to the machine you're SSH'd into, and scp it to your machine. If you need any more information, let me know :)

METHOD 2

If you have direct access to the file (say http://test.com/file.pdf) you can just run curl -O http://test.com/file.pdf or wget http://test.com/file.pdf and it will be saved to the current directory (every single machine I've ever SSH'd into has either wget or curl).

share|improve this answer
    
What if it's a pdf that is only available to certain subscribers, which is the network that I'm accessing through ssh? –  stanigator May 10 '10 at 0:09
    
@stanigator: Answer updated to reflect your comment. –  squircle May 10 '10 at 0:19
    
Hmm...the machine that I'm accessing doesn't have links or elinks. I guess I may not be able to achieve my purpose this way. –  stanigator May 10 '10 at 0:23
    
@stanigator: to get the file you're looking for, do you have to log in, or do you have direct access to it? –  squircle May 10 '10 at 0:26
    
@stanigator: Does it have lynx? It's very common. See my answer. –  Dennis Williamson May 10 '10 at 0:26
show 4 more comments

Other text-mode browsers include Lynx, Links and Links 2 (with graphics with or without the X Window System, but not over ssh).

share|improve this answer
add comment

try

lynx 

its an older browser

share|improve this answer
    
Nope. It doesn't have it. –  stanigator May 10 '10 at 0:29
    
Not older, just better :D –  crasic Aug 11 '11 at 5:18
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.