Is there a way to show data on other form
I tried this code but it shows data from the wordpress ..
I want to show the value of the fields in other form
can you help me please ?
<?php
/**
Plugin Name: Formdatashowup
*/
addaction( 'wpajaxnoprivgetuserinformation','smartformextgetuserinformation');
addaction( 'wpajaxgetuserinformation','smartformextgetuser_information');
function smartformextgetuserinformation(){
requireonce SMARTFORMS_API;
$query=new SmartFormsQuery(17);
$query->AddField('rnField87');
$query->AddField('rnField104');
$query->AddCondition('_UserId','=',get_current_user_id());
$result= $query->GetResults();
echo json_encode(array(
'name' => $result[0]['rnField87'],
'email' => $result[0]['rnField104']
));
die();
}
2
votes
