* unify handling
This commit is contained in:
Sarjuuk
2022-03-12 23:59:06 +01:00
parent 4b32811424
commit 3cb02f2204
49 changed files with 179 additions and 159 deletions

View File

@@ -16,7 +16,7 @@ class ObjectPage extends GenericPage
protected $path = [0, 5];
protected $tabId = 0;
protected $mode = CACHE_TYPE_PAGE;
protected $js = ['swfobject.js'];
protected $js = [[JS_FILE, 'swfobject.js']];
protected $_get = ['domain' => ['filter' => FILTER_CALLBACK, 'options' => 'GenericPage::checkDomain']];
@@ -51,7 +51,7 @@ class ObjectPage extends GenericPage
protected function generateContent()
{
$this->addJS('?data=zones&locale='.User::$localeId.'&t='.$_SESSION['dataKey']);
$this->addScript([JS_FILE, '?data=zones&locale='.User::$localeId.'&t='.$_SESSION['dataKey']]);
/***********/
/* Infobox */
@@ -215,8 +215,10 @@ class ObjectPage extends GenericPage
// pageText
if ($this->pageText = Game::getPageText($next = $this->subject->getField('pageTextId')))
{
$this->addCSS(['path' => 'Book.css']);
$this->addJS('Book.js');
$this->addScript(
[JS_FILE, 'Book.js'],
[CSS_FILE, 'Book.css']
);
}
// get spawns and path