This is Interesting: Free Magazines for Graphics designers and webmasters
Home > Archive > Dreamweaver > June 2004 > Showbreaks function
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
Showbreaks function
|
|
| Ben Walker 2004-06-11, 7:15 pm |
| I know this code goes before the html tag...
<%
Function showBreaks(str)
showBreaks = replace(str, chr(10), " <br>")
End Function
%>
But how do i get my dynamic data to apply this?
| |
| ~Angela, TMM 2004-06-12, 4:14 am |
| Hello Ben,
str is the argument of the function. You need to pass this particular
function a string. That string can be a record you're outputting, a
variable, or a true string ("This is a string"). (Perhaps there are other
ways but I'm not thinking of any at the moment...)
So if this is your code
<%= rsMyRecordset.Item("MyField).Value %>
you would make that the argument of the function like so:
<%= showBreaks(rsTLS.Fields.Item("txtItemName").Value) %>
Hope that helps, and good luck.
~Angela
--
Angela C. Buraglia, Founder:
~FAQs, Tutorials & Resources~ http://www.DreamweaverFAQ.com
~My Extensions~ http://www.dwfaq.com/go.asp?ID=AngelaX10
DWfaq Support Newsgroup: news://support.dwfaq.com/support
Co-Author with Joseph Lowery, Dreamweaver MX 2004 Killer Tips:
http://www.dwkillertips.com
Extension Developer for Cartweaver 2:
http://www.cartweaver.com/extensionsuite.cfm
Remove the CAPS in my E-mail to reply off list.
"Ben Walker" <bwalker@telephoneland.com> wrote in message
news:cacu5u$f7d$1@forums.macromedia.com...
> I know this code goes before the html tag...
>
> <%
> Function showBreaks(str)
> showBreaks = replace(str, chr(10), " <br>")
> End Function
> %>
>
> But how do i get my dynamic data to apply this?
>
>
|
|
|
| | Copyright 2003 - 2009 forum4designers.com Software forum Computer Hardware reviews |
|