Spoilers and E-mail

Get the scoop on the changes happening here at CAA. You may also suggest changes or additions to the site and provide feedback about the board.

Spoilers and E-mail

Postby shooraijin » Sat Nov 08, 2003 11:44 pm

I'm not sure if it always had this problem, but spoilers sneak into the messages I get when new replies are added to threads (got a fairly significant one off the Matrix Revolutions thread, which was kind of a bummer ... :( ).
"you're a doctor.... and 27 years.... so...doctor + 27 years = HATORI SOHMA" - RoyalWing, when I was 27
"Al hail the forum editting Shooby! His vibes are law!" - Osaka-chan

I could still be champ, but I'd feel bad taking it away from one of the younger guys. - George Foreman
User avatar
shooraijin
 
Posts: 9922
Joined: Thu Jun 26, 2003 12:00 pm
Location: Southern California

Postby Straylight » Sun Nov 09, 2003 12:33 am

Just had a look at the email script and it's a jungle. Technically before the spoilers changed the problem should have still been there -- I don't think the emailer bothers to parse out tags. I'm gonna leave it as is for the moment because I have no idea how this script works. ;)
[align=center]
Image
Banner above created using my avatar generator tool.
You know you want try it.
User avatar
Straylight
 
Posts: 2346
Joined: Mon May 26, 2003 12:00 pm
Location: Manchester, UK

Postby shooraijin » Sun Nov 09, 2003 8:46 am

If it's in Perl (crosses fingers), or even if it's still PHP albeit with the Perl regular expressions package compiled in, something like this should work:

s/\[spoiler[^]]*\][^[]*\[\/spoiler[^]]*\]//sig;

However, I notice there are no vB code tags in the E-mails that are sent out anyway, so something must be pulling them.

Maybe you could piggyback on the code that yanks out quotations, since those definitely don't appear in the E-mail messages (which led to some private hilarity when I was unable to figure out the context of a few messages a while ago).
"you're a doctor.... and 27 years.... so...doctor + 27 years = HATORI SOHMA" - RoyalWing, when I was 27
"Al hail the forum editting Shooby! His vibes are law!" - Osaka-chan

I could still be champ, but I'd feel bad taking it away from one of the younger guys. - George Foreman
User avatar
shooraijin
 
Posts: 9922
Joined: Thu Jun 26, 2003 12:00 pm
Location: Southern California

Postby shooraijin » Sun Nov 09, 2003 8:47 am

... just realized it wouldn't work for escaped brackets inside vB code blocks, but you get the idea :)
"you're a doctor.... and 27 years.... so...doctor + 27 years = HATORI SOHMA" - RoyalWing, when I was 27
"Al hail the forum editting Shooby! His vibes are law!" - Osaka-chan

I could still be champ, but I'd feel bad taking it away from one of the younger guys. - George Foreman
User avatar
shooraijin
 
Posts: 9922
Joined: Thu Jun 26, 2003 12:00 pm
Location: Southern California

Postby Saint » Sun Nov 09, 2003 11:52 am

Yes, i can see how e-mail spoilers can be a problem. They have been like that even before the new spoiler method was up. Ash's post about the Matrix really caught my eye when i read that e-mail. I was like "I can't believe she just said that?!?" then you link to it and see its in a spoiler box... too bad for people who didn't know and read the e-mail.
We are saved by grace thru faith, not of works... "keep on fighting for grace"
User avatar
Saint
 
Posts: 538
Joined: Tue Jun 17, 2003 9:29 pm
Location: Alabama

Postby Straylight » Sun Nov 09, 2003 1:06 pm

Maybe you could piggyback on the code that yanks out quotations, since those definitely don't appear in the E-mail messages (which led to some private hilarity when I was unable to figure out the context of a few messages a while ago).


That would definatly be the best plan, however I can't actually find the code that removes quotes from emails. It's a total jungle -- each file has a set of includes and those includes can have more includes ... :stressed: :stressed: :stressed: Everything is written in php, and the email script doesn't contain any regular expressions at all.

I'll find it eventually.
[align=center]
Image
Banner above created using my avatar generator tool.
You know you want try it.
User avatar
Straylight
 
Posts: 2346
Joined: Mon May 26, 2003 12:00 pm
Location: Manchester, UK


Return to Announcements and Feedback

Who is online

Users browsing this forum: No registered users and 34 guests