projects
/
pazpar2-moved-to-github.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (from parent 1:
f9130dd
)
Register onclick handlers to pager anchors as anonymous functions.
author
Anders S. Mortensen
<sondberg@indexdata.dk>
Thu, 11 Jan 2007 11:14:16 +0000
(11:14 +0000)
committer
Anders S. Mortensen
<sondberg@indexdata.dk>
Thu, 11 Jan 2007 11:14:16 +0000
(11:14 +0000)
www/demo/search.js
patch
|
blob
|
history
diff --git
a/www/demo/search.js
b/www/demo/search.js
index
9ef3be4
..
fc1a0bf
100644
(file)
--- a/
www/demo/search.js
+++ b/
www/demo/search.js
@@
-1,4
+1,4
@@
-/* $Id: search.js,v 1.18 2007-01-11 10:18:38 sondberg Exp $
+/* $Id: search.js,v 1.19 2007-01-11 11:14:16 sondberg Exp $
* ---------------------------------------------------
* Javascript container
*/
* ---------------------------------------------------
* Javascript container
*/
@@
-170,7
+170,10
@@
function make_pager (hits, offset, max) {
}
page_elem.setAttribute('href', '#');
}
page_elem.setAttribute('href', '#');
- page_elem.setAttribute('onclick', 'update_offset(' + off + ')');
+ page_elem.setAttribute('off', off);
+ page_elem.onclick = function () {
+ update_offset(this.getAttribute('off'));
+ };
div_elem.appendChild(page_elem);
div_elem.appendChild(newline_node);
div_elem.appendChild(page_elem);
div_elem.appendChild(newline_node);