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


PHP Vtiger_Package::packageFromFilesystem方法代码示例

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


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

示例1: vtlib_purify

include_once 'vtlib/Vtiger/Module.php';
global $current_user, $adb;
$dl = vtlib_purify($_REQUEST['download']);
$dl = !empty($dl);
if (!$dl) {
    header('Content-Type: text/html; charset=UTF8');
    ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html><head><title><?php 
    echo $title;
    ?>
</title>
<style type="text/css">@import url("themes/softed/style.css");br { display: block; margin: 2px; }</style>
</head><body class=small style="font-size: 12px; margin: 2px; padding: 2px;">
<?php 
}
set_time_limit(0);
ini_set('memory_limit', '1024M');
if (empty($_REQUEST['modulename'])) {
    echo '<br><br><b>Necessary Parameter {modulename} not present</b><br>';
} else {
    $modulename = vtlib_purify($_REQUEST['modulename']);
    Vtiger_Package::packageFromFilesystem($modulename, false, $dl);
    if ($dl) {
        die;
    }
    echo "<b>Package should be exported to the packages/optional directory of your install.</b><br>";
}
?>
</body>
</html>
开发者ID:casati-dolibarr,项目名称:corebos,代码行数:31,代码来源:export_package_filesystem.php

示例2: vtlib_purify

/*+********************************************************************************
 * The contents of this file are subject to the vtiger CRM Public License Version 1.0
 * ("License"); You may not use this file except in compliance with the License
 * The Original Code is:  vtiger CRM Open Source
 * The Initial Developer of the Original Code is vtiger.
 * Portions created by vtiger are Copyright (C) vtiger.
 * All Rights Reserved.
 ********************************************************************************/
$module_export = vtlib_purify($_REQUEST['module_export']);
require_once "vtlib/Vtiger/Package.php";
require_once "vtlib/Vtiger/Module.php";
$package = new Vtiger_Package();
$module = Vtiger_Module::getInstance($module_export);
if ($module) {
    if (isset($_REQUEST['manifestfs'])) {
        Vtiger_Package::packageFromFilesystem($module_export, false, true);
    } else {
        $package->export($module, '', "{$module_export}.zip", true);
    }
} else {
    global $adb, $vtiger_current_version;
    $lngrs = $adb->pquery('select * from vtiger_language where prefix=?', array($module_export));
    if ($lngrs and $adb->num_rows($lngrs) == 1) {
        // we have a language file
        $lnginfo = $adb->fetch_array($lngrs);
        $lngxml = 'include/language/' . $lnginfo['prefix'] . '.manifest.xml';
        if (!file_exists($lngxml)) {
            $mnf = fopen($lngxml, 'w');
            fwrite($mnf, "<?xml version='1.0'?>\n");
            fwrite($mnf, "<module>\n");
            fwrite($mnf, "<type>language</type>\n");
开发者ID:casati-dolibarr,项目名称:corebos,代码行数:31,代码来源:Export.php


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