Opened 7 years ago

Closed 7 years ago

#14710 closed defect (wontfix)

Protocol-relative URLs shouldn't generally be treated as cross-domain

Reported by: Thomas Bachem Owned by: Rawld Gill
Priority: undecided Milestone: tbd
Component: Loader Version: 1.7.1
Keywords: Cc:
Blocked By: Blocking:

Description

Related to #8546.

It's unnecessary to enforce the xdomain loader for all protocol-relative URLs (e.g. //example.com). Protocol-relative URLs are a bless for sites using https, and used more and more often as all browsers support them nowadays. There should be a more intelligent cross-domain check here that compares protocols.

From the current source:

if(/^\/\//.test(url)){
   // for v1.6- backcompat, url starting with // indicates xdomain
   return true;
}

If 1.6-compatibility is wanted, at least a configuration setting should be added.

Change History (1)

comment:1 Changed 7 years ago by Rawld Gill

Resolution: wontfix
Status: newclosed

This is the logic of 1.6. Then entire idea of a xdomain loader is deprecated. It is much better to just use the AMD loader and not worry about these kind of problems.

Note: See TracTickets for help on using tickets.