Trying to fetch a value in JavaScript using an Ajax Call,
The code being used is as follows:
<script>
var value = $.ajax({
type:"GET",
url:"get_result.php",
data:"{'abc':" + $abc + "}",
});
alert(value);
</script>
The script written in get_reult.php
is:
<?php
echo $abc= "Working";
?>
Looking forward to hearing about a better solution!