Alwayslost Posted October 31, 2017 Report Share Posted October 31, 2017 Looking for a script in data pages, where if the phone number doesn't exist, the image presently used for phone number changes... I have a similar script for "Yes/No" fields but don't know how to manipulate it for from Yes/No to Blank/not blank.. Any input is appreciated. Quote Link to comment Share on other sites More sharing options...
Mathilda Posted November 1, 2017 Report Share Posted November 1, 2017 9 hours ago, Alwayslost said: Looking for a script in data pages, where if the phone number doesn't exist, the image presently used for phone number changes... I have a similar script for "Yes/No" fields but don't know how to manipulate it for from Yes/No to Blank/not blank.. Any input is appreciated. You may find an example in this post. Hope that helps Quote Link to comment Share on other sites More sharing options...
Alwayslost Posted November 1, 2017 Author Report Share Posted November 1, 2017 Hi Mathilda: I read it but I don't understand it how it can work on phone number fields. Can you give me an example please with phone number field in there. Also, would this work the same: if I have a check box for phone number and a field for phone number and then use the script below with correct field names of course: <span style="color: #000000; font-size: 12px; font-family: Arial, sans-serif; font-style: normal; font-weight: normal;"><b>21+ </b></span><span id="iconage[@field:age][@field:ID]"></span> <script> if ("[@field:age]" == "No"){ document.getElementById('iconage[@field:age][@field:ID]').innerHTML="<img width='18px' src='http://assets.goplaypool.com/files/theme/appcas/01no.png'/>"; } else if ("[@field:age]" == "Yes"){ document.getElementById('iconage[@field:age][@field:ID]').innerHTML="<img width='18px' src='http://assets.goplaypool.com/files/theme/appcas/01yes.png'/>"; } </script> Thank you in advance. 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.