' Gambas module file

Public Sub TextToHtml(sText As String) As String
  
  Return Replace(Replace(Html(sText), "\n", "<br>"), " ", "&nbsp;")
  
End

Public Sub RenderText(sText As String, sClass As String) As String
  
  If Not sText Then Return
  Return "<div class=\"" & sClass & "\">" & TextToHtml(sText) & "</div>"
  
End

Public Sub RenderHtml(sHtml As String, sClass As String) As String
  
  If Not sHtml Then Return
  Return "<div class=\"" & sClass & "\">" & sHtml & "</div>"
  
End

Public Sub RenderImage(sImage As String, sClass As String) As String
  
  If Not sImage Then Return
  Return "<img class=\"" & sClass & "\" src=\"" & Html(WebControl._GetImageLink(sImage)) & "\">"
  
End

