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


PHP tag::copy_tag方法代码示例

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


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

示例1: daddslashes

    $thread['rate'] = $thread['displayorder'] = $thread['attachment'] = 0;
    $thread['typeid'] = $_GET['threadtypeid'];
    $thread = daddslashes($thread);
    $thread['posttableid'] = 0;
    $threadid = C::t('forum_thread')->insert($thread, true);
    if ($post = C::t('forum_post')->fetch_threadpost_by_tid_invisible($_G['tid'])) {
        $post['pid'] = '';
        $post['tid'] = $threadid;
        $post['fid'] = $copyto;
        $post['dateline'] = TIMESTAMP;
        $post['attachment'] = 0;
        $post['invisible'] = $post['rate'] = $post['ratetimes'] = 0;
        $post['message'] .= "\n" . lang('forum/thread', 'source') . ": [url=forum.php?mod=viewthread&tid={$sourcetid}]{$thread['subject']}[/url]";
        $post = daddslashes($post);
        $pid = insertpost($post);
    }
    $class_tag = new tag();
    $class_tag->copy_tag($_G['tid'], $threadid, 'tid');
    if ($typeoptionvar) {
        foreach ($typeoptionvar as $key => $value) {
            $value['tid'] = $threadid;
            $value['fid'] = $toforum['fid'];
            C::t('forum_typeoptionvar')->insert($value);
        }
    }
    updatepostcredits('+', $post['authorid'], 'post', $copyto);
    updateforumcount($copyto);
    updateforumcount($_G['fid']);
    $modpostsnum++;
    $resultarray = array('redirect' => "forum.php?mod=forumdisplay&fid={$_G['fid']}", 'reasonpm' => $sendreasonpm ? array('data' => array($thread), 'var' => 'thread', 'item' => 'reason_copy', 'notictype' => 'post') : array(), 'reasonvar' => array('tid' => $thread['tid'], 'subject' => $thread['subject'], 'modaction' => $modaction, 'reason' => $reason, 'threadid' => $threadid), 'modtids' => $thread['tid'], 'modlog' => array($thread, $other));
}
开发者ID:tang86,项目名称:discuz-utf8,代码行数:31,代码来源:topicadmin_copy.php


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