• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

PHP xoopsCodeTarea函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了PHP中xoopsCodeTarea函数的典型用法代码示例。如果您正苦于以下问题:PHP xoopsCodeTarea函数的具体用法?PHP xoopsCodeTarea怎么用?PHP xoopsCodeTarea使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



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

示例1: html_editor

function html_editor($textareaname)
{
    if (preg_match("/(MSIE)/i", $_SERVER['HTTP_USER_AGENT'])) {
        init_editor($textareaname);
    } else {
        xoopsCodeTarea($textareaname);
        xoopsSmilies($textareaname);
    }
}
开发者ID:severnaya99,项目名称:Sg-2010,代码行数:9,代码来源:wysiwygeditor.php


示例2: ModForm

function ModForm()
{
    global $xoopsDB;
    $idt = $_POST['idt'];
    if ($idt <= 0) {
        header('location: terminos.php');
        die;
    }
    xoops_cp_header();
    include_once 'functions.php';
    include XOOPS_ROOT_PATH . "/include/xoopscodes.php";
    ShowNav();
    $result = $xoopsDB->query("SELECT * FROM {$tterms} WHERE id_term='{$idt}'");
    $row = $xoopsDB->fetchArray($result);
    echo "<table width='100%' class='outer' cellspacing='1'>\n\n\t\t\t<tr><th colspan='2'>" . _AM_TERMS_MOD . "</th></tr>\n\t\t\t<form name='frmNew' method='post' action='terminos.php'>\n\t\t\t<tr><td class='even' align='left'>" . _AM_TERM_TITLE . "</td>\n\n\t\t\t<td class='odd' align='left'><input value='{$row['titulo']}' type='text' name='titulo' size='30'></td></tr>\n\t\t\t<tr><td class='even' align='left'>" . _AM_TERMS_TEXT . "</td>\n\n\t\t\t<td class='odd' align='left'>";
    $GLOBALS['texto'] = $row['texto'];
    xoopsCodeTarea("texto", 20, 15);
    xoopsSmilies("texto");
    echo "\t</td></tr>\n\n\t\t\t<tr><td class='even'>&nbsp;</td>\n\n\t\t\t<td class='odd' align='left'><input type='submit' name='sbt' value='" . _AM_SEND . "'></td></tr>\n\n\t\t\t<input type='hidden' name='op' value='savemod'>\n\t\t\t<input type='hidden' name='idt' value='{$idt}'>\n\t\t\t</form></table>";
    xoops_cp_footer();
}
开发者ID:BackupTheBerlios,项目名称:soopa,代码行数:21,代码来源:terminos.php


