Last modified: 2010-05-15 16:03:44 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T16328, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 14328 - jsMsg should accept DOM objects as input
jsMsg should accept DOM objects as input
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
General/Unknown (Other open bugs)
1.13.x
All All
: Normal enhancement with 1 vote (vote)
: ---
Assigned To: Nobody - You can work on this!
: patch, patch-need-review
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2008-05-29 08:40 UTC by Adrian Lang
Modified: 2010-05-15 16:03 UTC (History)
1 user (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Adrian Lang 2008-05-29 08:40:43 UTC
currently, jsMsg only takes HTML as String for the message content.

I suggest the following change:

<	messageDiv.innerHTML = message;

>	if (typeof message == 'string') {
>		messageDiv.innerHTML = message;
>	}
>	else if (typeof message == 'object') {
>		while (messageDiv.hasChildNodes()) // Remove old content
>			messageDiv.removeChild(messageDiv.firstChild);
>		messageDiv.appendChild (message); // Append new content
>	}
Comment 1 Chad H. 2008-06-12 14:01:19 UTC
Fixed in r36239

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links