alexa-tracking

Main Content

1024
1024
KASKUS
51
244
https://www.kaskus.co.id/thread/52e5f7bbfbca1752738b45bb/ask-master-ajax-bantu-ane
[ASK] master ajax bantu ane
solved
errornya gimana gan itu programnya?
Quote:Original Posted By BreakMyFall
errornya gimana gan itu programnya?


bukan error gan, tapi ga efek apa2 emoticon-Matabelo

harusnya pas ane masukin user id misal "88378764" di text name ke isi datanya yang dari database
up up
Code:

[removed][removed]
[removed]
$(document).ready(function() {
$(".userid").change(function() {
var userid =$(this).val();
var dataString = 'userid='+userid;
$.ajax({
type: "POST",
url: "getname.php",
data: dataString,
cache: false,
success: function(html) {
[B] $(".name").html(html);[/B]
}
});
});
});
[removed]
<pre> User ID <input type="text" id="userid" name="userid"> <br>
Name <input type="text" [B]id="name"[/B] name="name"> </pre>


1. klo id manggilnya pake pagar(#), klo class pake titik(.).
2. klo tag html (div, span, dll) isinya pake html, klo inputan form pakenya val.