Affiliate Webmaster Forum  

Go Back   Affiliate Webmaster Forum > All Aboard > External RSS Feeds


External RSS Feeds Particular RSS feeds that we like including our regular Twitter tweets.

» GoogleAds

» Need Traffic? Ride An Elephant!
Reply
 
LinkBack Thread Tools
  #1 (permalink)  
Old 01-19-2010, 03:56 PM
GTP Dave's Avatar
Consultations $.05
Administrator
Points: 2,433, Level: 31 Points: 2,433, Level: 31 Points: 2,433, Level: 31
Activity: 20% Activity: 20% Activity: 20%
 
Join Date: May 2008
Location: Switzerland
Posts: 588
Default Default Prefix Declaration

Default Prefix Declaration

Henry S. Thompson
18 Nov 2009
Table of Contents
1. Disclaimer

The ideas behind the proposal presented here are neitherparticularly new nor particularly mine. I've made the effort towrite this down so anyone wishing to refer to ideas in this spacecan say "Something along the lines of [this posting]" rather than"Something, you know, like, uhm, what we talked about, prefixbinding, media-type-based defaulting, that stuff".


2. Introduction

Criticism of XMLnamespaces as an appropriate mechanism for enabling distributedextensibility for the Web typically targets two issues:
  1. Syntactic complexity
  2. API complexity
Of these, the first is arguably the more significant, becausethe number of authors exceeds the number of developers by a largemargin. Accordingly, this proposal attempts to address the firstproblem, by providing a defaulting mechanism for namespace prefixbindings which covers the 99% case.


3. The proposal

BindingDefine a trivial XML language which provides a means toassociate prefixes with namespace names (URIs);Invoking from HTMLDefine a link relation dpd for use in the (X)HTMLheader;Invokingfrom XMLDefine a processing instruction xml-dpd and/or anattribute xml:dpd for use at the top of XMLdocuments;Defaulting by Media TypeImplement a registry which maps from media types to a publisheddpd file;SemanticsDefine a precedence, which operates on a per-prefix basis,namely xmlns: >> explicit invocation >> applicationbuilt-in default >> media-type-based default, and a semanticsin terms of namespaceinformation items or appropriate data-model equivalent on thedocument element.
4. Whyprefixes?

XML namespaces provide two essentially distinct mechanisms for'owning' names, that is, preventing what would otherwise be a namecollision by associating names in some way with some additionaldistinguishing characteristic:
  1. By prefixing the name, and binding the prefix to a particularURI;
  2. By declaring that within a particular subtree,unprefixed names are associated with a particular URI.
In XML namespaces as they stand today, the association with aURI is done via a namespace declarationwhich takes the form of an attribute, and whose impact is scoped tothe subtree rooted at the owner element of that attribute.

Liam Quin has proposed an additional, out-of-band and defaultable,approach to the association for unprefixed names, usingpatterns to identify the subtrees where particular URIs apply. I'veborrowed some of his ideas about how to connect documents to prefixbinding definitions.

The approach presented here is similar-but-different, in that its primarygoal is to enable out-of-band and defaultable associations of namespacesto names with prefixes, with whole-document scope. Theadvantages of focussing on prefixed names in this way are:
  • Ad-hoc extensibility mechanisms typically use prefixes.The HTML5 specification already has at least two of these:aria- and data-;
  • Prefixed names are more robust in the face of arbitrarycut-and-paste operations;
  • Authors are used to them: For example XSLT stylesheets and W3CXML Schema documents almost always use explicit prefixesextensively;
  • Prefix binding information can be very simple: just a set ofpairs of prefix and URI.
Provision is also made for optionally specifying a binding for the default namespace at the document element, primarily for the media type registry case, where it makes sense to associate a primary namespace with a media type.


5. Example

If this proposal were adopted, and a dpd document for use in HTML 4.01 or XHTML1:

was registered against the text/html media type, the following would result in a DOM with html and body elements in the XHTML namespace and an input element in the XForms namespace:
...

More...


Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Default Prefix Declaration GTP Dave External RSS Feeds 0 11-20-2009 03:02 PM
Default Prefix Declaration GTP Dave External RSS Feeds 0 11-18-2009 06:53 PM

» Your Ad Could Be Here

» Sponsors


DomainCompound.com
Domain Compost
Cheapest Web Software
Buy Website Traffic

Webmaster Submit Link

Multiply Profits AND Automate Your Business

AWeber's email marketing software makes it easy.

Opt-In Based Email Marketing

Powered by vBadvanced CMPS v3.2.1

All times are GMT. The time now is 04:41 PM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.3.0
AffiliateWebmasterForum.com