I have the following script that converts line breaks from plain text into HTML formatted paragraphs. It takes plain text from one text area field and outputs the new formatted text into another text area field.
var noBreaks = document.getElementById("oldText").value;
noBreaks = noBreaks.replace(/
a way to get "plain text" from a script without using <script>...</script> why i want this :user side environnement doen't support script.i will have 2 files ( main.html : 100% html no script , child.html :the script )it means the script must run server side...so, on user side, it will look like this : [code]
On my site, I would like to have jQuery automatically convert all plain-text URLs to links. For example, if I have the following in the BODY tag of my Web page: Go to [URL]to go to the Google Groups home page. I want it to be converted in to this: Go to <a href="http://groups.google.com">http://groups.google.com</a> to go to the Google Groups home page. I'm sure the prepend() and append() functions will be used, but how do I tell jQuery how to pick URLs out of the Web page, if they are not surrounded by separate tags? I'm sure if each URL was in a SPAN tag it would be much easier.
My requirement is to develop a simple form with checkboxes which when selected calculate a price based on the value assigned to the checkbox. The form and calculations is working great but i need a few final touches which i can't work out.
1. I want the total to be in plain text and not in a text box maybe just drop the total value in a DIV.
2. I want the form to start with a default value for example 200, i have tried adding a hidden checkbox with a value of 200 and setting it to checked as default but it doesnt display 200 in the total when i first load the page it only calculates it when i select the first box and i need it to be displayed as the total even if no options are selected.
<body> <BR><BR> <form>
Note this is only intended to be used on IE8. As it stands, the ouput generates and formats exactly as I want bar two things:
1) Does anyone know how I can get some of the text to bold? I've tried everything I can think of (html tags, escape characters etc etc). Is there a way to open a word window in rtf perhaps?
2) Does anyone know how I can insert a small image (a signature in gif or jpg) into the document?
I can use a browser window instead of word, which formats, bolds, images etc, however I then get the issue of headers/footers when printing. I cannot disable headers everytime I want to print a letter, it's not practical.