本文整理汇总了PHP中XML::XmlArrayResponse方法的典型用法代码示例。如果您正苦于以下问题:PHP XML::XmlArrayResponse方法的具体用法?PHP XML::XmlArrayResponse怎么用?PHP XML::XmlArrayResponse使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类XML
的用法示例。
在下文中一共展示了XML::XmlArrayResponse方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: UserList
private function UserList()
{
$DB = new DataBase();
$EnterpriseAlias = filter_input(INPUT_POST, "EnterpriseAlias");
$SelectUsers = "SELECT * FROM Users WHERE UserName != 'admin'";
$ResultSelect = $DB->ConsultaSelect($EnterpriseAlias, $SelectUsers);
if ($ResultSelect['Estado'] != 1) {
XML::XmlResponse("Error", 0, "<p><b>Error</b> al consultar los usuarios</p><br>Detalles:<br><br>" . $ResultSelect['Estado']);
return 0;
}
$Users = $ResultSelect['ArrayDatos'];
XML::XmlArrayResponse("UserList", "User", $Users);
}
示例2: GetSystemEnterprises
private function GetSystemEnterprises()
{
$DB = new DataBase();
$IdEnterprise = filter_input(INPUT_POST, "IdEnterprise");
$EnterpriseAlias = filter_input(INPUT_POST, "EnterpriseAlias");
if ($IdEnterprise > 0) {
$Condition = " WHERE en.IdEnterprise = {$IdEnterprise} ";
}
$QueryEnterprises = "SELECT en.IdEnterprise, en.EnterpriseName, en.Alias, en.RFC, en.DischargeDate, en.UsedMemory, en.AvailableMemory, en.TotalMemory, vol.IdVolume, vol.VolumeName FROM Enterprises en LEFT JOIN Volumes vol ON en.IdVolume = vol.IdVolume {$Condition}";
$ResultQuery = $DB->ConsultaSelect($EnterpriseAlias, $QueryEnterprises);
if ($ResultQuery['Estado'] != 1) {
XML::XmlResponse("Error", 0, "<p><b>Error</b> al obtener el listado de empresas</p><br>Detalles:<br><br>" . $ResultQuery['Estado']);
return 0;
}
XML::XmlArrayResponse("Enterprises", "Enterprise", $ResultQuery['ArrayDatos']);
}
示例3: GetActiveEmails
private function GetActiveEmails()
{
$DB = new DataBase();
$EnterpriseAlias = filter_input(INPUT_POST, "EnterpriseAlias");
$IdUser = filter_input(INPUT_POST, "IdUser");
$UserName = filter_input(INPUT_POST, "UserName");
$ActiveEmailsQuery = "SELECT IdEmail, User FROM EmailEngine";
$ActiveEmailResult = $DB->ConsultaSelect($EnterpriseAlias, $ActiveEmailsQuery);
if ($ActiveEmailResult['Estado'] != 1) {
XML::XmlResponse("Error", 0, "<p><b>Error</b> al consultar los correos activos</p><br>Detalles:<br><br>" . $ActiveEmailResult['Estado']);
return 0;
}
XML::XmlArrayResponse("ActiveEmails", "Email", $ActiveEmailResult['ArrayDatos']);
}