Import java.util.regex. *;
/ / This method is used to resolve the use of the UBB's IMG expression method to HTML style, use the REGX package
Public Static String ConvertTags (String Str)
{
IF (str == null || str.length () == 0)
{
Return Str;
}
String Patt = "
// [img //]) ([^ // [] ) (// [/ IMG //]) ";
Pattern P = Pattern.Compile (Patt);
Matcher M = P.matcher (STR);
StringBuffer SB = new stringbuffer ();
INT i = 0;
Boolean Result = m.find ();
While (result)
{
i ;
M.AppendReplacement (SB, "");
Result = m.find ();
}
M.AppendTail (SB);
Return sb.toString ();
}