Alwayslost Posted September 8, 2016 Report Share Posted September 8, 2016 Hello. I have entered the following script and on the 3rd data field, the value doesn't show! Also, would like to hide any of the fields if no value with script. Any help is appreciated... <span style="color: #A1A1A1; font-size: 12px; font-family: Arial, sans-serif; font-style: normal; font-weight: normal;">21+</span> <span id="icon[@field:age]"></span> <script> if ("[@field:age]" == "No"){ document.getElementById('icon[@field:age]').innerHTML="<img width='15px' src='http://someapp.com/nk/icons/yellowflag.png'/>"; } else if ("[@field:age]" == "Yes"){ document.getElementById('icon[@field:age]').innerHTML="<img width='15px' src='http://assets.goplaypool.com/files/theme/appcas/check_01.png'/>"; } </script> <span style="color: #A1A1A1; font-size: 12px; font-family: Arial, sans-serif; font-style: normal; font-weight: normal;">Tournaments</span> <span id="icon[@field:tourneys]"></span> <script> if ("[@field:tourneys]" == "No"){ document.getElementById('icon[@field:tourneys]').innerHTML="<img width='15px' src='http://someapp.com/nk/icons/yellowflag.png'/>"; } else if ("[@field:tourneys]" == "Yes"){ document.getElementById('icon[@field:tourneys]').innerHTML="<img width='15px' src='http://assets.goplaypool.com/files/theme/appcas/check_01.png'/>"; } </script> <span style="color: #A1A1A1; font-size: 12px; font-family: Arial, sans-serif; font-style: normal; font-weight: normal;">Tournaments</span> <span id="icon[@field:tourneys]"></span> <script> if ("[@field:tourneys]" == "No"){ document.getElementById('icon[@field:tourneys]').innerHTML="<img width='15px' src='http://someapp.com/nk/icons/yellowflag.png'/>"; } else if ("[@field:tourneys]" == "Yes"){ document.getElementById('icon[@field:tourneys]').innerHTML="<img width='15px' src='http://assets.goplaypool.com/files/theme/appcas/check_01.png'/>"; } </script> Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.