diff options
author | Richard Gibson <richard.gibson@gmail.com> | 2012-02-17 14:17:20 -0500 |
---|---|---|
committer | Dave Methvin <dave.methvin@gmail.com> | 2012-02-23 23:09:31 -0500 |
commit | dec2804c783003c13d356ed3fec664c3ac4b05ee (patch) | |
tree | e9e212208dfac982cad404874d76956bbf100bb6 /src | |
parent | f36568324d1b68101cc6e8933b94db3bc8591fad (diff) | |
download | jquery-dec2804c783003c13d356ed3fec664c3ac4b05ee.tar.gz jquery-dec2804c783003c13d356ed3fec664c3ac4b05ee.zip |
Fix #11359: preserve contents for cloned scripts
Diffstat (limited to 'src')
-rw-r--r-- | src/manipulation.js | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/manipulation.js b/src/manipulation.js index 602076a1b..220e09d46 100644 --- a/src/manipulation.js +++ b/src/manipulation.js @@ -456,6 +456,10 @@ function cloneFixAttributes( src, dest ) { // cloning other types of input fields } else if ( nodeName === "input" || nodeName === "textarea" ) { dest.defaultValue = src.defaultValue; + + // IE blanks contents when cloning scripts + } else if ( nodeName === "script" && dest.text !== src.text ) { + dest.text = src.text; } // Event data gets referenced instead of copied if the expando |