Regex 将图像调用到幻灯片中的正则表达式代码(MyBB)

Regex 将图像调用到幻灯片中的正则表达式代码(MyBB),regex,image,mybb,Regex,Image,Mybb,这里有人熟悉MyBB吗 我想在我之前在画廊幻灯片中选择的论坛中以一个线程显示所有图像 [img]*URL\u IMAGE\u文件*[/img] 滑块的一部分是一个滑块,我的意思如下。 其中:17和18有我选择的ID WHERE t.fid IN (17,18) AND t.visible='1' AND t.closed NOT LIKE 'moved|%' AND t.firstpost=p.pid 如果出现错误,请更正以下代码 // Slider Images /***** Slider

这里有人熟悉MyBB吗

我想在我之前在画廊幻灯片中选择的论坛中以一个线程显示所有图像

[img]*URL\u IMAGE\u文件*[/img]

滑块的一部分是一个滑块,我的意思如下。

其中:17和18有我选择的ID

WHERE t.fid IN (17,18) AND t.visible='1' AND t.closed NOT LIKE 'moved|%' AND t.firstpost=p.pid
如果出现错误,请更正以下代码

// Slider Images
/***** Slider Gallery Thread End *****/ 

 /* LATEST THREADS */

$query = $db->query("
       SELECT t.*, p.message, a.aid, a.thumbnail
       FROM ".TABLE_PREFIX."threads t
       LEFT JOIN ".TABLE_PREFIX."posts p ON (p.pid = t.firstpost)
       LEFT JOIN ".TABLE_PREFIX."attachments a ON(a.pid=p.pid)
       WHERE t.fid IN (17,18) AND t.visible='1' AND t.closed NOT LIKE 'moved|%' AND t.firstpost=p.pid
       ORDER BY t.dateline DESC
       LIMIT 1");

if(!$db->num_rows($query))

    {
        // Needs to output a nice "no posts here" box
        $title = 'Error';
        $message = 'No Message';

        eval("\$tricks = \"".$templates->get("member_profile_no_content")."\";");

    }
    else

    {
    // Set up the parser options.
    $parser_options = array(
        "allow_html" => $forum['allowhtml'],
        "allow_mycode" => $forum['allowmycode'],
        "allow_smilies" => $forum['allowsmilies'],
        "allow_imgcode" => $forum['allowimgcode'],
        "allow_videocode" => $forum['allowvideocode'],
         "filter_badwords" => 1
        );

    while($threads = $db->fetch_array($query))

        {
        $threads['threadlink'] = get_thread_link($threads['tid']);


        if($threads['lastposteruid'] == 0)

        {
            $lastposterlink = $threads['lastposter'];

        }
        else
        {
            $lastposterlink = build_profile_link($threads['lastposter'], $threads['lastposteruid']);

        }
        $view_string = 'Views';
        $reply_string = 'Replies';
        if($threads['views'] == 1)

        {
            $view_string = 'Views';

        }

        if($threads['replies'] == 1)

        {
            $reply_string = 'Replies';

        }

        if ($thread['thumbnail'])
        {
            $thumbnail = '<a href="'.$mybb->settings['bburl'].'/attachment.php?aid='.$aid.'" target=_blank><img src="./uploads/'.$thread['thumbnail'].'" alt="" title="" width="100%" height="100px"></a>';
        }
        else
        {
            $thumbnail = '';
        }

        $threads['profilelink'] = build_profile_link($threads['username'], $threads['uid']);
        $threads['reply'] = $lang->sprintf($lang->thread_views_stats, my_number_format($threads['replies']), $reply_string, my_number_format($threads['views']), $view_string);
        $threads['date'] = my_date($mybb->settings['dateformat'], $threads['dateline']);
        $threads['time'] = my_date($mybb->settings['timeformat'], $threads['dateline']);
        $threads['lastpostlink'] = get_thread_link($threads['tid'], 0, "lastpost");
        $threads['message'] = my_substr($threads['message'], 0, 150) . "...";
        $threads['message'] = $parser->parse_message($threads['message'], $options);
        eval("\$tricks .= \"".$templates->get("depan_slides")."\";");
    }
        }

/***** Slider Gallery Thread End *****/

@卢茨霍恩:没有错误。但是应该从线程中获取的图像文件没有显示。有什么可以帮助我的吗?