This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.


For more information, see this announcement post. Click the X in the top right-corner of this box to dismiss this message.

mIRC to HTML?

Old posts that have not been replied to for several years.
Locked
d
darkie
Voice
Posts: 20
Joined: Sun Feb 23, 2003 4:50 am

mIRC to HTML?

Post by darkie »

Has someone made a script to convert strings with mIRC colour codes into HTML? It's been done in mIRC, and I've heard it's been done in TCL, but I cannot find it? Has anybody done it or can somebody do it?

Thanx in advance
User avatar
GodOfSuicide
Master
Posts: 463
Joined: Mon Jun 17, 2002 8:00 pm
Location: Austria

Post by GodOfSuicide »

look @ the irc2html post, just some treads under yours
d
darkie
Voice
Posts: 20
Joined: Sun Feb 23, 2003 4:50 am

Post by darkie »

I need something that can convert strings with mIRC colour codes into HTML, changing colour codes into <font colour=xxxxxx>blah blah blah</font> is what I'm looking for here.
User avatar
GodOfSuicide
Master
Posts: 463
Joined: Mon Jun 17, 2002 8:00 pm
Location: Austria

Post by GodOfSuicide »

if i remember correct such code is in irc2html
d
darkie
Voice
Posts: 20
Joined: Sun Feb 23, 2003 4:50 am

Post by darkie »

GodOfSuicide wrote:if i remember correct such code is in irc2html
The closest I can see is code to strip mIRC colour codes, not converting them to HTML.

What I need is something that converts this: ♥3Hello☼ to, for example: <font colour="#009300">Hello</font>
p
ppslim
Revered One
Posts: 3914
Joined: Sun Sep 23, 2001 8:00 pm
Location: Liverpool, England

Post by ppslim »

I am looking for a way to do this now, however, it's not as easy as I first thought.

The problem with mIRC colour codes, they can take a while to parse in pure Tcl, using string commands. So I am looking to modify my eegexp for stripping, to extract the details, then convert it to a code.

Give me a few days, and I might have it.
User avatar
stdragon
Owner
Posts: 959
Joined: Sun Sep 23, 2001 8:00 pm
Contact:

Post by stdragon »

You can try this, I just wrote it. Not really tested.

http://stdarg.techmonkeys.org/egg/scrip ... o_html.tcl

It doesn't support background colors right now but it's not too hard to add. I guess the best way would be to <span style='background-color: blah; color: blah'>blah blah</span> right?
p
ppslim
Revered One
Posts: 3914
Joined: Sun Sep 23, 2001 8:00 pm
Location: Liverpool, England

Post by ppslim »

stdragon, I am guessing you are a Netscape monkey right?

DIV tages would be best
User avatar
stdragon
Owner
Posts: 959
Joined: Sun Sep 23, 2001 8:00 pm
Contact:

Post by stdragon »

I said span tags because div tags create line breaks and we need the background colors to be embedded within a line.
d
darkie
Voice
Posts: 20
Joined: Sun Feb 23, 2003 4:50 am

Post by darkie »

stdragon wrote:You can try this, I just wrote it. Not really tested.

http://stdarg.techmonkeys.org/egg/scrip ... o_html.tcl

It doesn't support background colors right now but it's not too hard to add. I guess the best way would be to <span style='background-color: blah; color: blah'>blah blah</span> right?
This looks good, would it be cool if I used this in my script? I wouldn't like to be using it without your permission, being the author and all.
p
ppslim
Revered One
Posts: 3914
Joined: Sun Sep 23, 2001 8:00 pm
Location: Liverpool, England

Post by ppslim »

Without stdragn replying, I can say yes to that.

THe whole idea behind a public forum, si that if information becomes available, and viewable byt he public, it becomes public domain, though there may be licence restrictions.

The only thing I can sugest, is you make a note in your script, who contributed code, and that anybody ripping your, must continue to note the contribution.

If you ever find code made public here, simply make a referance to the author.
d
darkie
Voice
Posts: 20
Joined: Sun Feb 23, 2003 4:50 am

Post by darkie »

To see this TCL script in action, go to http://www.splashirc.com/onchat.php
Locked