Hi guys
I have a simple one for you.
I am currently using the following script to display data from my database field onto my page
-------------------------
<a href="http://www.mysite.com/<%=oRsB.fields("customername")%>.asp"><%=oRsB.fiel ds("customername")%></a>
-------------------------
However, the "customername" field in my database sometimes contains data with many character spaces at the end eg:
"Mr Ray Harding "
I think you know what's coming next, I need to display the customer's name without the white spaces at the end (trim function?)but also replace any spaces in the middle with a "-". Thus, the data will be displayed as:
"Mr-Ray-Harding" and my hyperlink will direct to: "http://www.mysite.com/Mr-Ray-Harding.asp" without the white spaces.
How is this done?
Any help would be fully appreciated
Best regards
Rod from the UK