Mercurial > hg > digilib-old
changeset 238:1ccda61967b2
initial parameter parsing now earlier
author | robcast |
---|---|
date | Tue, 20 Jul 2004 15:29:25 +0200 |
parents | 786c27786281 |
children | 264c55606a4e |
files | client/digitallibrary/digimage.jsp client/digitallibrary/dllib.js |
diffstat | 2 files changed, 16 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/client/digitallibrary/digimage.jsp Tue Jul 20 09:57:24 2004 +0200 +++ b/client/digitallibrary/digimage.jsp Tue Jul 20 15:29:25 2004 +0200 @@ -51,6 +51,7 @@ newParameter('ddpix', '', 9); newParameter('ddpiy', '', 9); document.id='digilib'; + dl_param_init(); </script> </head> <body bgcolor="#666666" onload="dl_init()">
--- a/client/digitallibrary/dllib.js Tue Jul 20 09:57:24 2004 +0200 +++ b/client/digitallibrary/dllib.js Tue Jul 20 15:29:25 2004 +0200 @@ -193,7 +193,21 @@ var elemScaler = null; var picElem = null; + +function dl_param_init() { + // parameter initialisation before onload + + // put the query parameters (sans "?") in the parameters array + parseParameters(location.search.slice(1)); + // treat special parameters + dlMarks = parseMarks(); + dlArea = parseArea(); + dlFlags = parseFlags(); +} + + function dl_init() { + // initalisation on load elemScaler = getElement("scaler", true); picElem = getElement("pic", true); if (picElem == null && elemScaler) { @@ -422,7 +436,7 @@ } -function getRef(select) { +function getRef() { // returns a reference to the current digilib set if (! baseUrl) { var baseUrl = location.protocol + "//" + location.host + location.pathname;