Bug 13146 - REGRESSION: Newlines in javascript results in bookmarks are stripped out
Summary: REGRESSION: Newlines in javascript results in bookmarks are stripped out
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: 523.x (Safari 3)
Hardware: Mac OS X 10.4
: P2 Major
Assignee: Nobody
URL: javascript:location.href='mailto:?SUB...
Keywords: InRadar, Regression
Depends on:
Blocks:
 
Reported: 2007-03-21 12:50 PDT by Gibbons Burke
Modified: 2007-12-30 15:58 PST (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Gibbons Burke 2007-03-21 12:50:36 PDT
I have a bookmark on my Safari bookmark bar with the javascript in the bug report's URL in the URL of the bookmark. When I click this bookmark button it gets the page title and the URL and creates a new mail message with the page's title in the Subject: header, and the title and page's URL in the body of the mail message.

For example, if I click the bookmark button on this bug report page in the latest production version of Safari, it results in the following email in Mail.app:

Mail Header:
Subject: Enter Bug: WebKit

Body:
Enter Bug: WebKit
<http://bugs.webkit.org/enter_bug.cgi>

In recent (last 3 weeks at least) Nightly Builds of the Webkit.app, however, the new line is being stripped out of the resulting text string, so that the body looks like this:

Enter Bug: WebKit<http://bugs.webkit.org/enter_bug.cgi>
Comment 1 David Kilzer (:ddkilzer) 2007-03-21 22:48:59 PDT
Confirmed with a local debug build of WebKit r20361 using Safari 2.0.4 (419.3) on Mac OS X 10.4.9 (8P135).
Comment 2 Mark Rowe (bdash) 2007-03-23 00:24:51 PDT
<rdar://problem/5083647>
Comment 3 Alexey Proskuryakov 2007-03-23 12:39:17 PDT
FWIW, I'm seeing the same behavior with Firefox.
Comment 4 Gibbons Burke 2007-05-14 10:42:30 PDT
I'm not sure if this is a new bug or if it is related, but as of the latest nightly build (r21448), the javascript included in this has stopped working entirely. The Subject line and Contents of the email generated contains nothing but the first letter in the title of the web page from which the script was engaged.
Comment 5 Gibbons Burke 2007-07-06 14:12:23 PDT
The problem exists in Safari 3.0.x also.
Comment 6 Oliver Hunt 2007-07-13 22:05:21 PDT
ap says this occurs in firefox as well, this is a p2
Comment 7 Alexey Proskuryakov 2007-12-30 15:58:38 PST
I'm not sure if this is a bug, but in any case, here is a workaround:

javascript:location.href='mailto:?SUBJECT='+document.title+%20'&BODY='+document.title+'%250A%3C'+escape(location.href)+'%3E'