Answer the question
In order to leave comments, you need to log in
Regular game: how to convert several adjacent BRs into one?
Line example: Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula < br br br br > Lorem ipsum...< br >
Is it possible to convert several standing in a row "< br> < br> < br> < br>" into one, like this - "< br >" ?
Answer the question
In order to leave comments, you need to log in
'< br >< br >< br >Lorem ipsum...< br >'.replace(/(<\s?br\s?>){2,}/g,'< br >')
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question