I am new to using VB and integrating JavaScript. I have a simple question, but I'm having trouble figuring it out for some reason.
I am struggling to properly construct an IF-statement. Can you please help me? I have searched and googled, but have not found a solution that works for me. My code is functioning correctly otherwise. Here is the code I am working with:
<script type="text/javascript">
var markers = [
<asp:Repeater ID="rptMarkers" runat="server">
<ItemTemplate>
{
"title": '<%# Eval("pvm")%>',
"lat": '<%# Eval("lat")%>',
"lng": '<%# Eval("lng")%>',
"icon": '<%# Eval("Ikoni")%>',
"description": "<span style=’font-size:18px;font-weight:bold;><%#Eval("pvm")%> <%# Eval("Otsikko")%></span><hr>" +
"Text: <%# Eval("Nimi")%> <br> Merkki: <%# Eval("Tunniste")%> <br>"+
"<%# Eval("Info")%>"
--> This section should be within an IF-statement; If there is "Photo" information, it should be included, otherwise left out;
+"</div><div><img src=<%# Eval("Photo")%> height='150'></img></div></div>"
<--
}
</ItemTemplate>
...
Please provide me with some guidance on this issue.