本文整理汇总了PHP中AFS::parseDomAFS方法的典型用法代码示例。如果您正苦于以下问题:PHP AFS::parseDomAFS方法的具体用法?PHP AFS::parseDomAFS怎么用?PHP AFS::parseDomAFS使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类AFS
的用法示例。
在下文中一共展示了AFS::parseDomAFS方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: Main
function Main()
{
switch ($this->formArray["formAction"]) {
case "edit":
$AFSDetails = new SoapObject(NCCBIZ . "AFSDetails.php", "urn:Object");
if (!($xmlStr = $AFSDetails->getAFS($this->formArray["afsID"]))) {
echo "xml failed";
} else {
if (!($domDoc = domxml_open_mem($xmlStr))) {
$this->tpl->set_block("rptsTemplate", "OwnerListTable", "OwnerListTableBlock");
$this->tpl->set_var("OwnerListTableBlock", "error xmlDoc");
} else {
$afs = new AFS();
$afs->parseDomAFS($domDoc);
foreach ($afs as $key => $value) {
$this->formArray[$key] = $value;
}
//print_r($afs);
//exit();
$administrator = $afs->getAdministratorArray();
foreach ($administrator as $key => $value) {
$this->formArray["lastName"] = $value->getLastName();
$this->formArray["firstName"] = $value->getFirstName();
$this->formArray["middleName"] = $value->getMiddleName();
$this->formArray["number"] = $value->getNumber();
$this->formArray["street"] = $value->getStreet();
$this->formArray["barangay"] = $value->getBarangay();
$this->formArray["district"] = $value->getDistrict();
$this->formArray["municipalityCity"] = $value->getMunicipalityCity();
$this->formArray["province"] = $value->getProvince();
$this->formArray["telephone"] = $value->getTelephone();
}
}
}
break;
case "save":
$AFSEncode = new SoapObject(NCCBIZ . "AFSEncode.php", "urn:Object");
if ($this->formArray["afsID"] != "") {
$afs = new AFS();
$afs->selectAFS($this->formArray["afsID"]);
$afs->setOdID($this->formArray["odID"]);
$afs->setPropertyIndexNumber($this->formArray["propertyIndexNumber"]);
$afs->setCertificateOfTitleNumber($this->formArray["certificateOfTitleNumber"]);
$afs->setCadastralLotNumber($this->formArray["cadastralLotNumber"]);
$afs->setNorth($this->formArray["north"]);
$afs->setSouth($this->formArray["south"]);
$afs->setEast($this->formArray["east"]);
$afs->setWest($this->formArray["west"]);
$afs->setCreatedBy($this->userID);
$afs->setModifiedBy($this->userID);
$person = new Person();
$person->setPersonID($afs->getAdministrator());
$person->setLastName($this->formArray["lastName"]);
$person->setFirstName($this->formArray["firstName"]);
$person->setMiddleName($this->formArray["middleName"]);
$person->setNumber($this->formArray["number"]);
$person->setStreet($this->formArray["street"]);
$person->setBarangay($this->formArray["barangay"]);
$person->setDistrict($this->formArray["district"]);
$person->setMunicipalityCity($this->formArray["municipalityCity"]);
$person->setProvince($this->formArray["province"]);
$person->setTelephone($this->formArray["telephone"]);
$person->setDom();
$afs->setAdministratorArray($person);
$afs->setDomAFS();
$doc = $afs->getDomAFS();
$xmlStr = $doc->dump_mem();
if (!($ret = $AFSEncode->updateAFS($xmlStr))) {
echo "error update";
}
header("location: AFSClose.php" . $this->sess->url("") . $this->sess->add_query(array("odID" => $ret)));
exit;
} else {
$afs = new AFS();
$afs->setOdID($this->formArray["odID"]);
$afs->setPropertyIndexNumber($this->formArray["propertyIndexNumber"]);
$afs->setCertificateOfTitleNumber($this->formArray["certificateOfTitleNumber"]);
$afs->setCadastralLotNumber($this->formArray["cadastralLotNumber"]);
$afs->setNorth($this->formArray["north"]);
$afs->setSouth($this->formArray["south"]);
$afs->setEast($this->formArray["east"]);
$afs->setWest($this->formArray["west"]);
$afs->setCreatedBy($this->userID);
$afs->setModifiedBy($this->userID);
$adminAddress = new Address();
$adminAddress->setNumber($this->formArray["number"]);
$adminAddress->setStreet($this->formArray["street"]);
$adminAddress->setBarangay($this->formArray["barangay"]);
$adminAddress->setDistrict($this->formArray["district"]);
$adminAddress->setMunicipalityCity($this->formArray["municipalityCity"]);
$adminAddress->setProvince($this->formArray["province"]);
$adminAddress->setDomDocument();
$person = new Person();
$person->setLastName($this->formArray["lastName"]);
$person->setFirstName($this->formArray["firstName"]);
$person->setMiddleName($this->formArray["middleName"]);
$person->setTelephone($this->formArray["telephone"]);
$person->setDomDocument();
$afs->setAdministratorArray($person);
$afs->setDomDocument();
//.........这里部分代码省略.........