bug-librejs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug-librejs] treatment of schema of URL in Web label matching


From: Peter Olson
Subject: [Bug-librejs] treatment of schema of URL in Web label matching
Date: Mon, 22 Apr 2013 15:23:36 -0400
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130308 Thunderbird/17.0.4

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

I was having difficulty with a Web label I created recently.  I have
scripts that can be referenced either as http://example.com/path or
https://example.com/path, so I entered one row with the URL
//example.com/path thinking that it would match either schema, but it
just mysteriously fails.  I had patterned this on a Web label for one
of my other sites where the label row starts //example.com/path and it
works.  However, for that site, I think all the src attributes for the
JS are of the form //example.com/path, and I am led to suspect that
for complete coverage I would need to have the same URL in three forms
in the Web label, one with just //, one with http://, and one with
https://

Does this match your expectations?  I would propose that LibreJS be
changed internally to match a URL specified in the label as beginning
with // to all three of these forms, or perhaps even to ignore the
schema part of the URL entirely in that case.

Thinking a little more about this, are these equivalent?

 http://example.com/abc/def/ghi/../js/xyz.js
 http://example.com/abc/def/js/xyz.js

I am pretty sure I have seen this kind of thing done in Drupal, where
an extension knows where it lives in the Drupal tree and needs to
reach up to some common Javascript provided by Drupal.

What about absolute vs. relative reference in general?  Is there a
difference between these

 http://example.com/abc/def/js/xyz.js
 def/js/xyz.js

when referred by http://example.com/abc/index.html

Peter Olson
FSF Senior Systems Administrator
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with undefined - http://www.enigmail.net/

iEYEARECAAYFAlF1jjgACgkQUndYrQZsfBqEoQCgj4kabIDbCEh7X7WRwhnb54Dj
MpwAn0tMytINOP07cq3dumbv19BexRQK
=/mBC
-----END PGP SIGNATURE-----



reply via email to

[Prev in Thread] Current Thread [Next in Thread]