Buzzen Forum

Misc => IRC Scripters => Topic started by: g33k™ on March 09, 2025, 12:07:29 am

Title: ircWx-Conn v2.2 input modification.
Post by: g33k™ on March 09, 2025, 12:07:29 am
I want to modify the theme code for input on subject line script, to capitalize the 1st letter of the sentence and replace words and "i" to "I" as well. This is what I have, is there a more modern way to achieve this?

on *:INPUT:#: {
  if ($Left($1, 1) != /) {
    var %Text = $Replacexcs($Regsubex($1-, /^([a-z])|\b(i)\b/g, $Upper(\t)), doesnt, doesn't, couldnt, couldn't, wouldnt, wouldn't, shouldnt, shouldn't, didnt, didn't, isnt, isn't, theyll, they'll, wasnt, wasn't, havent, haven't, dont, don't, thats, that's, cant, can't)

Thoughts?

Title: Re: ircWx-Conn v2.2 input modification.
Post by: err0r on March 09, 2025, 08:10:01 pm
The way you have it is probably the most modern way unless you want to get into sockets that will check using php for spelling or openai.