Moin!
Nachtrag: Warum machst Du nicht einfach:
htmlcode = htmlcode.replace(/<(/?b)>/gim, "[$1]");
Das kannst Du dann gleich erweitern auf:
htmlcode = htmlcode.replace(/<(/?(?:b|u|font\b[^>]*))>/gim, "[$1]");
usw...
-- Skeeve
Moin!
Nachtrag: Warum machst Du nicht einfach:
htmlcode = htmlcode.replace(/<(/?b)>/gim, "[$1]");
Das kannst Du dann gleich erweitern auf:
htmlcode = htmlcode.replace(/<(/?(?:b|u|font\b[^>]*))>/gim, "[$1]");
usw...
-- Skeeve