1 // Defines common variables for testing
2 // TODO - don't use global namespace
4 // $$$ TODO make test host auto-magic
6 testHost: 'http://www-testflip.archive.org'
7 // testHost: 'http://www-mang.archive.org'
10 // Set up dummy BookReader class for JSLocate
11 function BookReader() {
14 BookReader.prototype.init = function() {
19 // Returns locator URL for the given id
20 function jsLocateURL(identifier, book) {
21 var bookURL = common.testHost + '/bookreader/BookReaderJSLocate.php?id=' + identifier;
23 bookURL += '&book=' + book;
28 function previewURL(identifier, bookId, page) {
29 return common.testHost + '/download/' + identifier + '/page/' + bookId + '_' + page + '.jpg';