SilverHoodCorp / gdata-java-client

Automatically exported from code.google.com/p/gdata-java-client
Apache License 2.0
0 stars 0 forks source link

Submitting post with newlines being replaced with br tags. #417

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
Try to insert a new post with the following content (notice the newlines):

<script type="text/javascript">
alert('hello world!');
</script>

What is the expected output? What do you see instead?
I expect the new post to have the exact same content.

Instead, all newlines are being replaced with html br tags. Ex.:
<script type="text/javascript"><br />alert('hello world!');<br /></script>

What version of the product are you using? On what operating system?
1.47.1, Windows 7 64-bit

Please provide any additional information below.

This is a problem irregardless of what newline ending I try to use (/n, /r/n, 
/r). I've also tried with various TextContext's, HTML and PlainText versions 
exhibit the same behavior.
The issue will show up in both the "edit post" textbox and the actual post if 
the post was created with the "Use <br> tag" line break setting.
If it was created using the "Press Enter for line breaks" setting, the editor 
textbox will show newlines, but on inspecting the actual post the html still 
uses br tags, causing the script to fail.

Original issue reported on code.google.com by hellowor...@gmail.com on 26 Nov 2012 at 5:28