コード例 #1
0
ファイル: sales.php プロジェクト: BackupTheBerlios/soopa
function ShowServs()
{
    global $xoopsDB;
    include 'functions.php';
    $result = $xoopsDB->query("SELECT * FROM {$tvensrv} ORDER BY id_srv");
    xoops_cp_header();
    ShowNav();
    echo "<table width='100%' class='outer' cellspacing='1'>\n\t\t\t<tr><th colspan='4'>" . _AM_SERVS_LIST . "</th></tr>";
    while ($row = $xoopsDB->fetchArray($result)) {
        echo "<tr class='even'><td align='left'>\n\t\t\t  <a href='promos.php?op=view&amp;idp={$row['id_promo']}'>" . ServiceName($row['id_srv']) . "</a></td>\n\t\t\t  <td align='center'>" . date("d/m/Y h:i:s", $row['fecha']) . "</td>\n\t\t\t  <td align='center'>{$row['buyermail']}</td>\n\t\t\t  <td align='center'><a href='sales.php?op=promos&amp;action=del'>" . _AM_DELETE . "</a></td>\n\t\t\t  </tr>";
    }
    echo "</table>";
    xoops_cp_footer();
}
コード例 #2
0
ファイル: services.php プロジェクト: BackupTheBerlios/soopa
function DelCar()
{
    global $xoopsDB;
    $ok = $_POST['ok'];
    $idc = $_POST['idc'];
    $ids = $_POST['ids'];
    if ($idc <= 0) {
        header('location: services.php?op=caract&ids=' . $ids);
        die;
    }
    if ($ok) {
        $xoopsDB->query("DELETE FROM " . $xoopsDB->prefix('rmsrv_caract') . " WHERE id_car='{$idc}'");
        $xoopsDB->query("DELETE FROM " . $xoopsDB->prefix('rmsrv_carrel') . " WHERE id_car='{$idc}'");
        redirect_header('services.php?op=caract&amp;ids=' . $ids, 1, _AM_CARDELETED);
        die;
    } else {
        include 'functions.php';
        xoops_cp_header();
        ShowNav();
        echo "<table width='60%' class='outer' cellspacing='1' align='center'>\n\n\t\t\t\t<tr class='even'><td align='center'>\n\n\t\t\t\t<form name='frm' method='post' action='services.php'>\n\t\t\t\t" . _AM_CONFIRMDELCAR . "<br><br>\n\n\t\t\t\t<input type='button' name='sbt' value='" . _AM_CANCEL . "' onClick='javascript: history.go(-1);'>\n\n\t\t\t\t<input type='submit' name='sbt' value='" . _AM_DELETE . "'>\n\n\t\t\t\t<input type='hidden' name='op' value='delcar'>\n\n\t\t\t\t<input type='hidden' name='ok' value='1'>\n\n\t\t\t\t<input type='hidden' name='ids' value='{$ids}'>\n\n\t\t\t\t<input type='hidden' name='idc' value='{$idc}'>\n\n\t\t\t\t</form></td></tr></table>";
        xoops_cp_footer();
    }
}
コード例 #3
0
ファイル: index.php プロジェクト: BackupTheBerlios/soopa
// This program is free software; you can redistribute it and/or modify     //
// it under the terms of the GNU General Public License as published by     //
// the Free Software Foundation; either version 2 of the License, or        //
// (at your option) any later version.                                      //
//                                                                          //
// This program 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.                             //
// ------------------------------------------------------------------------ //
// Este programa es un programa libre; puedes distribuirlo y modificarlo    //
// bajo los términos de al GNU General Public Licencse como ha sido         //
// publicada por The Free Software Foundation (Fundación de Software Libre; //
// en cualquier versión 2 de la Licencia o mas reciente.                    //
//                                                                          //
// Este programa es distribuido esperando que sea últil pero SIN NINGUNA    //
// GARANTÍA. Ver The GNU General Public License para mas detalles.          //
// ------------------------------------------------------------------------ //
// Questions, Bugs or any comment plese write me                            //
// Preguntas, errores o cualquier comentario escribeme                      //
// <*****@*****.**>                                              //
// ------------------------------------------------------------------------ //
//////////////////////////////////////////////////////////////////////////////
include '../../../include/cp_header.php';
if (!file_exists("../language/" . $xoopsConfig['language'] . "/admin.php")) {
    include "../language/spanish/admin.php";
}
include 'functions.php';
xoops_cp_header();
ShowNav();
xoops_cp_footer();
コード例 #4
0
ファイル: terminos.php プロジェクト: BackupTheBerlios/soopa
function Delete()
{
    global $xoopsDB;
    $idt = $_POST['idt'];
    if ($idt <= 0) {
        header('location: terminos.php');
        die;
    }
    $ok = $_POST['ok'];
    if ($ok) {
        $xoopsDB->query("DELETE FROM " . $xoopsDB->prefix('rmsrv_trel') . " WHERE id_term='{$idt}'");
        $xoopsDB->query("DELETE FROM " . $xoopsDB->prefix('rmsrv_terminos') . " WHERE id_term='{$idt}'");
        redirect_header('terminos.php', 1, _AM_TERMS_DELETED);
        die;
    } else {
        include_once 'functions.php';
        xoops_cp_header();
        ShowNav();
        echo "<table width='60%' class='outer' cellspacing='1' align='center'>\n\n\t\t\t\t<tr class='even'><td align='center'>\n\n\t\t\t\t<form name='frm' method='post' action='terminos.php'>\n\t\t\t\t" . _AM_TERM_CONFIRMDEL . "<br><br>\n\n\t\t\t\t<input type='button' name='sbt' value='" . _AM_CANCEL . "' onClick='javascript: history.go(-1);'>\n\n\t\t\t\t<input type='submit' name='sbt' value='" . _AM_DELETE . "'>\n\n\t\t\t\t<input type='hidden' name='op' value='del'>\n\n\t\t\t\t<input type='hidden' name='ok' value='1'>\n\n\t\t\t\t<input type='hidden' name='idt' value='{$idt}'>\n\n\t\t\t\t</form></td></tr></table>";
        xoops_cp_footer();
    }
}
コード例 #5
0
ファイル: banners.php プロジェクト: BackupTheBerlios/soopa
function Delete()
{
    global $xoopsDB;
    $ok = $_POST['ok'];
    if ($ok) {
        $idb = $_POST['idb'];
        if ($idb <= 0) {
            ShowBanns();
            die;
        }
        $xoopsDB->query("DELETE FROM " . $xoopsDB->prefix("rmsrv_banners") . " WHERE id_ban='{$idb}'");
        $err = $xoopsDB->error();
        if ($err == '') {
            redirect_header('banners.php', 1, _AM_BANNDELOK);
            die;
        } else {
            redirect_header('banners.php?op=mod&amp;idb=' . $idb, 1, _AM_ERRNEXT . $err);
            die;
        }
    } else {
        include 'functions.php';
        xoops_cp_header();
        ShowNav();
        echo "<table class='outer' width='60%' align='center' cellspacing='1'>\n\t\t\t\t<tr><td class='even' align='center'>\n\t\t\t\t<form name='frmDel' method='post' action='banners.php'>\n\t\t\t\t<br><br>" . _DEL_CONFIRM . "<br><br>\n\t\t\t\t<input type='button' name='cancel' value='" . _AM_CANCEL . "' onClick='javascript: history.go(-1);'>\n\t\t\t\t<input type='submit' name='sbt' value='" . _AM_DELETE . "'>\n\t\t\t\t<input type='hidden' name='op' value='del'>\n\t\t\t\t<input type='hidden' name='ok' value='1'>\n\t\t\t\t<input type='hidden' name='idb' value='" . $_GET['idb'] . "'>\n\t\t\t\t</form></td></table>";
        xoops_cp_footer();
    }
}
コード例 #6
0
ファイル: categos.php プロジェクト: BackupTheBerlios/soopa
function ViewCatego()
{
    global $xoopsDB, $myts;
    $idc = $_GET['idc'];
    if ($idc <= 0) {
        header('location: categos.php');
        die;
    }
    include 'functions.php';
    $result = $xoopsDB->query("SELECT * FROM {$tcategos} WHERE id_cat='{$idc}'");
    $num = $xoopsDB->getRowsNum($result);
    if ($num <= 0) {
        redirect_header('categos.php', 1, _AM_NOEXIST);
        die;
    }
    $row = $xoopsDB->fetchArray($result);
    xoops_cp_header();
    ShowNav();
    echo "<table width='100%' cellspacing='1' class='outer'>\n\n\t\t\t<tr><th colspan='2'>{$row['nombre']}</th></tr>\n\n\t\t\t<tr><td class='even' align='center'>";
    if ($row['img'] != '') {
        echo "<img src='" . XOOPS_URL . "/modules/rmservices/images/categos/{$row['img']}' border='0'>";
    }
    echo "  </td><td class='odd' align='left'>" . $myts->makeTareaData4Show($row['desc']) . "<br><br><br>\n\t\t\t<a href='categos.php?op=mod&amp;idc=" . $idc . "'>" . _AM_MODIFY . "</a>\n |\n\t\t\t<a href='categos.php?op=del&amp;idc=" . $idc . "'>" . _AM_DELETE . "</a>\n</td></tr></table><br>";
    echo "<table width='100%' class='outer' cellspacing='1'>\n\t\t\t<tr><th colspan='2'>" . sprintf(_AM_SERVICESIN, $row['nombre']) . "</th></tr>";
    $result = $xoopsDB->query("SELECT id_srv, nombre, activo, shortdesc FROM {$tservs} WHERE id_cat='{$idc}'");
    while ($row = $xoopsDB->fetchArray($result)) {
        echo "<tr class='even'><td align='left'>\n\t\t\t\t\t<a href='services.php?op=view&amp;ids=" . $row['id_srv'] . "'>{$row['nombre']}</a><br>\n\t\t\t\t\t<span style='font-size: 9px;'>\n\t\t\t\t\t{$row['shortdesc']}<br><strong>";
        if ($row['activo'] == 1) {
            echo _AM_ACTIVE;
        } else {
            echo _AM_INACTIVE;
        }
        echo "</strong></span></td>\n\t\t\t\t\t<td align='center'>\n\t\t\t\t\t<a href='services.php?op=mod&amp;ids=" . $row['id_srv'] . "'>" . _AM_MODIFY . "</a>\n\n\t\t\t\t    <a href='services.php?op=del&amp;ids=" . $row['id_srv'] . "'>" . _AM_DELETE . "</a>\n\n\t\t\t\t\t</td></tr>";
    }
    echo "</table>";
    xoops_cp_footer();
}
コード例 #7
0
ファイル: promos.php プロジェクト: BackupTheBerlios/soopa
function ViewPromo()
{
    global $xoopsDB, $myts;
    $idp = $_GET['idp'];
    if ($idp <= 0) {
        ShowPromos();
        die;
    }
    include_once 'functions.php';
    $result = $xoopsDB->query("SELECT * FROM {$tpromos} WHERE id_promo='{$idp}'");
    $num = $xoopsDB->getRowsNum($result);
    if ($num <= 0) {
        redirect_header('promos.php', 1, _AM_NOEXIST);
        die;
    }
    $row = $xoopsDB->fetchArray($result);
    xoops_cp_header();
    ShowNav();
    echo "<table width='100%' class='outer' cellspacing='2'>\n\n\t\t\t<tr><th colspan='2'>{$row['nombre']}</th></tr>\n\t\t\t<tr><td class='even' align='center'>";
    if ($row['img'] != '') {
        echo "<img src='{$row['img']}' border='0'>";
    }
    echo "<br><br>\n\t\t\t<a href='promos.php?op=mod&amp;idp=" . $idp . "'>" . _AM_MODIFY . "</a><br>\n\t\t\t<a href='promos.php?op=del&amp;idp=" . $idp . "'>" . _AM_DELETE . "</a></td>\n\t\t\t<td class='odd' align='left'>" . $myts->makeTareaData4Show($row['longdesc']) . "<br><br>\n\t\t\t<strong>" . _AM_FORMPRICE . "</strong> {$row['precio']}<br>\n\t\t\t<strong>" . _AM_FORMCODE . "</strong> <span style='font-family: courier'>{$row['codigo']}</a><br>\n\t\t\t</td></table><br>";
    echo "<table width='100%' class='outer' cellspacing='2'>\n\n\t\t\t<tr><th colspan='2'>" . _AM_ASSIGNED . "</th></tr>";
    $result = $xoopsDB->query("SELECT * FROM {$tprorel} WHERE id_promo='{$idp}'");
    while ($row = $xoopsDB->fetchArray($result)) {
        echo "<tr><td class='even' align='left'>\n\t\t\t\t\t<a href='services.php?op=view&amp;ids=" . $row['id_srv'] . "'>" . ServiceName($row['id_srv']) . "</a></td>\n\n\t\t\t\t\t<td class='even' align='center'>\n\t\t\t\t\t<a href='services.php?op=mod&amp;ids=" . $row['id_srv'] . "'>" . _AM_MODIFY . "</a></td></tr>";
    }
    echo "  </table>";
    xoops_cp_footer();
}