==== XML ==== ==== PHP ==== function rpcf_get_doc_templates_list($doc_type_id) { //0x7022 $ret=array(); if (!$this->connection->urfa_call(0x7022)) { print "Error calling function ". __FUNCTION__ ."\n"; return FALSE; } $packet=$this->connection->getPacket(); $packet->DataSetInt($doc_type_id); $this->connection->urfa_send_param($packet); $x = $this->connection->urfa_get_data();// Tariff count $count = $x->DataGetInt(); $ret['count'] = $count; for ($i=0;$i<$count;$i++) { // $x = $this->connection->urfa_get_data(); $doc_template['id']=$x->DataGetInt(); $doc_template['doc_id']=$x->DataGetInt(); $doc_template['date']=$x->DataGetInt(); $doc_template['doc_name']=$x->DataGetString(); $doc_template['def']=$x->DataGetInt(); $ret['doc_templates'][]=$doc_template; } // $this->connection->urfa_get_data(); return $ret; }