- Posts: 30
- Thank you received: 0
Ask the community, share ideas, and connect with other LimeSurvey users!
<script type="text/javascript" charset="utf-8"> $(document).ready(function() { // Identify some vars... var apiFilePath = 'http//path/to/api/file.php'; var sid = 123456; var token = 'ABCDE'; var email = 'example@example.com'; var firstName = 'Fred'; var lastName = 'Flinstone'; // AJAX call $.ajax({ url: apiFilePath, // Path to the PHP file async: true, cache : false, // No caching in IE data: { sid: sid, token: token, email : email, firstName: firstName, lastName: lastName }, success: function(results){ // Do something with the returned results of the AJAX call }, error: function(){ alert('Could not connect!'); } }); }); </script>
$iSurveyID = $_GET["sid"]; $token = $_GET["token"]; $email = $_GET["email"]; $LastNameAPI = $_GET["firstName"]; $FirstNameAPI = $_GET["lastName"];