Common Functions for Classic ASP

Function log_g(str)
	dim value

	if isNull(str) then
		response.write "NULL"
		response.end
	end if

	if isarray(str) or isobject(str) then
		for each value in str
		    response.write(value & "<br />")
		next
		response.end
	end if

	response.write "(" & len(str) & ") " & str
	response.end
End Function

function escape_sql(value)
	str = replace(value, "'", "''")
	escape_sql = str
end function