Linking to New Zealand Legislation
Saturday, January 12th, 2008The web page Public Access to Legislation - Creating links to the New Zealand Legislation website gives information on how to link to New Zealand Legislation.
The legislative documents are identified by:
- the information type (Act, Regulation, Bill, SOP)
- the legislation type or category (public, local, members, government, imperial etc)
- the year
- the number, padded with initial zeros to 4 digits. For Bills, the number will also include the Bar number and split letter (if applicable).
And a legislative document can currently be linked to in the following ways:
- To the documents table of contents.
- To the document as one HTML page
- To specific provisions within the document
- To specific HTML versions
- To the document to download as a PDF
In the same way that I want to link to photo sharing sites from within my web application there will be occasions when I want to link to legislation, standards and regulation documents.
For example in the context of a web based building project it could be useful to link to the Building Act 2004 Table of Content which gives an overview of the individual sections of the Building Act.
This is useful as a general reference but there will be occasions where I want to show a provision in a specific context relevant to the project. For example a building project needs to be issued with a building consent which can lapse after a period of time.
When showing the status of a project which has not yet started building it would be useful to indicate if its building consent is about to expire and if it is then link to the relevant provision to clarify the situation.
Currently there are two simple ways of linking to the specific provision, open it in the same page or open it in a new page.
- Lapse of Building Consent - Opened in the same page
- Lapse of Building Consent - Opened in a new page
Both of these approaches are a bit rough for todays modern Ajax-based web applications which would ideally take a smoother approach. I.e. take just the relevant content and slide it into the page at the required location, in this case inserting just the following:
“A building consent lapses and is of no effect if the building work to which it relates does not commence within—
(a) 12 months after the date of issue of the building consent; or
(b) any further period that the building consent authority may allow.”
This Ajax insertion can be achieved by first using a customized HTML reader which extracts the relevant content from the original provisions page.
The simpler display rendered by the customized HTML reader would also be more appropriate for a mobile phone based web application.
Note that in January 2008, as part of the PAL Project, a new site for accessing New Zealand legislation will be available.
The PAL Project stores the legislation documents as XML fragments that are combined for publication as HTML and PDF. It is likely that the documents will also be available as XML.
If the XML document is available then it should be simpler to access the content of the specific provisions when using the customized HTML reader discussed above.
A further simplification would be to provide a REST based web service for accessing the provisions. This would allow the content of the provision “Lapse of Building Consent” to be accessed via a URI similar to the following http://www.legislation.govt.nz/act/public/2004/se/072se52.xml.