I'm working on a website that uses a datafeed. Within that datafeed (that comes in via a CSV file) there is a paragraph of text. The client is entering the text in bullet point format and would like it to be displayed as such. For example:
- First point here... * Second point here... * Third point here...
(The client is using the asterix for all points, it's the text editor here converting the first into a bullet point)
Does anyone know a way I'm able to insert line breaks before all but the first asterix so this appears as a list? Maybe with a little javascript?
Ideally the list would appear like this:
- First point here...
- Second point here...
- Third point here...
Thanks in advance,
Tom
li(as they don't need to be closed):text.replace('*', '<li>');<ul>) and make list items (<li>) out of all text nodes beginning with asterix. Make the formatting with CSS, you can set different style for the first list element with the selectorli:first-child.liis optional: w3.org/TR/html-markup/li.html