In theory, a script would run something like this:
code:
Search for the following string: "| Session Start:"
search for string for next occurrence of: ".--------------------------------------------------------------------."
if number of lines between these strings > 2 then ignore (as multi conversations will be much harder to convert)
else, detect your username from first line by searching for an email and store as $localuser
detect recipient username from second line by searching for an email and store as $recipientuser
convert date from "Session Start:" to the YYYY-MM-DD format and store as $sessiondate
search for first time stamp from the first message ( [HH:MM:SS] ) strip the brackets and store as $sessionstart
Print the following into an html file
<html><head><title>Conversation with $recepientuser at $sessiondate $sessionstart on $localuser (msn)</title></head><body><h3>Conversation with $recepientuser at $sessiondate $sessionstart on $localuser (msn)</h3>
Next, identify all unique screen names (aliases) from each line of the conversation and ask which username it refers to (as the text logs dont make it clear)
Then identify status messages ("user has changed their name to" or "user has gone offline") by looking for messages starting with a *
Format all local user messages with the following HTML:
<font color="#16569E"><font size="2">(TIMESTAMP)</font> <b>SCREEN NAME (TRUNCATED):</b></font> <font sml="MSN">CONVERSATION TEXT</font><br/>
Format all recipient messages with the following HTML:
<font color="#A82F2F"><font size="2">(TIMESTAMP)</font> <b>SCREEN NAME (TRUNCATED):</b></font> <font sml="MSN"><span style='font-family: High Tower Text; '><strong><span style='color: #ff0000; '>CONVERSATION TEXT</span></strong></span></font><br/>
Format all status message with the following HTML:
<font size="2">(TIMESTAMP)</font><b> SCREEN NAME (TRUNCATED). STATUS.</b><br/>
close the file with:
</body></html>
then save the file with the following date format: $recipientuser/YYYY-MM-DD.HHMMSS.html
But I have no idea how to code it!