Returns HTML instead of plain-text
See original GitHub issueOn MacOS curl cht.sh
returns normal HTML page for me instead of a plain text version of the cheatsheet, however curl -q cht.sh
works fine.
Issue Analytics
- State:
- Created 5 years ago
- Reactions:2
- Comments:10 (5 by maintainers)
Top Results From Across the Web
API GET Request Returns HTML/Text instead of JSON
So far, I've got it connected to the server hosting my API, but I'm unable to get it to return JSON. Instead it...
Read more >Change the message format to HTML, Rich Text Format, or ...
Change the format of a reply or a forwarded message You can change a plain text message to HTML. In the message, click...
Read more >3 ways to convert HTML text to plain text - DEV Community
3 ways to convert HTML text to plain text · 1) Using .replace(/<[^>]*>/g, '') · 2) Create a temporary DOM element and retrieve...
Read more >Why would a web page be displayed as plain text instead of ...
This question have two scenarios as asked. First: the text is shown because there might be some closing of tag issue, which causes...
Read more >How to send an HTML message in reply to a plain text email
What's more, instead of your carefully designed HTML email signature, the recipient will just see its simple plain text version.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Yes, the problem in your case is that
curl
uses this User-Agent string (so it is seen as Mozilla from the web server side). I don’t know why there is such a problem in Mac OS X, but maybe is is configured by default in~/.curlrc
. Could you please check it? Probably it is the case because it works with-q
. So please check your~/.curlrc
and remove the user agent line from there. If you need it for some reasons, we can override user agent in thecht.sh
script explicitly (but in that case you couldn’t query the service withcurl
alone).I would remove the
user-agent
string from your~/.curlrc
if you do not really need it.Could you please check what user-agent uses your curl?