You need to sign in to do that
Don't have an account?
Robert Miller
jQuery - dynamically display input text
I am attempting to build a VF page that mimics the HTML below. The HTML works as desired, but something breaks in the translation to apex. Thoughts?
HTML
VF
HTML
<!DOCTYPE html> <html> <head> <script src="http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script> <script> j$ = jQuery.noConflict(); j$(document).ready(function() { j$('[id*=name]').bind('keydown keyup keypress', function() { j$('[id*=display]').html(this.value); }); }); </script> </head> <body> <input type='text' id='name'> Your name is <span id='display'/> </body> </html>
VF
<apex:page> <head> <apex:includeScript value="http://ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js" /> <script> j$ = jQuery.noConflict(); j$(document).ready(function() { j$('[id*=name]').bind('keydown keyup keypress', function() { j$('[id*=display]').html(this.value); }); }); </script> </head> <body> <apex:form > <apex:inputText id="name"/> </apex:form> Your name is <apex:outputPanel id="display" /> </body> </apex:page>
All connection to and from salesforce should be secured. In your current page jQuery plugin is being served over http. Use this,
Instead of, Rest seems fine to me.
--Akram
All Answers
All connection to and from salesforce should be secured. In your current page jQuery plugin is being served over http. Use this,
Instead of, Rest seems fine to me.
--Akram