Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
valid Url hostname
06-10-2012, 01:10 AM, (This post was last modified: 06-10-2012, 01:23 AM by RobertShiplett.)
#1
valid Url hostname
In converting a plain HTML-only home page to a Curl page I made a discovery (to me, at least.)

In Canada, from my Cdn IP, the only path to google.com instead of google.ca is to concat a query.

Browsers accept the HTML anchor href of https://www.google.com?q=
but they silently convert it to https://www.google.com/?q=

But Curl rejects the former - even when using {url-encode-string maybe-has-query? = true,

The hostname will prove invalid. Creating a URL and then using set-query is of no avail.

But this will work : https://www.google.com/?q=

and with one forward slash after the top-level we have a valid hostname.

And yet, in Curl we do get away with

{link href={url "http://www.bbc.co.uk"} || ...

for modest inconsistency in parsing 'What Is A Valid Hostname?' ... or not?



Robert Shiplett, Curlr
Fredericton NB

Canada

Forum Jump:


Users browsing this thread:
1 Guest(s)

MyBB SQL Error

MyBB has experienced an internal SQL error and cannot continue.

SQL Error:
1017 - Can't find file: 'mybb_threadviews' (errno: 2)
Query:
INSERT INTO mybb_threadviews (tid) VALUES('524')