mirror of
				https://bitbucket.org/chromiumembedded/cef
				synced 2025-06-05 21:39:12 +02:00 
			
		
		
		
	git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@2011 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
		
			
				
	
	
		
			29 lines
		
	
	
		
			793 B
		
	
	
	
		
			HTML
		
	
	
	
	
	
			
		
		
	
	
			29 lines
		
	
	
		
			793 B
		
	
	
	
		
			HTML
		
	
	
	
	
	
| <html>
 | |
| <head>
 | |
| <title>Binding Test</title>
 | |
| <script language="JavaScript">
 | |
| 
 | |
| // Send a query to the browser process.
 | |
| function sendMessage() {
 | |
|   // Results in a call to the OnQuery method in binding_test.cpp
 | |
|   window.cefQuery({
 | |
|     request: 'BindingTest:' + document.getElementById("message").value,
 | |
|     onSuccess: function(response) {
 | |
|       document.getElementById('result').value = 'Response: '+response;
 | |
|     },
 | |
|     onFailure: function(error_code, error_message) {}
 | |
|   });
 | |
| }
 | |
| </script>
 | |
| 
 | |
| </head>
 | |
| <body bgcolor="white">
 | |
| <form>
 | |
| Message: <input type="text" id="message" value="My Message">
 | |
| <br/><input type="button" onclick="sendMessage();" value="Send Message">
 | |
| <br/>You should see the reverse of your message below:
 | |
| <br/><textarea rows="10" cols="40" id="result"></textarea>
 | |
| </form>
 | |
| </body>
 | |
| </html>
 |