earwig75
asked on
Add a space after commas in a coldfusion string
I have a select box that allows the user to choose multiple choices and then my cfoutput code writes this to the page. It outputs the choices separated by a comma but no space after the comma. The choice with multiples is "usernames". Right now they show as: username1,username2,userna me3 etc... I'd like: username1, username2, username3 etc..
I'd like to add a space after each comma. Thank you.
I'd like to add a space after each comma. Thank you.
<cfoutput><p>User Names: #usernames# Range: #StDate# - #EdDate#</p></cfoutput>
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
like
<cfset updatedString = replace(usernames,",",", ","All") />