当前位置: 首页>>代码示例>>PHP>>正文


PHP global_common::convertToXML方法代码示例

本文整理汇总了PHP中global_common::convertToXML方法的典型用法代码示例。如果您正苦于以下问题:PHP global_common::convertToXML方法的具体用法?PHP global_common::convertToXML怎么用?PHP global_common::convertToXML使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在global_common的用法示例。


在下文中一共展示了global_common::convertToXML方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: array

                $linkArticle = global_common::getHostName() . '/article_detail.php?aid=' . $comment[global_mapping::ArticleID];
                $commentDate = global_common::formatDateTimeVN($comment[global_mapping::CreatedDate]);
                $commentContent = $comment[global_mapping::Content];
                $linkPolicy = global_common::getHostName() . '/' . global_common::PAGE_TERM_KM;
                $arrMailContent = global_common::formatMailContent(global_common::TEAMPLATE_BAD_COMMENT, null, array(global_common::formatOutputText($fullName), $linkArticle, $commentDate, $commentContent, $linkPolicy));
                $emailSubject = $arrMailContent[0];
                $emailContent = $arrMailContent[1];
                $isSent = global_mail::send($userEmail, $fullName, $emailSubject, $emailContent, null, global_common::SUPPORT_MAIL_USERNAME, global_common::SUPPORT_MAIL_PASSWORD, global_common::SUPPORT_MAIL_DISPLAY_NAME);
            }
            if ($isSent) {
                $badComment = $objCommentBad->getCommentBadByID($commentID);
                if (count($badComment) <= 0) {
                    $createdBy = $c_userInfo[global_mapping::UserID];
                    $resultID = $objCommentBad->insert($commentID, $description, $createdBy, $isBad);
                } else {
                    $updatedBy = $c_userInfo[global_mapping::UserID];
                    $resultID = $objCommentBad->activateBadComment($commentID, $description, $updatedBy, $isBad);
                }
                if ($resultID) {
                    $arrHeader = global_common::getMessageHeaderArr($banCode);
                    //$banCode
                    echo global_common::convertToXML($arrHeader, array("rs", "inf", "form"), array(1, 'Xử lý bad comment thành công'), array(0, 1));
                    return;
                }
            }
        }
        echo global_common::convertToXML($arrHeader, array("rs", "inf"), array(0, "Xử lý thất bại. Xin vui lòng thử lại sau."), array(0, 1));
        return;
    }
    return;
}
开发者ID:vietlethanh,项目名称:timkm20130929,代码行数:31,代码来源:bg_comment.php

示例2: elseif

    }
} elseif ($_pgR['act'] == model_AdType::ACT_DELETE) {
    $IDName = "menu_id";
    $contentID = $_pgR["id"];
    $strTableName = user_menu::TBL_T_MENU;
    $result = global_common::updateDeleteFlag($contentID, $IDName, $strTableName, $_pgR["status"], $objConnection);
    if ($result) {
        $IDName = "content_id";
        $strTableName = user_faq::TBL_T_FAQ;
        $result = global_common::updateDeleteFlag($contentID, $IDName, $strTableName, $_pgR["status"], $objConnection);
    }
    $arrHeader = global_common::getMessageHeaderArr($banCode = 0, 0);
    $arrKey = array("rs", "id");
    $arrValue = array($result ? 1 : 0, $contentID);
    $arrIsMetaData = array(0, 1);
    echo global_common::convertToXML($arrHeader, $arrKey, $arrValue, $arrIsMetaData);
    return;
}
?>

<?php 
include_once 'include/_admin_header.inc';
include_once 'include/_admin_menu.inc';
?>
<script type="text/javascript" src="<?php 
echo $_objSystem->locateJs('sela_AdType.js');
?>
"></script>
	
<!--Begin Form Input -->
<input type="hidden" id="adddocmode" name="adddocmode" value="1<?php 
开发者ID:vietlethanh,项目名称:oceo,代码行数:31,代码来源:admin_adtype.php

