p.kennedy Posted September 22, 2011 Share Posted September 22, 2011 I have a large text area that is intended to be a bulleted list. I want to set it up so that there is only one text area but when the users hits a hard return the next sentence automatically starts with a bullet. Is this even possible? Link to comment Share on other sites More sharing options...
esmith Posted September 22, 2011 Share Posted September 22, 2011 Sure. You'll need to know what the data looks like when passed to the template, but my guess is that hard returns will appear as break tags in which case you would write a simple rule to replace the tags with a tag plus a bullet character when composed and check the box to return tagged output. return Field("TEXT ARA").replace(/<br>/g, "<br>•"); Link to comment Share on other sites More sharing options...
p.kennedy Posted September 23, 2011 Author Share Posted September 23, 2011 This code doesn't work. Link to comment Share on other sites More sharing options...
Dan Korn Posted September 23, 2011 Share Posted September 23, 2011 Try this instead: return Field("YourFieldName").replace(/<br>/g, "<br>•"); Although I'm not sure exactly what kind of markup gets placed in the field when "users hits a hard return." Where are these users doing the typing? Is this in a Web-to-Print system such as MarcomCentral? Link to comment Share on other sites More sharing options...
p.kennedy Posted September 23, 2011 Author Share Posted September 23, 2011 That code didn't produce any bullets either. They will be typing in marcom central Link to comment Share on other sites More sharing options...
Dan Korn Posted September 23, 2011 Share Posted September 23, 2011 That code didn't produce any bullets either. They will be typing in marcom central Okay, so we need to figure out exactly what is in the data that comes from MarcomCentral, so that we know what needs to be replaced. Can you add a rule which outputs the raw field value, by returning it with the "Treat returned strings as tagged text" box UNchecked, and output that? Or, if you can access the composition log (.msg) file, you can use call the Print function in a rule with the field value to write it there. Getting a hold of the actual tagged markup input data file would be best. Link to comment Share on other sites More sharing options...
p.kennedy Posted September 23, 2011 Author Share Posted September 23, 2011 It is <p> I replaced it and it worked. You tha man Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.