mirror of
https://github.com/processwire/processwire.git
synced 2025-08-12 09:44:38 +02:00
Update to processwire/processwire-issues#60 for multi-instance support with multi-language page names
This commit is contained in:
@@ -147,10 +147,21 @@ class ProcessWire extends Wire {
|
|||||||
$this->shutdown = $this->wire(new WireShutdown());
|
$this->shutdown = $this->wire(new WireShutdown());
|
||||||
$this->config($config);
|
$this->config($config);
|
||||||
$this->load($config);
|
$this->load($config);
|
||||||
|
|
||||||
|
if($this->getNumInstances() > 1) {
|
||||||
|
// this instance is not handling the request and needs a mock $page API var and pageview
|
||||||
|
/** @var ProcessPageView $view */
|
||||||
|
$view = $this->wire('modules')->get('ProcessPageView');
|
||||||
|
$view->execute(false);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public function __toString() {
|
public function __toString() {
|
||||||
return $this->className() . " " . self::versionMajor . "." . self::versionMinor . "." . self::versionRevision;
|
$str = $this->className() . " ";
|
||||||
|
$str .= self::versionMajor . "." . self::versionMinor . "." . self::versionRevision;
|
||||||
|
if(self::versionSuffix) $str .= " " . self::versionSuffix;
|
||||||
|
if($this->getNumInstances() > 1) $str .= " #$this->instanceID";
|
||||||
|
return $str;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Reference in New Issue
Block a user