Skip to content

Instantly share code, notes, and snippets.

@mokamoto
Created November 29, 2013 09:47
Show Gist options
  • Save mokamoto/7703564 to your computer and use it in GitHub Desktop.
Save mokamoto/7703564 to your computer and use it in GitHub Desktop.
<apex:page controller="JSRemoteController"
docType="html-5.0"
standardStylesheets="false"
applyHtmlTag="false"
applyBodyTag="false"
showHeader="false">
<html>
<head>
<script type="text/javascript">
function getEcho(areaMessage){
JSRemoteController.getEchoService(areaMessage,function(result, event){
if(event.status) {
document.getElementById("result").innerHTML = result;
}
});
}
</script>
</head>
<body>
<textarea rows="7" cols="20" id="area"></textarea>
<br />
<button onclick="getEcho(document.getElementById('area').value);">JS Remoteエコー</button><br/>
<div id="result"></div>
</body>
</html>
</apex:page>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment