Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by ready4data on Sep 12, 2008 05:15
open dhtmlx forum
Email Link in Cell

I want to add an email link to a cell using a recordset.
I'm using ver 1.6
The link I want to insert is:
<a href="Mailto:<%= rsRecords1.Fields("AEmail").Value %>?subject=Question from Customer?body=<%= rsRecords1.Fields("AFName").Value %>, %0A"><%= rsRecords1.Fields("asm").Value %></a>

I want to insert it in the asm cell

I load my data using XML using this code:
Response.write("<rows total_count='" & totalCount & "' pos='" & posStart & "'>")
Do while not rs.EOF
Response.write("<row id='" & rs("dataid") & "'>")
Response.write("<cell style='" & "' bgColor='" & rs("acolor") & "'>")
Response.write(rs("asm"))
Response.write("</cell>")
Response.write("<cell style='" & "' bgColor='" & rs("tcolor") & "'>")
Response.write(rs("tsm"))
Response.write("</cell>")
Response.write("</row>")
rs.MoveNext
Loop
Response.write("</rows>")

Please advise,
Scott




Answer posted by Support on Sep 12, 2008 07:34
You can insert any inline HTML tags directly in XML output , just wrap them in CDATA section 

Response.write("<cell style='" & "' bgColor='" & rs("acolor") & "'>") 
Response.write("<![CDATA[ <a href=""Mailto:" & rsRecords1.Fields("AEmail").Value & "?subject=Question from Customer&body=" & rsRecords1.Fields("AFName").Value & ", %0A"">" &  rsRecords1.Fields("asm").Value & "></a> ]]>")
Response.write("</cell>")