⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 pmcard.php

📁 wap 程序 手器电脑通用
💻 PHP
字号:
<?php
/** 
*
* @package wappyCULT: wap community script
* @version 1.00 2006/09/12 21:53:27 wappy
* @copyright (c) 2004-2006 wappyCULT 
* @license http://opensource.org/licenses/gpl-license.php GNU Public License 
*
*/

/**
*/
header('content-type: image/jpeg');

include("config.php");
include("core.php");
connectdb();
$msg = $_GET["msg"];
$cid = $_GET["cid"];
$iid = $cid +0;
$cinfo=mysql_fetch_array(mysql_query("SELECT * FROM ibwf_cards WHERE id='".$iid."'"));
list ($r,$g,$b)  = explode(',',$cinfo[6]);
settype($r,"integer");
settype($g,"integer");
settype($b,"integer");
$bgpic = @imagecreatefromjpeg("pmcards/$cid.jpg");
$bg = imagecolorallocate ($bgpic, 0, 0, 0);
$textcolor = imagecolorallocate($bgpic,$r,$g,$b);

if(($cinfo[5]==0)&&($cinfo[4]==0))
{
    imagestring($bgpic,$cinfo[1],$cinfo[2],$cinfo[3],"$msg",$textcolor);
}else{
    $words = explode(' ',$msg);
    for($i=0;$i< count($words);$i++)
    {
        $xl = $cinfo[3]+($cinfo[4]*$i)+$cinfo[2];
        $yl = $cinfo[4]+($cinfo[5]*$i)+$cinfo[3];
        imagestring($bgpic,$cinfo[1], $xl,$yl,$words[$i],$textcolor);
    }

}
imagejpeg($bgpic);
imagedestroy($bgpic);

?>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -