May 10, 200421 yr This may be an easy fix, I'm sure someone's encountered it before, but my search on this site produced nothing... I have a field that has check boxes with a value list. When I display this field on the web, it makes returns after each value of the checklist. Normally this would be fine, but it's being used in a document.write, which is freaking out because of the line break. Is there any way (perhaps along the lines of the 'raw' attribute), that I can have this data displayed without line breaks?
May 10, 200421 yr Author Is there a CDML solution? Or javascript not worrying so much about a break in the line?
May 10, 200421 yr Author Well, using the 'break' encoding offers a decent solution...The javascript works but there is a <br> between each value.
May 11, 200421 yr Here is some Javascript that you can combine with the [FMP-Field:xxx,Break] tag. <body>The first Line<br> <script> myfield = "hello<br>World<br>from<br>Garry."; document.write(myfield.replace(/<br>/g, " ")); document.write("<br>"); </script> The Last Line</body> Hope this helps. Garry
Create an account or sign in to comment