示例3: redirect_header

    } else {
        $tags['WAITINGLINKS_URL'] = XOOPS_URL . '/modules/' . $xoopsModule->getVar('dirname') . '/admin/index.php?op=listNewLinks';
        $notification_handler->triggerEvent('global', 0, 'link_submit', $tags);
        $notification_handler->triggerEvent('category', $cid, 'link_submit', $tags);
        if ($notify) {
            include_once XOOPS_ROOT_PATH . '/include/notification_constants.php';
            $notification_handler->subscribe('link', $newid, 'approve', XOOPS_NOTIFICATION_MODE_SENDONCETHENDELETE);
        }
        redirect_header("index.php", 2, _MD_RECEIVED);
    }
    exit;
} else {
    $xoopsOption['template_main'] = 'mylinks_submit.html';
    include XOOPS_ROOT_PATH . "/header.php";
    ob_start();
    xoopsCodeTarea("message", 37, 8);
    $xoopsTpl->assign('xoops_codes', ob_get_contents());
    ob_end_clean();
    ob_start();
    xoopsSmilies("message");
    $xoopsTpl->assign('xoops_smilies', ob_get_contents());
    ob_end_clean();
    $xoopsTpl->assign('notify_show', !empty($xoopsUser) && !$xoopsModuleConfig['autoapprove'] ? 1 : 0);
    $xoopsTpl->assign('lang_submitonce', _MD_SUBMITONCE);
    $xoopsTpl->assign('lang_submitlinkh', _MD_SUBMITLINKHEAD);
    $xoopsTpl->assign('lang_allpending', _MD_ALLPENDING);
    $xoopsTpl->assign('lang_dontabuse', _MD_DONTABUSE);
    $xoopsTpl->assign('lang_wetakeshot', _MD_TAKESHOT);
    $xoopsTpl->assign('lang_sitetitle', _MD_SITETITLE);
    $xoopsTpl->assign('lang_siteurl', _MD_SITEURL);
    $xoopsTpl->assign('lang_category', _MD_CATEGORYC);
开发者ID:amjadtbssm,项目名称:website,代码行数:31,代码来源:submit.php


示例4: ModForm

function ModForm()
{
    global $xoopsDB;
    $idb = $_GET['idb'];
    if ($idb <= 0) {
        ShowBanns();
        die;
    }
    include 'functions.php';
    $result = $xoopsDB->query("SELECT * FROM {$tbann} WHERE id_ban='{$idb}'");
    $num = $xoopsDB->getRowsNum($result);
    if ($num <= 0) {
        redirect_header('banners.php', 1, _AM_NOEXIST);
        die;
    }
    $row = $xoopsDB->fetchArray($result);
    include XOOPS_ROOT_PATH . "/include/xoopscodes.php";
    xoops_cp_header();
    ShowNav();
    echo "<table width='100%' class='outer' cellspacing='1'>\n\n\t\t\t<tr><th colspan='2'>" . _AM_MODBANN . "</th></tr>\n\t\t\t<form name='frmNew' method='post' action='banners.php'>\n\t\t\t<tr><td class='even' align='left'>" . _AM_FORMSERV . "</td>\n\n\t\t\t<td class='odd' align='left'><select name='ids'>\n\n\t\t\t<option value='0'>" . _AM_SELECTSRV . "</option>";
    $result = $xoopsDB->query("SELECT nombre, id_srv, id_cat FROM " . $xoopsDB->prefix("rmsrv_servicios") . " ORDER BY nombre");
    while ($rw = $xoopsDB->fetchArray($result)) {
        if ($row['id_srv'] == $rw['id_srv']) {
            echo "<option value='{$rw['id_srv']}' selected>{$rw['nombre']} (" . CategoName($rw['id_cat']) . ")</option>";
        } else {
            echo "<option value='{$rw['id_srv']}'>{$rw['nombre']} (" . CategoName($rw['id_cat']) . ")</option>";
        }
    }
    echo "</select></td></tr>\n\t\t  <tr><td class='even' align='left'>" . _AM_FORMIMG . "</td>\n\t\t  <td class='odd' align='left'><textarea cols='30' rows='3' name='img'>{$row['img']}</textarea></td></tr>\n\t\t  <tr><td align='left' class='even'>" . _AM_DESC . "</td>\n\t\t  <td class='odd' align='left'>";
    $GLOBALS['desc'] = $row['desc'];
    xoopsCodeTarea("desc", 20, 15);
    xoopsSmilies("desc");
    echo "</td></tr>\n\n\t\t  <tr><td class='even' align='left'>" . _AM_SHOWBUY . "</td>\n\t\t  <td class='odd' align='left'>";
    if ($row['buy']) {
        echo "<input type='radio' name='buy' value='1' checked='checked' /> " . _AM_YES . "&nbsp;\n\t\t  \t\t  <input type='radio' name='buy' value='0' /> " . _AM_NO . "</td></tr>";
    } else {
        echo "<input type='radio' name='buy' value='1' /> " . _AM_YES . "&nbsp;\n\t\t  \t\t  <input type='radio' name='buy' value='0' checked='checked' /> " . _AM_NO . "</td></tr>";
    }
    echo "<tr><td class='even' align='left'>" . _AM_SHOWBORDER . "</td>\n\t\t  <td class='odd' align='left'>";
    if ($row['showborder']) {
        echo "<input type='radio' name='borde' value='1' checked='checked' /> " . _AM_YES . "&nbsp;\n\t\t  \t\t  <input type='radio' name='borde' value='0' /> " . _AM_NO . "</td></tr>";
    } else {
        echo "<input type='radio' name='borde' value='1' /> " . _AM_YES . "&nbsp;\n\t\t  \t\t  <input type='radio' name='borde' value='0' checked='checked' /> " . _AM_NO . "</td></tr>";
    }
    echo "<tr><td class='even'>&nbsp;</td>\n\t\t  <td class='odd' align='left'><input type='submit' name='sbt' value='" . _AM_SEND . "'></td></tr>\n\t\t  <input type='hidden' name='op' value='savemod'>\n\t\t  <input type='hidden' name='idb' value='{$idb}'></form></table>";
    xoops_cp_footer();
}
开发者ID:BackupTheBerlios,项目名称:soopa,代码行数:47,代码来源:banners.php


示例5: NewCatego_Form

function NewCatego_Form($action = 0)
{
    global $xoopsDB;
    include XOOPS_ROOT_PATH . "/include/xoopscodes.php";
    if ($action) {
        $result = $xoopsDB->query("SELECT * FROM " . $xoopsDB->prefix("rmlib_categos") . " WHERE cid='{$_GET['cid']}'");
        list($tid, $titulo, $desc, $fecha) = $xoopsDB->fetchRow($result);
    }
    $GLOBALS['desc'] = $desc;
    $cid = $_GET['cid'];
    xoops_cp_header();
    echo "<table align='center' class='outer' cellspacing='1' cellpadding='0' width='80%'>\n\n\t\t\t<tr><th align='left' colspan='2'>" . _RH_CATEGOS_NEWCATEGO . "</th><tr>\n\n\t\t\t<form name='frmNew' method='post' action='index.php'>\n\t\t\t<tr><td class='even' align='left'>" . _RH_CATEGOS_TITLEC . "</td>\n\n\t\t\t<td class='odd' align='left'><input type='text' name='title' size='30' maxlength='100' value='{$titulo}'></td></tr>\n\n\t\t\t<tr><td class='even' align='left'>" . _RH_CATEGOS_DESC . "</td>\n\n\t\t\t<td class='odd' align='left'>";
    xoopsCodeTarea("desc", 20, 15);
    xoopsSmilies("desc");
    echo "  </td></tr>\n\n\t\t\t<tr><td class='even'>&nbsp;</td>\n\n\t\t\t<td class='odd' align='left'><input type='submit' name='sbt' value='" . _RH_GENERAL_SEND . "'>\n\n\t\t\t<input type='button' name='cancel' value='" . _RH_GENERAL_CANCEL . "' onClick='javascript: history.go(-1)'></td></tr>\n\n\t\t\t<input type='hidden' name='op' value='savecatego'>\n\n\t\t\t<input type='hidden' name='tid' value='{$tid}'>\n\n\t\t\t<input type='hidden' name='cid' value='{$cid}'>\n</form></table>";
    xoops_cp_footer();
}
开发者ID:BackupTheBerlios,项目名称:soopa,代码行数:17,代码来源:index.php


示例6: while

$count = 1;
while (list($key, $file) = each($filelist)) {
    $checked = "";
    if (isset($icon) && $file == $icon) {
        $checked = " checked='checked'";
    }
    echo "<input type='radio' value='{$file}' name='icon'{$checked} />&nbsp;";
    echo "<img src='" . XOOPS_URL . "/images/subject/{$file}' alt='' />&nbsp;";
    if ($count == 8) {
        echo "<br />";
        $count = 0;
    }
    $count++;
}
echo "</td></tr>\r\n<tr align='left'>\r\n<td class='head' valign='top' nowrap='nowrap'>" . _MD_MESSAGEC . "\r\n</td>\r\n<td class='odd'>";
xoopsCodeTarea("message");
if (!empty($isreply) && isset($hidden) && $hidden != "") {
    echo "<input type='hidden' name='isreply' value='1' />";
    echo "<input type='hidden' name='hidden' id='hidden' value='{$hidden}' />\r\n\t<input type='button' name='quote' class='formButton' value='" . _MD_QUOTE . "' onclick='xoopsGetElementById(\"message\").value=xoopsGetElementById(\"message\").value + xoopsGetElementById(\"hidden\").value; xoopsGetElementById(\"hidden\").value=\"\";' /><br />";
}
xoopsSmilies("message");
echo "</td></tr>\r\n<tr>";
echo "<td class='head' valign='top' nowrap='nowrap'>" . _MD_OPTIONS . "</td>\n";
echo "<td class='even'>";
if ($xoopsUser && $forumdata['forum_access'] == 2 && !empty($post_id)) {
    echo "<input type='checkbox' name='noname' value='1'";
    if (isset($noname) && $noname) {
        echo " checked='checked'";
    }
    echo " />&nbsp;" . _MD_POSTANONLY . "<br />\n";
}
开发者ID:amjadtbssm,项目名称:website,代码行数:31,代码来源:forumform.inc.php


示例7: Aceptar

function Aceptar()
{
    global $xoopsDB;
    $ids = isset($_GET['ids']) ? $_GET['ids'] : 0;
    if ($ids <= 0) {
        header('location: downs.php?op=new');
        die;
    }
    $tbl = $xoopsDB->prefix("rmdp_sended");
    $result = $xoopsDB->query("SELECT * FROM {$tbl} WHERE id_send='{$ids}'");
    $num = $xoopsDB->getRowsNum($result);
    /**
     * Si no encontramos la descarga redirigimos a otro lugar
     */
    if ($num <= 0) {
        redirect_header('sended.php', 2, _AM_RMDP_ERRNOEXIST);
        die;
    }
    $row = $xoopsDB->fetchArray($result);
    xoops_cp_header();
    include 'functions.php';
    include XOOPS_ROOT_PATH . "/include/xoopscodes.php";
    DP_ShowNav();
    echo "<table width='100%'  border='0' cellpadding='0' cellspacing='1' class='outer'>\n  \t\t\t<tr align='left'>\n    \t\t<th colspan='2'>" . _AM_RMDP_ACEPT . "</th>\n  \t\t\t</tr>\n  \t\t\t<form name='frmNew' method='post' action='modified.php?op=save'>\n  \t\t\t<tr>\n    \t\t<td class='even'>" . _AM_RMDP_FNAME . "</td>\n    \t\t<td class='odd'><input value='{$row['nombre']}' name='nombre' type='text' id='nombre' size='30' maxlength='200'></td>\n  \t\t\t</tr>\n  \t\t\t<tr>\n    \t\t<td class='even'>" . _AM_RMDP_FVERSION . "</td>\n    \t\t<td class='odd'><input value='{$row['version']}' name='version' type='text' id='version' size='30' maxlength='10'></td>\n  \t\t\t</tr>\n  \t\t\t<tr>\n    \t\t<td class='even'>" . _AM_RMDP_FLICENSE . "</td>\n    \t\t<td class='odd'><select name='licencia' id='licencia'>\n\t\t\t<option value='0'>Nenhuma</option>";
    $result = $xoopsDB->query("SELECT * FROM " . $xoopsDB->prefix('rmdp_licences') . " ORDER BY nombre");
    while ($rw = $xoopsDB->fetchArray($result)) {
        echo "<option value='{$rw['id_lic']}'";
        if ($rw['id_lic'] == $row['licencia']) {
            echo "selected";
        }
        echo ">{$rw['nombre']}</option>";
    }
    echo "  </select></td>\n  \t\t\t</tr>\n  \t\t\t<tr>\n    \t\t<td class='even'>" . _AM_RMDP_FFILE . "</td>\n    \t\t<td class='odd'><input value='{$row['archivo']}' name='archivo' type='text' id='archivo' size='30' maxlength='255'></td>\n  \t\t\t</tr>\n  \t\t\t<tr>\n    \t\t<td class='even'>" . _AM_RMDP_FIMG . "</td>\n    \t\t<td class='odd'><input value='{$row['img']}' name='img' type='text' id='img' size='30' maxlength='255'></td>\n  \t\t\t</tr>\n  \t\t\t<tr>\n    \t\t<td class='even'>" . _AM_RMDP_FCATEGO . "</td>\n    \t\t<td class='odd'><select name='idc' id='idc'>\n      \t\t<option value='0' selected>" . _AM_RMDP_SELECT . "</option>";
    DP_ChildCategoOption(0, 0, $row['id_cat']);
    echo "\t</select></td>\n  \t\t\t</tr><tr><td class='even'>" . _AM_RMDP_FLONG . "</td>\n    \t\t<td class='odd'>";
    $GLOBALS['longdesc'] = $row['longdesc'];
    xoopsCodeTarea("longdesc", 20, 15);
    xoopsSmilies("longdesc");
    echo "  </td>\n  \t\t\t</tr>\n  \t\t\t<tr>\n    \t\t<td class='even'>" . _AM_RMDP_FSIZE . "</td>\n    \t\t<td class='odd'><input value='{$row['size']}' name='size' type='text' id='size' size='30' maxlength='20'></td>\n  \t\t\t</tr>\n  \t\t\t<tr>\n    \t\t<td class='even'>" . _AM_RMDP_FFAVS . "</td>\n    \t\t<td class='odd'><input name='favorito' type='radio' value='1' ";
    if ($row['favorito']) {
        echo "checked";
    }
    echo "> \n      \t\t" . _AM_RMDP_YES . "\n        \t<input name='favorito' type='radio' value='0' ";
    if ($row['favorito'] == 0) {
        echo "checked";
    }
    echo "> \n      \t\t" . _AM_RMDP_NO . "</td>\n  \t\t\t</tr>\n  \t\t\t<tr>\n    \t\t<td class='even'>" . _AM_RMDP_FALLOWANONIM . "</td>\n    \t\t<td class='odd'><input name='anonimo' type='radio' value='1' ";
    if ($row['anonimo']) {
        echo "checked";
    }
    echo ">\n  \t\t\t" . _AM_RMDP_YES . "\n  \t\t\t<input name='anonimo' type='radio' value='0' ";
    if ($row['anonimo'] == 0) {
        echo "checked";
    }
    echo ">\n  \t\t\t" . _AM_RMDP_NO . "</td>\n  \t\t\t</tr>\n\t\t\t<tr>\n    \t\t<td class='even'>" . _AM_RMDP_RATING . "</td>\n    \t\t<td class='odd'>\n\t\t\t<select name='rating'>";
    for ($i = 0; $i <= 5; $i++) {
        if ($i == $row['calificacion']) {
            echo "<option value='{$i}' selected>{$i}</option>";
        } else {
            echo "<option value='{$i}'>{$i}</option>";
        }
    }
    echo "  </select></td></tr>\n  \t\t\t<tr><td class='even'>" . _AM_RMDP_FRESALTE . "</td>\n    \t\t<td class='odd'><input name='resaltar' type='radio' value='1' ";
    if ($row['resaltar']) {
        echo "checked";
    }
    echo "> " . _AM_RMDP_YES . "\n\t\t\t<input name='resaltar' type='radio' value='0' ";
    if ($row['resaltar'] == 0) {
        echo "checked";
    }
    echo "> " . _AM_RMDP_NO . "</td></tr>\n\t\t\t<tr><td class='even'>" . _AM_RMDP_FURLTITLE . "</td>\n    \t\t<td class='odd'><input value='{$row['urltitle']}' name='urltitle' type='text' id='url' size='30' maxlength='255'></td>\n  \t\t\t<tr><td class='even'>" . _AM_RMDP_FURL . "</td>\n    \t\t<td class='odd'><input value='{$row['url']}' name='url' type='text' id='url' size='30' maxlength='255'></td>\n \t\t\t</tr><tr><td class='even'>" . _AM_RMDP_SENDBY . "</td>\n    \t\t<td class='odd'><select name='idu'>";
    $result = $xoopsDB->query("SELECT uid, uname FROM " . $xoopsDB->prefix('users') . " ORDER BY uname");
    while ($rw = $xoopsDB->fetchArray($result)) {
        echo "<option value='{$rw['uid']}' ";
        if ($rw['uid'] == $row['submitter']) {
            echo "selected";
        }
        echo ">{$rw['uname']}</option>";
    }
    echo "  </select></td>\n \t\t\t</tr>\n\t\t\t<tr><td class='even' align='left'>" . _AM_RMDP_OSS . "</td>\n\t\t\t<td class='odd' align='left'>";
    $plats = explode("|", $row['plataformas']);
    foreach ($plats as $value) {
        echo "<input type='hidden' name='os[]' value='{$value}'>";
        echo DP_OsName($value) . "&nbsp;&nbsp;|&nbsp;&nbsp;";
    }
    echo "  </td></tr>\n\t\t\t<tr><td class='even'>&nbsp;<input type='hidden' name='id_soft' value='{$row['ids']}'></td>\n    \t\t<td class='odd'><input type='submit' name='Submit' value='" . _AM_RMDP_SAVE . "'></td>\n  \t\t\t</tr><input type='hidden' name='ids' value='{$ids}'></form></table>";
    xoops_cp_footer();
}
开发者ID:BackupTheBerlios,项目名称:soopa,代码行数:88,代码来源:modified.php


示例8: reviews

function reviews()
{
    global $xoopsDB;
    $ids = isset($_GET['ids']) ? $_GET['ids'] : 0;
    if ($ids <= 0) {
        header('location: downs.php');
        die;
    }
    include 'functions.php';
    include XOOPS_ROOT_PATH . "/include/xoopscodes.php";
    xoops_cp_header();
    DP_ShowNav();
    echo "<table width='100%' cellspacing='1' class='outer'>\n\t\t\t<tr><th colspan='2'>" . _AM_RMDP_REVIEWTITLE . "</th></tr>\n\t\t\t<form name='frmRev' method='post' action='downs.php'>\n\t\t\t<tr><td class='even' align='left'>" . _AM_RMDP_SHOTDOWN . "</td>\n\t\t\t<td class='odd' align='left'><strong>" . DP_DownloadName($ids) . "</strong></td>\n\t\t\t</tr><tr align='left'><td class='even'>" . _AM_RMDP_REVIEW . "</td>\n\t\t\t<td class='odd'>\n\t\t\t";
    list($text) = $xoopsDB->fetchRow($xoopsDB->query("SELECT text FROM " . $xoopsDB->prefix('rmdp_editorcom') . " WHERE id_soft='{$ids}'"));
    $GLOBALS['text'] = $text;
    xoopsCodeTarea("text", 20, 15);
    xoopsSmilies("text");
    echo "</td></tr>\n\t\t  <tr align='left'><td class='even'>" . _AM_RMDP_RATING . "</td>\n\t\t  <td class='odd'><select name='rate'>";
    list($rate) = $xoopsDB->fetchRow($xoopsDB->query("SELECT calificacion FROM " . $xoopsDB->prefix('rmdp_software') . " WHERE id_soft='{$ids}'"));
    for ($i = 1; $i <= 5; $i++) {
        if ($i == $rate) {
            echo "<option value='{$i}' selected>{$i}</option>";
        } else {
            echo "<option value='{$i}'>{$i}</option>";
        }
    }
    echo "</td></tr>\n\t\t  <tr align='left'><td class='even'>&nbsp;</td>\n\t\t  <td class='odd'><input type='submit' name='sbt' value='" . _AM_RMDP_MODIFY . "'>\n\t\t  <input type='hidden' name='op' value='savereview'>\n\t\t  <input type='hidden' name='ids' value='{$ids}'></td></tr></form></table>";
    xoops_cp_footer();
}
开发者ID:BackupTheBerlios,项目名称:soopa,代码行数:29,代码来源:downs.php


示例9: modLink

function modLink()
{
    global $xoopsDB, $myts, $eh, $mytree, $xoopsConfig;
    $linkimg_array = XoopsLists::getImgListAsArray(XOOPS_ROOT_PATH . "/modules/mylinks/images/shots/");
    $lid = $_GET['lid'];
    xoops_cp_header();
    echo "<h4>" . _MD_WEBLINKSCONF . "</h4>";
    echo "<table width='100%' border='0' cellspacing='1' class='outer'>" . "<tr class=\"odd\"><td>";
    $result = $xoopsDB->query("select cid, title, url, logourl from " . $xoopsDB->prefix("mylinks_links") . " where lid={$lid}") or $eh->show("0013");
    echo "<h4>" . _MD_MODLINK . "</h4><br />";
    list($cid, $title, $url, $logourl) = $xoopsDB->fetchRow($result);
    $title = $myts->makeTboxData4Edit($title);
    $url = $myts->makeTboxData4Edit($url);
    //      $url = urldecode($url);
    $logourl = $myts->makeTboxData4Edit($logourl);
    //      $logourl = urldecode($logourl);
    $result2 = $xoopsDB->query("select description from " . $xoopsDB->prefix("mylinks_text") . " where lid={$lid}");
    list($description) = $xoopsDB->fetchRow($result2);
    $GLOBALS['description'] = $myts->makeTareaData4Edit($description);
    echo "<table>";
    echo "<form method='post' action='index.php'>";
    echo "<tr><td>" . _MD_LINKID . "</td><td><b>{$lid}</b></td></tr>";
    echo "<tr><td>" . _MD_SITETITLE . "</td><td><input type='text' name='title' value=\"{$title}\" size='50' maxlength='100' /></td></tr>\n";
    echo "<tr><td>" . _MD_SITEURL . "</td><td><input type='text' name='url' value=\"{$url}\" size='50' maxlength='250' /></td></tr>\n";
    echo "<tr><td valign=\"top\">" . _MD_DESCRIPTIONC . "</td><td>";
    xoopsCodeTarea("description", 60, 8);
    xoopsSmilies("description");
    //echo "<textarea name=description cols=60 rows=5>$description</textarea>";
    echo "</td></tr>";
    echo "<tr><td>" . _MD_CATEGORYC . "</td><td>";
    $mytree->makeMySelBox("title", "title", $cid);
    echo "</td></tr>\n";
    echo "<tr><td>" . _MD_SHOTIMAGE . "</td><td>";
    //echo "<input type=text name=logourl value=\"$logourl\" size=\"50\" maxlength=\"60\"></input>
    echo "<select size='1' name='logourl'>";
    echo "<option value=' '>------</option>";
    foreach ($linkimg_array as $image) {
        if ($image == $logourl) {
            $opt_selected = "selected='selected'";
        } else {
            $opt_selected = "";
        }
        echo "<option value='" . $image . "' {$opt_selected}>" . $image . "</option>";
    }
    echo "</select>";
    echo "</td></tr>\n";
    $shotdir = "<b>" . XOOPS_URL . "/modules/mylinks/images/shots/</b>";
    echo "<tr><td></td><td>";
    printf(_MD_SHOTMUST, $shotdir);
    echo "</td></tr>\n";
    echo "</table>";
    echo "<br /><br /><input type='hidden' name='lid' value='{$lid}' />\n";
    echo "<input type='hidden' name='op' value='modLinkS' /><input type='submit' value='" . _MD_MODIFY . "' />";
    echo "</form>\n";
    echo "<table><tr><td>\n";
    echo myTextForm("index.php?op=delLink&amp;lid=" . $lid, _MD_DELETE);
    echo "</td><td>\n";
    echo myTextForm("index.php?op=linksConfigMenu", _MD_CANCEL);
    echo "</td></tr></table>\n";
    echo "<hr />";
    $result5 = $xoopsDB->query("SELECT count(*) FROM " . $xoopsDB->prefix("mylinks_votedata") . " WHERE lid = {$lid}");
    list($totalvotes) = $xoopsDB->fetchRow($result5);
    echo "<table width='100%'>\n";
    echo "<tr><td colspan='7'><b>";
    printf(_MD_TOTALVOTES, $totalvotes);
    echo "</b><br /><br /></td></tr>\n";
    // Show Registered Users Votes
    $result5 = $xoopsDB->query("SELECT ratingid, ratinguser, rating, ratinghostname, ratingtimestamp FROM " . $xoopsDB->prefix("mylinks_votedata") . " WHERE lid = {$lid} AND ratinguser >0 ORDER BY ratingtimestamp DESC");
    $votes = $xoopsDB->getRowsNum($result5);
    echo "<tr><td colspan='7'><br /><br /><b>";
    printf(_MD_USERTOTALVOTES, $votes);
    echo "</b><br /><br /></td></tr>\n";
    echo "<tr><td><b>" . _MD_USER . "  </b></td><td><b>" . _MD_IP . "  </b></td><td><b>" . _MD_RATING . "  </b></td><td><b>" . _MD_USERAVG . "  </b></td><td><b>" . _MD_TOTALRATE . "  </b></td><td><b>" . _MD_DATE . "  </b></td><td align=\"center\"><b>" . _MD_DELETE . "</b></td></tr>\n";
    if ($votes == 0) {
        echo "<tr><td align=\"center\" colspan=\"7\">" . _MD_NOREGVOTES . "<br /></td></tr>\n";
    }
    $x = 0;
    $colorswitch = "dddddd";
    while (list($ratingid, $ratinguser, $rating, $ratinghostname, $ratingtimestamp) = $xoopsDB->fetchRow($result5)) {
        //  $ratingtimestamp = formatTimestamp($ratingtimestamp);
        //Individual user information
        $result2 = $xoopsDB->query("SELECT rating FROM " . $xoopsDB->prefix("mylinks_votedata") . " WHERE ratinguser = '{$ratinguser}'");
        $uservotes = $xoopsDB->getRowsNum($result2);
        $useravgrating = 0;
        while (list($rating2) = $xoopsDB->fetchRow($result2)) {
            $useravgrating = $useravgrating + $rating2;
        }
        $useravgrating = $useravgrating / $uservotes;
        $useravgrating = number_format($useravgrating, 1);
        $ratingusername = XoopsUser::getUnameFromId($ratinguser);
        echo "<tr><td bgcolor=\"" . $colorswitch . "\">" . $ratingusername . "</td><td bgcolor=\"{$colorswitch}\">" . $ratinghostname . "</td><td bgcolor=\"{$colorswitch}\">{$rating}</td><td bgcolor=\"{$colorswitch}\">" . $useravgrating . "</td><td bgcolor=\"{$colorswitch}\">" . $uservotes . "</td><td bgcolor=\"{$colorswitch}\">" . $ratingtimestamp . "</td><td bgcolor=\"{$colorswitch}\" align=\"center\"><b>" . myTextForm("index.php?op=delVote&amp;lid={$lid}&amp;rid={$ratingid}", "X") . "</b></td></tr>\n";
        $x++;
        if ($colorswitch == "dddddd") {
            $colorswitch = "ffffff";
        } else {
            $colorswitch = "dddddd";
        }
    }
    // Show Unregistered Users Votes
    $result5 = $xoopsDB->query("SELECT ratingid, rating, ratinghostname, ratingtimestamp FROM " . $xoopsDB->prefix("mylinks_votedata") . " WHERE lid = {$lid} AND ratinguser = 0 ORDER BY ratingtimestamp DESC");
//.........这里部分代码省略.........
开发者ID:koki-h,项目名称:xoops_utf8,代码行数:101,代码来源:index.php


示例10: foreach

            $subject = $pm->getVar('subject', 'E');
            //TODO Fix harcoded string
            if (!preg_match('/^' . _RE . '/i', $subject)) {
                $subject = _RE . ' ' . $subject;
            }
            echo "<td class='even'><input type='text' name='subject' value='" . $subject . "' size='30' maxlength='100' /></td>";
        } else {
            echo "<td class='even'><input type='text' name='subject' size='30' maxlength='100' /></td>";
        }
        echo '</tr>';
        echo '<tr>';
        echo "<td class='head txtright' style='width:25%;'>" . _MESSAGEICON . '</td>';
        foreach ($subject_icons as $iconfile) {
            $icons_radio->addOption($iconfile, '<img src="' . XOOPS_URL . '/images/subject/' . $iconfile . '" alt="" />');
        }
        echo "<td class='even'>" . $icons_radio->render();
        echo '</td>';
        echo '</tr>';
        echo "<tr style='vertical-align:top;'><td style='width:25%;' class='head txtright'>" . _PM_MESSAGEC . '</td>';
        echo "<td class='even'>";
        xoopsCodeTarea('message', 37, 8);
        xoopsSmilies('message');
        echo '</td>';
        echo '</tr>';
        echo "<tr><td class='head'>&nbsp;</td><td class='even'>\n        <input type='hidden' name='op' value='submit' />" . $GLOBALS['xoopsSecurity']->getTokenHTML() . "\n        <input type='submit' class='formButton' name='submit' value='" . _PM_SUBMIT . "' />&nbsp;\n        <input type='reset' class='formButton' value='" . _PM_CLEAR . "' />\n        &nbsp;<input type='button' class='formButton' name='cancel' value='" . _PM_CANCELSEND . "' onclick='window.close();' />\n        </td></tr></table>\n";
        echo "</form>\n";
    }
} else {
    echo _PM_SORRY . "<br><br><a href='" . XOOPS_URL . "/register.php' title=''>" . _PM_REGISTERNOW . '</a>.';
}
xoops_footer();
开发者ID:geekwright,项目名称:XoopsCore25,代码行数:31,代码来源:pmlite.php


