Ejemplo n.º 1
0
		creds['api_sig']=$('#api_sig').val();
		
		url='<?php 
echo RJDGPP::getRPC();
?>
';
		creds['rjaction']='setCred';
		creds['id']=0;
		$.getJSON(url,creds).success(function(d){
			$('#msgs').mesfad(d.response);
		});
	};
	
	$.fn.getCred=function(){
		url='<?php 
echo RJDGPP::getRPC();
?>
';
		$.getJSON(url,{rjaction:'getCred',id:0}).success(function(d){
			if(d && d.creds){
				if(typeof d.creds.api_user !='undefined'){
					$('#api_user').val(d.creds.api_user);
				}
				if(typeof d.creds.api_pass !='undefined'){
					$('#api_pass').val(d.creds.api_pass);
				}
				if(typeof d.creds.api_sig !='undefined'){
					$('#api_sig').val(d.creds.api_sig);
				}
			}
		});