Print Page | Close Window

Different Text formats using a function

Printed From: Web Wiz Forums
Category: General Discussion
Forum Name: Classic ASP Discussion
Forum Description: Discussion on Active Server Pages (Classic ASP).
URL: https://forums.webwiz.net/forum_posts.asp?TID=4228
Printed Date: 30 March 2026 at 6:30am
Software Version: Web Wiz Forums 12.08 - https://www.webwizforums.com


Topic: Different Text formats using a function
Posted By: usaboy
Subject: Different Text formats using a function
Date Posted: 13 July 2003 at 5:09pm

Hi.. i have a string like this :

first line

second line

third line

forth line

fifth line

sixt line

 

now i need a function to do this :

put <b> </b> around the first line

put <i> </i> around the second line

put <br> instead of the third line which is a crriage returne

and then loop the same thing for the rest..

put <b> </b> around the forth line

put <i> </i> around the fifth line

put <br> on the sixth line... and so on...

how can i do that using a function in VBScript?!?!

tanx sooo much




Replies:
Posted By: Mart
Date Posted: 15 July 2003 at 9:48am
array = split(string, vbCrlf)

response.write("<b>" & array(0) & "</b>")

..etc



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.08 - https://www.webwizforums.com
Copyright ©2001-2026 Web Wiz Ltd. - https://www.webwiz.net