示例11: modDownload

function modDownload()
{
    global $xoopsDB, $myts, $eh, $mytree;
    $downimg_array = XoopsLists::getImgListAsArray(XOOPS_ROOT_PATH . "/modules/mydownloads/images/shots/");
    $lid = $_GET['lid'];
    xoops_cp_header();
    echo "<h4>" . _MD_DLCONF . "</h4>";
    echo "<table width='100%' border='0' cellspacing='1' class='outer'>" . "<tr class=\"odd\"><td>";
    $result = $xoopsDB->query("SELECT cid, title, url, homepage, version, size, platform, logourl FROM " . $xoopsDB->prefix("mydownloads_downloads") . " WHERE lid={$lid}") or $eh->show("0013");
    echo "<h4>" . _MD_MODDL . "</h4><br />";
    list($cid, $title, $url, $homepage, $version, $size, $platform, $logourl) = $xoopsDB->fetchRow($result);
    $title = $myts->makeTboxData4Edit($title);
    $url = $myts->makeTboxData4Edit($url);
    $homepage = $myts->makeTboxData4Edit($homepage);
    $version = $myts->makeTboxData4Edit($version);
    $size = $myts->makeTboxData4Edit($size);
    $platform = $myts->makeTboxData4Edit($platform);
    $logourl = $myts->makeTboxData4Edit($logourl);
    $result2 = $xoopsDB->query("SELECT description FROM " . $xoopsDB->prefix("mydownloads_text") . " WHERE lid={$lid}");
    list($description) = $xoopsDB->fetchRow($result2);
    $GLOBALS['description'] = $myts->makeTareaData4Edit($description);
    echo "<table>";
    echo "<form method='post' action='index.php'>";
    echo "<tr><td>" . _MD_FILEID . "</td><td><b>{$lid}</b></td></tr>";
    echo "<tr><td>" . _MD_FILETITLE . "</td><td><input type='text' name='title' value='{$title}' size='50' maxlength='100' /></input></td></tr>\n";
    echo "<tr><td>" . _MD_DLURL . "</td><td><input type='text' name='url' value='{$url}' size='50' maxlength='250' /></td></tr>\n";
    echo "<tr><td>" . _MD_HOMEPAGEC . "</td><td><input type='text' name='homepage' value='{$homepage}' size='50' maxlength='100' /></td></tr>\n";
    echo "<tr><td>" . _MD_VERSIONC . "</td><td><input type='text' name='version' value='{$version}' size='10' maxlength='10' /></td></tr>\n";
    echo "<tr><td>" . _MD_FILESIZEC . "</td><td><input type='text' name='size' value='{$size}' size='10' maxlength='100' />" . _MD_BYTES . "</td></tr>\n";
    echo "<tr><td>" . _MD_PLATFORMC . "</td><td><input type='text' name='platform' value='{$platform}' size='45' maxlength='60' /></td></tr>\n";
    echo "<tr><td valign=\"top\">" . _MD_DESCRIPTIONC . "</td><td>";
    xoopsCodeTarea("description", 60, 8);
    xoopsSmilies("description");
    echo "</td></tr>";
    echo "<tr><td>" . _MD_CATEGORYC . "</td><td>";
    $mytree->makeMySelBox("title", "title", $cid);
    echo "</td></tr>\n";
    echo "<tr><td>" . _MD_SHOTIMAGE . "</td><td>";
    //echo "<input type=text name=logourl value=\"$logourl\" size=\"50\" maxlength=\"60\"></input>";
    echo "<select size='1' name='logourl'>";
    echo "<option value=' '>------</option>";
    foreach ($downimg_array as $image) {
        if ($image == $logourl) {
            $opt_selected = "selected='selected'";
        } else {
            $opt_selected = "";
        }
        echo "<option value='" . $image . "' {$opt_selected}>" . $image . "</option>";
    }
    echo "</select>";
    echo "</td></tr>\n";
    echo "<tr><td></td><td>";
    $directory = XOOPS_URL . "/modules/mydownloads/images/shots/";
    printf(_MD_MUSTBEVALID, $directory);
    echo "</td></tr>\n";
    echo "</table>";
    echo "<br /><br /><input type='hidden' name='lid' value='{$lid}' />\n";
    echo "<input type='hidden' name='op' value='modDownloadS' /><input type='submit' value='" . _MD_SUBMIT . "' />";
    echo "</form>\n";
    echo "<table><tr><td>\n";
    echo myTextForm("index.php?op=delDownload&amp;lid=" . $lid, _MD_DELETE);
    echo "</td><td>\n";
    echo myTextForm("index.php?op=downloadsConfigMenu", _MD_CANCEL);
    echo "</td></tr></table>\n";
    echo "<hr />";
    $result5 = $xoopsDB->query("SELECT COUNT(*) FROM " . $xoopsDB->prefix("mydownloads_votedata") . "");
    list($totalvotes) = $xoopsDB->getRowsNum($result5);
    echo "<table width='100%'>\n";
    echo "<tr><td colspan='7'><b>";
    printf(_MD_DLRATINGS, $totalvotes);
    echo "</b><br /><br /></td></tr>\n";
    // Show Registered Users Votes
    $result5 = $xoopsDB->query("SELECT ratingid, ratinguser, rating, ratinghostname, ratingtimestamp FROM " . $xoopsDB->prefix("mydownloads_votedata") . " WHERE lid = {$lid} AND ratinguser != 0 ORDER BY ratingtimestamp DESC");
    $votes = $xoopsDB->getRowsNum($result5);
    echo "<tr><td colspan='7'><br /><br /><b>";
    printf(_MD_REGUSERVOTES, $votes);
    echo "</b><br /><br /></td></tr>\n";
    echo "<tr><td><b>" . _MD_USER . "  </b></td><td><b>" . _MD_IP . "  </b></td><td><b>" . _MD_RATING . "  </b></td><td><b>" . _MD_USERAVG . "  </b></td><td><b>" . _MD_TOTALRATE . "  </b></td><td><b>" . _MD_DATE . "  </b></td><td align=\"center\"><b>" . _MD_DELETE . "</b></td></tr>\n";
    if ($votes == 0) {
        echo "<tr><td align=\"center\" colspan=\"7\">" . _MD_NOREGVOTES . "<br /></td></tr>\n";
    }
    $x = 0;
    $colorswitch = "dddddd";
    while (list($ratingid, $ratinguser, $rating, $ratinghostname, $ratingtimestamp) = $xoopsDB->fetchRow($result5)) {
        $formatted_date = formatTimestamp($ratingtimestamp);
        //Individual user information
        $result2 = $xoopsDB->query("SELECT rating FROM " . $xoopsDB->prefix("mydownloads_votedata") . " WHERE ratinguser = {$ratinguser}");
        $uservotes = $xoopsDB->getRowsNum($result2);
        $useravgrating = 0;
        while (list($rating2) = $xoopsDB->fetchRow($result2)) {
            $useravgrating = $useravgrating + $rating2;
        }
        $useravgrating = $useravgrating / $uservotes;
        $useravgrating = number_format($useravgrating, 1);
        $ratinguname = XoopsUser::getUnameFromId($ratinguser);
        // echo "<tr><td bgcolor=\"$colorswitch\">$ratinguname</td><td bgcolor=\"$colorswitch\">$ratinghostname</td><td bgcolor=\"$colorswitch\">$rating</td><td bgcolor=\"$colorswitch\">$useravgrating</td><td bgcolor=\"$colorswitch\">$uservotes</td><td bgcolor=\"$colorswitch\">$formatted_date</td><td bgcolor=\"$colorswitch\" align=\"center\"><b><a href=index.php?op=delVote&amp;lid=$lid&amp;rid=$ratingid>X</a></b></td></tr>\n";
        // echo "<tr><td bgcolor=\"$colorswitch\">$ratinguname</td><td bgcolor=\"$colorswitch\">$ratinghostname</td><td bgcolor=\"$colorswitch\">$rating</td><td bgcolor=\"$colorswitch\">$useravgrating</td><td bgcolor=\"$colorswitch\">$uservotes</td><td bgcolor=\"$colorswitch\">$formatted_date</td><td bgcolor=\"$colorswitch\" align=\"center\">";
        echo "<tr><td bgcolor=\"{$colorswitch}\">{$ratinguname}</td><td bgcolor=\"{$colorswitch}\">{$ratinghostname}</td><td bgcolor=\"{$colorswitch}\">{$rating}</td><td bgcolor=\"{$colorswitch}\">{$useravgrating}</td><td bgcolor=\"{$colorswitch}\">{$uservotes}</td><td bgcolor=\"{$colorswitch}\">{$formatted_date}</td><td bgcolor=\"{$colorswitch}\" align=\"center\">";
        //echo "<table><tr><td>\n";
        echo myTextForm("index.php?op=delVote&amp;lid={$lid}&amp;rid={$ratingid}", "X");
//.........这里部分代码省略.........
开发者ID:koki-h,项目名称:xoops_utf8,代码行数:101,代码来源:index.php


示例12: while

$xoopsTpl->assign('user1', $xoopsModuleConfig['user_field1_name']);
$xoopsTpl->assign('user2', $xoopsModuleConfig['user_field2_name']);
$xoopsTpl->assign('user3', $xoopsModuleConfig['user_field3_name']);
$xoopsTpl->assign('user4', $xoopsModuleConfig['user_field4_name']);
while ($CURRENT_PIC = $xoopsDB->fetchArray($result)) {
    if (USER_IS_ADMIN) {
        get_user_albums($CURRENT_PIC['owner_id']);
        //   $admin_mode=1;
    }
    //else $admin_mode=0;
    //$form.=create_form($data);
    form_alb_list_box();
    form_pic_info();
    ob_start();
    $GLOBALS["caption{$CURRENT_PIC['pid']}"] = $myts->makeTareaData4Edit($CURRENT_PIC['caption']);
    xoopsCodeTarea("caption{$CURRENT_PIC['pid']}", 37, 8);
    $xoops_codes = ob_get_contents();
    ob_end_clean();
    ob_start();
    xoopsSmilies("caption" . $CURRENT_PIC['pid']);
    $smilies = ob_get_contents();
    ob_end_clean();
    $value_field1 = $myts->makeTboxData4Edit($CURRENT_PIC['user1']);
    $name_field1 = 'user1' . $CURRENT_PIC['pid'];
    $value_field2 = $myts->makeTboxData4Edit($CURRENT_PIC['user2']);
    $name_field2 = 'user2' . $CURRENT_PIC['pid'];
    $value_field3 = $myts->makeTboxData4Edit($CURRENT_PIC['user3']);
    $name_field3 = 'user3' . $CURRENT_PIC['pid'];
    $value_field4 = $myts->makeTboxData4Edit($CURRENT_PIC['user4']);
    $name_field4 = 'user4' . $CURRENT_PIC['pid'];
    form_options();
开发者ID:severnaya99,项目名称:Sg-2010,代码行数:31,代码来源:editpics.php


示例13: Modify

function Modify()
{
    global $xoopsDB;
    $idc = $_GET['idc'];
    if ($idc <= 0) {
        header('location: categos.php');
        die;
    }
    xoops_cp_header();
    include XOOPS_ROOT_PATH . "/include/xoopscodes.php";
    include_once XOOPS_ROOT_PATH . "/class/xoopslists.php";
    include_once 'functions.php';
    ShowNav();
    $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);
    echo "<table width='100%' class='outer' cellspacing='1'>\n\n\t\t\t<tr><th colspan='2'>" . _AM_MODIFYFORM . "</th></tr>\n\n\t\t\t<form name='frm' method='post' action='categos.php'>\n\n\t\t\t<tr><td class='even' align='left'>" . _AM_FORMNAME . "</td>\n\n\t\t\t<td align='left' class='odd'><input value='{$row['nombre']}' type='text' name='nombre' size='30'></td></tr>\n\n\t\t\t<tr><td class='even' align='left'>" . _AM_FORMIMG . "</td>\n\n\t\t\t<td align='left' class='odd'>\n\n\t\t\t<select name='img'><option value=''>--</option>\n";
    $imgArray = XoopsLists::getImgListAsArray(XOOPS_ROOT_PATH . "/modules/rmservices/images/categos/");
    foreach ($imgArray as $image) {
        if ($row['img'] == $image) {
            echo "<option value='" . $image . "' selected>" . $image . "</option>";
        } else {
            echo "<option value='" . $image . "'>" . $image . "</option>";
        }
    }
    echo "  </select><br>\n\t\t\t<span style='font-size: 9px;'>" . _AM_INFOIMG . "</span></td></tr>\n\n\t\t\t<tr><td class='even' align='left'>" . _AM_DESC . "</td>\n\n\t\t\t<td align='left' class='odd'>";
    $GLOBALS['desc'] = $row['desc'];
    xoopsCodeTarea("desc", 20, 15);
    xoopsSmilies("desc");
    echo "  </td></tr>\n\n\t        <tr><td align='left' class='even'>&nbsp;</td>\n\n\t\t\t<td class='odd' align='left'><input type='submit' name='sbt' value='" . _AM_SEND . "'></td>\n\t\t\t<input type='hidden' name='op' value='savemod'>\n\n\t\t\t<input type='hidden' name='idc' value='{$idc}'>\n\n\t\t\t</tr></form></table>";
    xoops_cp_footer();
}
开发者ID:BackupTheBerlios,项目名称:soopa,代码行数:36,代码来源:categos.php


示例14: ob_start

该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP xoopsSmilies函数代码示例发布时间:2022-05-23
下一篇:
PHP xoonips_getutility函数代码示例发布时间:2022-05-23
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap