Ejemplo n.º 1
0
                    $temp_image = dfopen($ppic, 99999999, '', '', true, 3, $_SERVER['HTTP_USER_AGENT']);
                    if (!$temp_image) {
                        jio()->MakeDir(dirname($tpic));
                        jio()->WriteFile($tpic, $temp_image);
                    }
                }
            }
        }
        if (is_file($tpic) && ($ps = getimagesize($tpic) && ($p_data = file_get_contents($tpic)))) {
            $p_name = basename($topic_image['name'] ? $topic_image['name'] : $tpic);
            if (!$p_name) {
                $p_name = mt_rand();
            }
            $p_name = array_iconv($GLOBALS['_J']['config']['charset'], 'UTF-8', $p_name);
            $pic = array($ps['mime'], $p_name, $p_data);
            $t_result = $QQAuth->tAddPic($content, $pic);
        } else {
            $t_result = $QQAuth->tAdd($content);
        }
    } else {
        $t_result = $QQAuth->tAdd($content);
    }
} else {
    $reid = DB::result_first("select `qqwb_id` from " . TABLE_PREFIX . "qqwb_bind_topic where `tid`='{$totid}'");
    if ($reid < 1) {
        return;
    }
    $t_result = $QQAuth->tReply($reid, $content);
}
if ($t_result['errcode']) {
    if (jget('debug')) {