You need to sign in to do that
Don't have an account?
AK_Smith
user agent with JS on visualforce page
Hello! Please hellp me to fix my code to get user agent
<apex:page standardController="CTPHARMA__Activity__c" id="page"> <script> agent() function agent() { var u = window.navigator.userAgent; document.getElementById('page:form:A').value = 1; } </script> <apex:form id="form" > <apex:inputField id="A" value="{!CTPHARMA__Activity__c.SF1_UA__c}" /> </apex:form> </apex:page>
thanks
All Answers
use below code :
put your js in end of the page :
i hope it helps you.
Let me inform if it helps you and kindly mark it best answer if it helps you
thanks
thanks
Thanks! Where to add your script?