示例3: array

                //$banCode
                echo global_common::convertToXML($arrHeader, array("rs", "inf"), array(1, 'Cập nhật thành công'), array(0, 1));
                return;
            } else {
                echo global_common::convertToXML($arrHeader, array("rs", "inf"), array(0, "Input data is invalid"), array(0, 1));
                return;
            }
        }
        return;
    } elseif ($_pgR['act'] == Model_Product::ACT_STORE_PRICE_DELETE) {
        $productPriceID = $_pgR['id'];
        $productPrice = global_common::deleteObject($productPriceID, global_mapping::ProductPriceID, Model_ProductPrice::TBL_SL_PRODUCT_PRICE, $objConnection);
        if ($productPrice) {
            echo global_common::convertToXML($strMessageHeader, array("rs", "inf"), array(1, "Delete successfully"), array(0, 1));
        } else {
            echo global_common::convertToXML($arrHeader, array("rs", "inf"), array(0, "Data is invalid. Pleae try again later"), array(0, 1));
        }
        return;
    }
}
//elseif($_pgR['act'] == Model_ProductType::ACT_GET_ALL)
//{
//	$types = $objArticleType->getAllArticleType(0);
//	echo json_encode($types);
//	return ;
//}
/*elseif($_pgR['act'] == Model_Product::ACT_ACTIVE)
{
	$articleID = $_pgR['id'];
	$isActivate = $_pgR['isactivate'];
	$result = $objArticle->activeArticle($articleID,$isActivate);
开发者ID:vietlethanh,项目名称:oceo,代码行数:31,代码来源:bg_product.php

示例4: array

        echo global_common::convertToXML($strMessageHeader, array('rs', 'content'), array(1, json_encode($advertising)), array(0, 1));
    } else {
        echo global_common::convertToXML($arrHeader, array("rs", "inf"), array(0, "Data is invalid. Pleae try again later"), array(0, 1));
    }
    return;
} elseif ($_pgR['act'] == Model_Advertising::ACT_ACTIVE) {
    $adID = $_pgR['id'];
    $isActivate = $_pgR['isactivate'];
    $result = $objAdvertising->activeAdvertising($adID, $isActivate);
    if ($result) {
        $arrHeader = global_common::getMessageHeaderArr($banCode);
        //$banCode
        echo global_common::convertToXML($arrHeader, array("rs", "inf"), array(1, ($isActivate ? 'Xóa' : 'Deactivate') . ' thành công'), array(0, 1));
        return;
    } else {
        echo global_common::convertToXML($arrHeader, array("rs", "inf"), array(0, ($isActivate ? 'Xóa' : 'Deactivate') . ' unsuccessfully'), array(0, 1));
        return;
    }
}
$catID = $_pgR["cid"];
$adTypeID = $_pgR["tid"];
$deleted = $_pgR["deleted"];
$condition = '';
if ($catID) {
    $condition .= global_mapping::ArticleTypeID . '=' . $catID . '';
}
if ($adTypeID) {
    if ($condition) {
        $condition .= ' and ' . global_mapping::AdTypeID . '=' . $adTypeID;
    } else {
        $condition .= global_mapping::AdTypeID . '=' . $adTypeID;
开发者ID:vietlethanh,项目名称:KooKooBackEnd,代码行数:31,代码来源:admin_advertising.php

示例5: html_entity_decode

                        $fullName = $_pgR['fullName'];
                        $fullName = html_entity_decode($fullName, ENT_COMPAT, 'UTF-8');
                        $email = $_pgR['email'];
                        $email = html_entity_decode($email, ENT_COMPAT, 'UTF-8');
                        $subject = $_pgR['subject'];
                        $subject = html_entity_decode($subject, ENT_COMPAT, 'UTF-8');
                        $content = $_pgR['content'];
                        $content = html_entity_decode($content, ENT_COMPAT, 'UTF-8');
                        $emailContent = 'From:' . $fullName . '<br>' . 'Email:' . $email . '<br>' . 'Content: <br>' . $content;
                        $isSent = global_mail::send(global_common::SUPPORT_MAIL_USERNAME, global_common::SUPPORT_MAIL_DISPLAY_NAME, $subject, $emailContent, null, global_common::SUPPORT_MAIL_USERNAME, global_common::SUPPORT_MAIL_PASSWORD, global_common::SUPPORT_MAIL_DISPLAY_NAME);
                        if ($isSent) {
                            $arrHeader = global_common::getMessageHeaderArr($banCode);
                            //$banCode
                            echo global_common::convertToXML($arrHeader, array('rs', 'inf'), array(1, 'Đã gửi thành công.'), array(0, 1));
                            return;
                        } else {
                            echo global_common::convertToXML($arrHeader, array('rs', 'inf'), array(0, 'Xử lý thất bại. Xin vui lòng thử lại sau!'), array(0, 1));
                            return;
                        }
                    } else {
                        if ($_pgR["act"] == Model_User::ACT_LOGOUT) {
                            echo global_common::convertToXML($arrHeader, array('rs', 'inf', 'rurl'), array(1, '', $_SESSION[global_common::SES_C_CUR_PAGE]), array(0, 1, 1));
                            global_common::clearSession();
                            return;
                        }
                    }
                }
            }
        }
    }
}
开发者ID:vietlethanh,项目名称:oceo,代码行数:31,代码来源:bg_user.php

示例6: array

require 'config/globalconfig.php';
include_once 'class/model_user.php';
if ($_pgR["act"] == model_Article::ACT_ADD) {
    $createdBy = $_pgR['CreatedBy'];
    $createdBy = global_editor::rteSafe(html_entity_decode($createdBy, ENT_COMPAT, 'UTF-8'));
    $createdDate = $_pgR['CreatedDate'];
    $createdDate = global_editor::rteSafe(html_entity_decode($createdDate, ENT_COMPAT, 'UTF-8'));
    $modifiedBy = $_pgR['ModifiedBy'];
    $modifiedBy = global_editor::rteSafe(html_entity_decode($modifiedBy, ENT_COMPAT, 'UTF-8'));
    $modifiedDate = $_pgR['ModifiedDate'];
    $modifiedDate = global_editor::rteSafe(html_entity_decode($modifiedDate, ENT_COMPAT, 'UTF-8'));
    $deletedBy = $_pgR['DeletedBy'];
    $deletedBy = global_editor::rteSafe(html_entity_decode($deletedBy, ENT_COMPAT, 'UTF-8'));
    $deletedDate = $_pgR['DeletedDate'];
    $deletedDate = global_editor::rteSafe(html_entity_decode($deletedDate, ENT_COMPAT, 'UTF-8'));
    $isDeleted = $_pgR['IsDeleted'];
    $isDeleted = global_editor::rteSafe(html_entity_decode($isDeleted, ENT_COMPAT, 'UTF-8'));
    //$strName = $_pgR['name'];
    //$strName = global_editor::rteSafe(html_entity_decode($strName,ENT_COMPAT ,'UTF-8' ));
    $resultID = $objArticle->insert($articleid, $prefix, $title, $filename, $articletype, $content, $notificationtype, $tags, $catalogueid, $sectionid, $numview, $numcomment, $status);
    if ($resultID) {
        $arrHeader = global_common::getMessageHeaderArr($banCode);
        //$banCode
        echo global_common::convertToXML($arrHeader, array("rs", "inf"), array(1, $result), array(0, 1));
        return;
    } else {
        echo global_common::convertToXML($arrHeader, array("rs", "info"), array(0, "Input data is invalid"), array(0, 1));
        return;
    }
    return;
}
开发者ID:roni5,项目名称:sela,代码行数:31,代码来源:public.php

示例7: array

        $arrHeader = global_common::getMessageHeaderArr($banCode);
        //$banCode
        echo global_common::convertToXML($arrHeader, array('rs', 'inf'), array(2, 'Tên đăng nhập đã tồn tại'), array(0, 1));
        return;
    }
    if ($objUser->checkExistEmail($email)) {
        $arrHeader = global_common::getMessageHeaderArr($banCode);
        //$banCode
        echo global_common::convertToXML($arrHeader, array('rs', 'inf'), array(3, 'Email đã tồn tại'), array(0, 1));
        return;
    }
    $resultID = $objUser->register($userName, $password, $fullname, $birthDate, $email, $sex);
    if ($resultID) {
        $arrHeader = global_common::getMessageHeaderArr($banCode);
        //$banCode
        echo global_common::convertToXML($arrHeader, array('rs', 'inf'), array(1, 'Đăng ký thành công'), array(0, 1));
        return;
    } else {
        echo global_common::convertToXML($arrHeader, array('rs', 'info'), array(0, 'Đăng ký thất bại'), array(0, 1));
        return;
    }
} else {
    if ($_pgR["act"] == Model_User::ACT_LOGOUT) {
        // or this would remove all the variables in the session, but not the session itself
        session_unset();
        // this would destroy the session variables
        session_destroy();
        echo global_common::convertToXML($arrHeader, array('rs', 'inf'), array(1, ''), array(0, 1));
        return;
    }
}
开发者ID:roni5,项目名称:sela,代码行数:31,代码来源:bg_user.php


注:本文中的global_common::convertToXML方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。