本文整理汇总了PHP中Web::was方法的典型用法代码示例。如果您正苦于以下问题:PHP Web::was方法的具体用法?PHP Web::was怎么用?PHP Web::was使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Web
的用法示例。
在下文中一共展示了Web::was方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: updateUpdate
function updateUpdate($param)
{
// This is sort of a hack... The ssl configuration of the ipaddress has to be reflected properly in the domain too. So the web objects are initialized, the ssl parameters are changed on the fly and synced again. All this is because, apache will refuse to start if the ssl files are missing, which is fucking terrible. (later)... Apache is actually ok. The whole damn problem is with iis. Be careful about the createExtraVariables. As for now, the web object doesn't create objects from the parent domain object, and thus web object will work indepnednely without the help of the domain parent object. Thus the parent of the web can anything. But if in the at any time in the future the web object starts needing any parameter from the domain, then this will have to be rewritten. Then the domain objects have to initialized first, then the web objects are initialized, and the web can be created only UNDER the domain, and not directly under this object.
global $gbl, $sgbl, $login, $ghtml;
$driverapp = $gbl->getSyncClass($this->__masterserver, $this->__readserver, 'web');
$olddom = $this->domain;
$newdom = $param['domain'];
if (!csb($newdom, "lxdummy") && !is_disabled($newdom)) {
$ip = gethostbyname($newdom);
if ($ip != $this->getParentO()->ipaddr) {
throw new lxexception("this_domain_does_not_resolve_to_this_ip", 'domain', $newdom);
}
}
$this->domain = $param['domain'];
$this->ipaddr = $this->getParentO()->ipaddr;
$this->setUpdateSubaction();
$this->write();
if ($olddom) {
$odo = new Web(null, $this->syncserver, $olddom);
$odo->get();
// Need to get the client here itself so that it won't run into problems later. You don't need the client anymore...
//$odo->getParentO()->getParentO();
if ($odo->dbaction !== 'add') {
$odo->setUpdateSubaction('fixipdomain');
$odo->was();
}
}
if ($olddom === $newdom) {
return;
}
if (is_disabled($newdom)) {
return;
}
$ndo = new Web(null, $this->syncserver, $newdom);
$ndo->get();
//$ndo->getParentO()->getParentO(); //you don't need client anymore..
$ndo->setUpdateSubaction('fixipdomain');
$ndo->was();
}