Page Index Toggle Pages: 1 ReplyAdd Poll Send Topic
Normal Topic Reply preview bug (Read 1599 times)
 
Paste Member Name in Quick Reply Box Monni
Language
***
Offline


Min izāmō

Posts: 413
Location: Kaarina, Finland
Joined: Jul 16th, 2014
Gender: Male
Mood: Frustrated
Zodiac sign: Pisces
Reply preview bug
Oct 22nd, 2014 at 4:53pm
Mark & QuoteQuote  
Preview shows up as "$3" instead of the real quoted text when replying to very long post.

For me is looks like it doesn't escape "|" before sending back...
  

reply.png ( 3 KB | 139 Downloads )
Back to top
IP Logged
 
Paste Member Name in Quick Reply Box Dandello
Forum Administrator
YaBB Modder
*****
Offline


I love YaBB 2.7!

Posts: 2234
Location: The Land of YaBB
Joined: Feb 12th, 2014
Gender: Female
Mood: Annoyed
Zodiac sign: Virgo
Re: Reply preview bug
Reply #1 - Oct 22nd, 2014 at 9:25pm
Mark & QuoteQuote  
All I can come up with is: if you're quoting code as long as your permitted characters, Yabb may truncate the '[/code]' or other end tags and that can really mess things up. (But I haven't been able to duplicate getting a '$3' rather than text or an error message. That '$3' will come from YaBBC.pm auto-formatting something.)
  

Perfection is not possible. Excellence, however, is excellent.
Back to top
WWW  
IP Logged
 
Paste Member Name in Quick Reply Box Monni
Language
***
Offline


Min izāmō

Posts: 413
Location: Kaarina, Finland
Joined: Jul 16th, 2014
Gender: Male
Mood: Frustrated
Zodiac sign: Pisces
Re: Reply preview bug
Reply #2 - Oct 23rd, 2014 at 3:53am
Mark & QuoteQuote  
Dandello wrote on Oct 22nd, 2014 at 9:25pm:
All I can come up with is: if you're quoting code as long as your permitted characters, Yabb may truncate the '[/code]' or other end tags and that can really mess things up. (But I haven't been able to duplicate getting a '$3' rather than text or an error message. That '$3' will come from YaBBC.pm auto-formatting something.)


That $3 most likely comes from the HTML source of the error page it tries to split instead of the simple subject|message|myname it is supposed to split when returning in the ajax callback. It shouldn't replace the message with the error page when using LivePreview, it should just return HTTP error status, return empty message or truncate it.

I can reproduce this every time I try to quote and reply one of the longer patch posts in the HTML 5 section of this forum. It does throw error popup, but does also mess up the LivePreview big time.
  
Back to top
IP Logged
 
Paste Member Name in Quick Reply Box Dandello
Forum Administrator
YaBB Modder
*****
Offline


I love YaBB 2.7!

Posts: 2234
Location: The Land of YaBB
Joined: Feb 12th, 2014
Gender: Female
Mood: Annoyed
Zodiac sign: Virgo
Re: Reply preview bug
Reply #3 - Oct 23rd, 2014 at 5:46am
Mark & QuoteQuote  
Okay, I was able to reproduce the problem. What's happening is when a quote is too long, it gets truncated. But if it's quoted code, the end-tag for the code section gets truncated/removed - which tells YaBB it should be rendered.

Basically, we need to write a 'code tag detector' for quotes so that code tags always have end tags.
  

Perfection is not possible. Excellence, however, is excellent.
Back to top
WWW  
IP Logged
 
Paste Member Name in Quick Reply Box Dandello
Forum Administrator
YaBB Modder
*****
Offline


I love YaBB 2.7!

Posts: 2234
Location: The Land of YaBB
Joined: Feb 12th, 2014
Gender: Female
Mood: Annoyed
Zodiac sign: Virgo
Re: Reply preview bug
Reply #4 - Oct 23rd, 2014 at 7:23pm
Mark & QuoteQuote  
Okay - currently testing a fix - during the quote truncation process it counts the number of code open and code close tags, compares them and if there are more opens than closes, adds a close code tag just in front of the end quote tag.

Other unclosed tags due to truncation are a nuisance but aren't likely to completely trash the rendering.
  

Perfection is not possible. Excellence, however, is excellent.
Back to top
WWW  
IP Logged
 
Paste Member Name in Quick Reply Box Monni
Language
***
Offline


Min izāmō

Posts: 413
Location: Kaarina, Finland
Joined: Jul 16th, 2014
Gender: Male
Mood: Frustrated
Zodiac sign: Pisces
Re: Reply preview bug
Reply #5 - Oct 23rd, 2014 at 7:33pm
Mark & QuoteQuote  
Dandello wrote on Oct 23rd, 2014 at 7:23pm:
Okay - currently testing a fix - during the quote truncation process it counts the number of code open and code close tags, compares them and if there are more opens than closes, adds a close code tag just in front of the end quote tag.

Other unclosed tags due to truncation are a nuisance but aren't likely to completely trash the rendering.


Works better here... Doesn't mangle the output like before. I think we need to deal with the other unclosed tags when and if we notice them causing any trouble.
  
Back to top
IP Logged
 
Page Index Toggle Pages: 1
ReplyAdd Poll Send Topic
Bookmarks: del.icio.us Digg Facebook Google LinkedIn reddit Twitter Yahoo
Reply preview bug

Please type the characters exactly as they appear in the image,
without the first 2 and last 2 characters.
The characters must be typed in the same order,
and they are case-sensitive.
Open Preview Preview

You can resize the textbox by dragging the right or bottom border.
Off Topic Comment Insert Spoiler
Insert Hyperlink Insert FTP Link Insert Image Insert E-mail Insert Media Insert Table Insert Table Row Insert Table Column Insert Horizontal Rule Insert Teletype Insert Code Insert Quote Edited Superscript Subscript Insert List /me - my name Insert Marquee Insert Timestamp No Parse
Bold Italicized Underline Insert Strikethrough Highlight
                       
Change Text Color
Insert Preformatted Text Left Align Centered Right Align
resize_wb
resize_hb







Max 5000 characters. Remaining characters:
Text size: %
More Smilies
View All Smilies
Collapse additional features Collapse/Expand additional features Smiley Wink Cheesy Grin Angry Sad Shocked Cool Huh Roll Eyes Tongue Embarrassed Lips Sealed Undecided Kiss Cry