<?php
session_start();
include_once("../libs/variable.php");
$idsql = "select distinct if(retid=0,ifnull(fwtid,tid),retid) from talk_rec where (content!='' or imgs!='' or video!='') and uid = '$uid' and retid =0 and fwtid is NULL order by pubtime desc limit 0,20";
$sql1=$db->getcol($idsql);
print_r($sql1);
echo "<hr>";
$idsq2 = "select distinct ifnull(fwtid,retid) from talk_rec where uid = '$uid' and fwtid>0 order by pubtime desc limit 0,20";
$sql2=$db->getcol($idsq2);
print_r($sql2);
echo "<hr>";
print_r(array_merge_recursive($sql1,$sql2));
echo "<hr>";
$a1=array("a"=>"red","b"=>"green");
$a2=array("c"=>"blue","b"=>"yellow");
print_r($a1);
echo "<hr>";
print_r($a2);
echo "<hr>";
print_r(array_merge_recursive($a1,$a2));
?>