This provides a third method, modify the code of the editor I, can directly solve in the IE7 8 browser normal use. The specific methods are as follows:
Open the Editor.js file under Include, which has this code:
The code is as follows |
Copy Code |
if (element. Yuseronclick) eval (element. Yuseronclick + "anonymous ()"); |
Said because IE8 shielded the anonymous method, so to change to click Method, so changed to this, but I have an amazing discovery, it is changed to do so after the IE7 editor is no use, pain and I went online to check, the Internet is really high water like clouds, Sure enough, I found the answer on the CSDN:
The code is as follows |
Copy Code |
if (Navigator.appVersion.match (/8./i) = = ' 8. ') { if (element. Yuseronclick) eval (element. Yuseronclick + "onclick (event)"); } Else { if (element. Yuseronclick) eval (element. Yuseronclick + "anonymous ()"); } |
Or
The code is as follows |
Copy Code |
if (Navigator.appVersion.match/msie (7|8| 9)./i)!=null { if (element. Yuseronclick) eval (element. Yuseronclick + "onclick (event)"); }else{ if (element. Yuseronclick) eval (element. Yuseronclick + "anonymous ()"); } |
Changing the code so that it works under IE7 and IE8.