![]() |
new line javascript
divText = window.opener.document.createTextNode('YOUR CHOİCE \n Start Day : '+val1);
I cant put a newline by this code but when I write \r instead of \n it works.However newline doesnt work.What can ı do?? |
...
:
function addElement1()Here is the code.I got the problem. Newline character doesnt work without pre tag in javascript.But this way,How will I be able to put a pre tag??? Because I am preparing the text in this child window and sending it to the parent... |
Use <br/> if you want a new line presentationally (as rendered by the browser for the client). If your concern is a new line in source view, than the newline should work for you.
Sorry the other code didn't work for you, but I intentionally tried to clarify your request up front, and you agreed it was correct. Presenting your issues clearly is something you need to work on. |
| All times are GMT -5. The time now is 7:44 PM. |
Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC