Closed
Bug 409508
Opened 17 years ago
Closed 15 years ago
Ping attribute enhancement using meta tag to indicate ping for all external destination urls to reduce ping attribute page bloat.
Categories
(Core :: DOM: Core & HTML, enhancement)
Core
DOM: Core & HTML
Tracking
()
RESOLVED
INVALID
People
(Reporter: rescator, Unassigned)
Details
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9b2) Gecko/2007121120 Firefox/3.0b2
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9b2) Gecko/2007121120 Firefox/3.0b2
<META name="Ping-prefix" content="/trackout/">
If the browser see this meta tag it will behave as if ping attribute was applied to all externally leading hrefs with the prefix added to the start.
In the example above this would be how the browser should treat it as if it was:
This tracking script has a url rewrite to it so it looks nice in log parsers etc.
The behavior would be similar to doing this:
<a href="http://example.com" ping="/trackout/http://example.com">Example.com</a>
<a href="links/">Links</a>
<a href="http://mozilla.org" ping="/trackout/http://mozilla.org">Mozilla.org</a>
if the meta tag is <META name="Ping-prefix" content="http://yoursite.com/trackout/">
the behavior would be similar to this:
<a href="http://example.com" ping="http://yoursite.com/trackout/http://example.com">Example.com</a>
<a href="links/">Links</a>
<a href="http://mozilla.org" ping="http://yoursite.com/trackout/http://mozilla.org">Mozilla.org</a>
Here is an alternative tracking script (no url rewrite on this one).
<META name="Ping-prefix" content="/trackout?url=">
This results in a behavior similar to doing:
<a href="http://example.com" ping="/trackout?url=http://example.com">Example.com</a>
<a href="links/">Links</a>
<a href="http://mozilla.org" ping="/trackout?url=http://mozilla.org">Mozilla.org</a>
This new meta tag would allow even more rapid adoption as web developers would not need to add a ping attribute to hundreds of pages with maybe dozens of links on each page, and it would be very easy to add such a meta tag to various template scripts/frameworks with just a line of code.
To the web developer AND the end user it would also mean no size increase, whereas using the ping attribute would potentially double the number of bytes per href..
Alternatively the base tag could be used instead of a meta tag.
In which case the implementation could be:
<base ping="/trackout/">
and
<base ping="/trackout?url=">
and so on...
This may actually be more fitting. (considering <base target=""> attribute behaves in a similar way to my idea)
Firefox 3 team has the chance to test this out and see which is more popular.
ping attributes in individual a href tags or a single ping attribute in the base tag.
With a possible saving of bytes due to a single ping attribute being used there would be no need to use javascript hacks nor redirect urls, nor ping attributes per url. How can one go wrong?
I am already testing ping attributes for urls on my site,
but damn adding that ping to all those pages is a pain.
a <base ping=""> to set a default prefix and have the url appended to it
would allow adding url ping by just a single line in the sites template.
PS! individual ping attributes would override the global one obviously, just like a target attribute would.
Oh, and could someone on the HTML5 list poke some of the guys over there and see if a ping attribute for the base tag in a similar vein could be considered?
Reproducible: Always
| Reporter | ||
Comment 1•17 years ago
|
||
Ok sorry about that. total brainfart. Obviously i ment <body> no clue where i got <base> from. Hope it still made sense though. Eh...
Updated•15 years ago
|
Component: General → Networking
OS: Windows XP → All
Product: Firefox → Core
QA Contact: general → networking
Hardware: x86 → All
Version: unspecified → Trunk
Updated•15 years ago
|
Component: Networking → DOM: Core & HTML
QA Contact: networking → general
Comment 2•15 years ago
|
||
Please propose this to the WHATWG <whatwg@whatwg.org> for specification.
Status: UNCONFIRMED → RESOLVED
Closed: 15 years ago
Resolution: --- → INVALID
Comment 3•15 years ago
|
||
(In reply to comment #2)
> Please propose this to the WHATWG <whatwg@whatwg.org> for specification.
For the record: <http://lists.whatwg.org/pipermail/whatwg-whatwg.org/2010-April/026049.html>. Thanks.
You need to log in
before you can comment on or make changes to this bug.
Description
•