20,268 downloads - November 27, 2013
We are switched to admin only, please email markdilley@gmail if you would like to edit.

Add The Link

From Universal Edit Button

Jump to: navigation, search

< Community Portal

If you host a website, you may want to add the universal edit button link to every page that can be edited. This page explains how.

This is the link tag as it appears on the the c2.com WelcomeVisitors page:

<link rel="alternate" 
  type="application/wiki" 
  title="Edit this page!" 
  href="wiki?edit=WelcomeVisitors"/>

Since application/wiki isn't a registered MIME type yet, some wikis (MediaWiki, Socialtext) are implementing with application/x-wiki for now, pending registration of application/wiki. The link tag looks like this:

<link rel="alternate" 
  type="application/x-wiki" 
  title="Edit this page!" 
  href="wiki?edit=WelcomeVisitors"/>

Note that the title attribute appears in a popup when you hover over the button, so if your site requires logging in to edit, then if the user isn't logged in you could have something like title="Log in to edit this page!". The fragment should not appear in the read only pages. The reference after href is a relative reference that should bring to the edit page. The edit page can be a usual Wiki edit form but can also be any other page that accepts at least some input from the user - the standard is flexible enough not to put any restrictions on this. As the reference can potentially contain the header of the user page, it is important to check it it does not contain non-URL characters like < and > or maybe better use numeric id.

Both methods work with the current version of the Firefox plugin.

There are also some other suggestions about what the rel and type values should be. Feel free to add your input about that or anything else here.

These link tags announce the availability of an alternate representation, type application/wiki or application/x-wiki, which is the edit page for this page.

Implementing it for different web applications

Producing these tag requires some logic which will differ for each wiki or weblog or other web application: the href part of this tag should specify the edit page that corresponds with the page being viewed. Each website will approach this substitution differently.

Personal tools