source: companies/serpro/news_admin/templates/celepar/fckeditor/editor/filemanager/browser/default/connectors/asp/util.asp @ 903

Revision 903, 1.3 KB checked in by niltonneto, 15 years ago (diff)

Importacao inicial do Expresso do Serpro

Line 
1<!--
2 * FCKeditor - The text editor for internet
3 * Copyright (C) 2003-2006 Frederico Caldeira Knabben
4 *
5 * Licensed under the terms of the GNU Lesser General Public License:
6 *              http://www.opensource.org/licenses/lgpl-license.php
7 *
8 * For further information visit:
9 *              http://www.fckeditor.net/
10 *
11 * "Support Open Source software. What about a donation today?"
12 *
13 * File Name: util.asp
14 *      This file include generic functions used by the ASP Connector.
15 *
16 * File Authors:
17 *              Frederico Caldeira Knabben (fredck@fckeditor.net)
18-->
19<%
20Function RemoveFromStart( sourceString, charToRemove )
21        Dim oRegex
22        Set oRegex = New RegExp
23        oRegex.Pattern = "^" & charToRemove & "+"
24
25        RemoveFromStart = oRegex.Replace( sourceString, "" )
26End Function
27
28Function RemoveFromEnd( sourceString, charToRemove )
29        Dim oRegex
30        Set oRegex = New RegExp
31        oRegex.Pattern = charToRemove & "+$"
32
33        RemoveFromEnd = oRegex.Replace( sourceString, "" )
34End Function
35
36Function ConvertToXmlAttribute( value )
37        ConvertToXmlAttribute = Replace( value, "&", "&amp;" )
38End Function
39
40Function InArray( value, sourceArray )
41        Dim i
42        For i = 0 to UBound( sourceArray )
43                If sourceArray(i) = value Then
44                        InArray = True
45                        Exit Function
46                End If
47        Next
48        InArray = False
49End Function
50
51%>
Note: See TracBrowser for help on using the repository browser.