What do you want to do? We are using this kind of callback with this mediawiki extension [1] Here is an example of output [2]
[1] https://git.wikimedia.org/blob/mediawiki%2Fextensions%2FCargo/5d58912d6969cadece74c89b7ac66450f692e6f3/libs%2Fext.cargo.exhibit.js [2] http://beta.programaseducativosaragon.es/mw126/index.php?title=MultipleViews Saludos, -- luismiguel (@lmorillas) 2015-10-27 11:12 GMT+01:00 Tully Hansen <[email protected]>: > Necroposting again, but… does anyone have a worked (or even working) example > for filtering views from URL parameters with Exhibit 3? I've tried > variations on the above to no avail (with current /HEAD/ version). My > experience with Javascript is effectively nil, so I'm in over my head… > example site at http://tullyhansen.github.io/botDB/nobel3ed.html, here's the > relevant code I'm attempting to use, which at least seems to be called > correctly by <body onload="onLoad()"> (as I see messages in console): > > <script type="text/javascript"> > onLoad = function() { > console.log("onLoad got called correctly!"); > var s, f, fDone; > fDone = function() { > window.exhibit = Exhibit.create(); > window.exhibit.configureFromDOM(); > }; > console.log("Made it to try block!"); > try { > s = Exhibit.getAttribute(document.body, "ondataload"); > if (s !== null && typeof s === "string" && s.length > 0) { > f = eval(s); > if (typeof f === "function") { > fDone = f; > } > } > } catch (e) { > Exhibit.Debug.warn(Exhibit._("%general.error.dataloadExecution")); > Exhibit.Debug.warn(e); > }; > console.log("Made it through try block!"); > Exhibit.jQuery(document.body).one("dataload.exhibit", fDone); > window.database = Exhibit.Database.create(); > window.database.loadLinks(); > console.log("Made it to the end of onLoad!"); > }; > </script> > > I'm getting an error of: TypeError: null is not an object (evaluating > 'Exhibit.Importer._registry.get') at getImporter > exhibit-scripted-bundle.js:5444. I also realise there's nothing in the above > to actually use the parameters. > > -- > You received this message because you are subscribed to the Google Groups > "SIMILE Widgets" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To post to this group, send email to [email protected]. > Visit this group at http://groups.google.com/group/simile-widgets. > For more options, visit https://groups.google.com/d/optout. -- You received this message because you are subscribed to the Google Groups "SIMILE Widgets" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/simile-widgets. For more options, visit https://groups.google.com/d/optout.
