Ejemplo n.º 1
0
<?php
include_once(dirname(__FILE__)."/frame.class.inc");
include_once(dirname(__FILE__)."/class.unix.inc");
include_once(dirname(__FILE__)."/class.postfix.inc");



if(isset($_GET["locales"])){locales();exit;}
if(isset($_GET["foldersnames"])){foldersnames();exit;}
if(isset($_GET["zarafa-user-create-store"])){zarafa_user_create_store();exit;}
if(isset($_GET["DbAttachConverter"])){DbAttachConverter();exit;}
if(isset($_GET["mbx-infos"])){mbx_infos();exit;}
if(isset($_GET["csv-export"])){csv_export();exit;}



while (list ($num, $ligne) = each ($_GET) ){$a[]="$num=$ligne";}
writelogs_framework("unable to unserstand ".@implode("&",$a),__FUNCTION__,__FILE__,__LINE__);


function locales(){
	$unix=new unix();
	$locale=$unix->find_program("locale");
	exec("$locale -a 2>&1",$results);
	echo "<articadatascgi>". base64_encode(serialize($results))."</articadatascgi>";
}

function foldersnames(){
	$unix=new unix();
	$php5=$unix->LOCATE_PHP5_BIN();
	$zarafa=$unix->find_program("zarafa-server");
Ejemplo n.º 2
0
  * License
  */
 case "license":
     include "license.mtree.php";
     break;
     /***
      * CSV Import/Export
      */
 /***
  * CSV Import/Export
  */
 case "csv":
     csv($option);
     break;
 case "csv_export":
     csv_export($option);
     break;
     /***
      * Upgrade routine
      */
 /***
  * Upgrade routine
  */
 case "upgrade":
     require_once JPATH_ADMINISTRATOR . DS . 'components' . DS . 'com_mtree' . DS . 'upgrade.php';
     break;
     /***
      * Diagnosis
      */
 /***
  * Diagnosis
Ejemplo n.º 3
0
    exit;
}
if (isset($_GET["zarafa-user-create-store"])) {
    zarafa_user_create_store();
    exit;
}
if (isset($_GET["DbAttachConverter"])) {
    DbAttachConverter();
    exit;
}
if (isset($_GET["mbx-infos"])) {
    mbx_infos();
    exit;
}
if (isset($_GET["csv-export"])) {
    csv_export();
    exit;
}
if (isset($_GET["removeidb"])) {
    removeidb();
    exit;
}
if (isset($_GET["zarafa-orphan-kill"])) {
    orphan_delete();
    exit;
}
if (isset($_GET["zarafa-orphan-link"])) {
    orphan_link();
    exit;
}
if (isset($_GET["zarafa-orphan-scan"])) {
Ejemplo n.º 4
0
   Camila PHP Framework is distributed in the hope that it will be useful,
   but WITHOUT ANY WARRANTY; without even the implied warranty of
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
   GNU General Public License for more details.

   You should have received a copy of the GNU General Public License
   along with Camila PHP Framework; if not, write to the Free Software
   Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA */
require CAMILA_LIB_DIR . '/adodb/toexport.inc.php';
require_once CAMILA_DIR . '/datagrid/form.class.php';
require_once CAMILA_DIR . '/datagrid/elements/form/static_listbox.php';
$options = '';
if (is_array($tables = $_CAMILA['db']->MetaTables('TABLES'))) {
    foreach ($tables as $table) {
        $options .= $table . ',';
    }
}
$form = new phpform('table', basename($_SERVER['PHP_SELF']) . '?dbexport');
new form_static_listbox($form, 'table', 'Table', $options, true);
if ($form->process()) {
    $file = CAMILA_TABLES_DIR . '/' . $form->fields['table']->value . '.csv';
    require_once CAMILA_DIR . 'db/export.inc.php';
    $result = csv_export($form->fields['table']->value, $file, $_CAMILA['db']);
    ob_start();
    print_r($result);
    $sql_r = ob_get_contents();
    ob_end_clean();
    camila_information_text('DATA EXPORT ' . $sql_r);
}
$form->draw();