DotBBS.Business/UBB.cs

(开头部分) 2KB

这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。

#region Usings
using System;
using System.Collections.Generic;
using System.Text;
using System.Text.RegularExpressions;
using System.Data;
using System.Web;
using System.Web.UI.WebControls;
using DotBBS.Data;
using DotBBS.Model;
using DotBBS.Common;
#endregion

//============================================================================
// 官方支持:DotBBS.Net   作者:吸铁石团队(水煮鱼)
//============================================================================
namespace DotBBS.Business
{
    public class UBB
    {
        static public string IconToImg(string input)
        {
            Regex reg = new Regex(@"\[[^]]+\]");
            MatchCollection mc = reg.Matches(input);
            if (mc.Count > 0)
            {
                for (int i = 0; i < mc.Count; i++)
                {
                    string icon = mc[i].Value;
                    if (icon.IndexOf("|") > -1)
                    {
                        string[] arr = icon.Split('|');
                        if (arr.Length > 0)
                        {
                            string img = "<img src=\"../DotBBS_Net/images/icons/" + arr[1] + "/"+arr[2].Replace("/]","")+"\"/>";
                            input = input.Replace(icon,img);
                        }
                    }
                }
            }

            return input;
        }

        static public string NoIcon(string input)
        {
            Regex reg = new Regex(@"\[[^]]+\]");
            MatchCollection mc = reg.Matches(input);
            if (mc.Count > 0)
            {
                for (int i = 0; i < mc.Count; i++)
                {
                    string icon = mc[i].Value;
                    input = input.Replace(icon,"");
                }
            }

            return input;
        }

后面还有 17 行代码,购买后查看完整代码

24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明

AI 解读 AI

登录后可用,每次 10 算力,解读结果公开显示在下面。

还没有人解读过这个文件。