hisoka Posted July 28, 2015 Share Posted July 28, 2015 (edited) I tried to access this site from my windows cmd command: http://curl.haxx.se using curl curl http://curl.haxx.se When I run curl http://curl.haxx.se , I got a lot of html attributes and tags , in my cmd , of the curl.haxx.se website but I could not open the website in my browser . I do not want to get html tags when I run the above command but I want to get the page of the website in my browser so how I can do it ? Edited July 28, 2015 by hisoka Link to comment Share on other sites More sharing options...
justsomeguy Posted July 28, 2015 Share Posted July 28, 2015 If you want to open the site in your browser then use a browser instead of command line cURL.edit: moved to General, this is not a PHP question 1 Link to comment Share on other sites More sharing options...
hisoka Posted July 28, 2015 Author Share Posted July 28, 2015 ok but I have some questions : 1) is it possible to open the page of a website using curl instead of clicking on my browser then writing the url of the site i want to access ? and if yes how ? 2) what I got in my cmd is it the home page of the website or what is it ? Link to comment Share on other sites More sharing options...
Ingolme Posted July 28, 2015 Share Posted July 28, 2015 cURL can get the HTTP headers and HTML code that the website provides, but it won't show you the actual page, because that's what a browser is for. 1 Link to comment Share on other sites More sharing options...
justsomeguy Posted July 28, 2015 Share Posted July 28, 2015 1) is it possible to open the page of a website using curl instead of clicking on my browser then writing the url of the site i want to access ? and if yes how ?Do you even understand what cURL is for? It is a command-line tool to send HTTP requests and return the contents. That means it downloads whatever the server returns, if that's HTML code or an image or whatever. That's the point of it. If you want to look at web pages in your browser then cURL is not the tool to use.2) what I got in my cmd is it the home page of the website or what is it ?It's whatever the server responded with for the URL that you requested. 1 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now