0

わかりました、私はこれを数え切れないほど調べました。imagecreatefrompng('some sort of photobucket url or imgur.com') を使用するには、次の関数を実行する必要があると多くの人が言いました。

$powered = imagecreatefromstring(file_get_contents('http://bowlinggreen.halfoffdeals.com/images/small_logos/bowlinggreen.png'));
$powered = imagepng($powered_by);

しかし、それは私を助けません。それは私にこのエラーを与えます:

警告: imagecreatefromstring() [function.imagecreatefromstring]: 123 行目の /usr/home/dev1/public_html/inline/iframe_special_gd.php の空の文字列または無効な画像

警告: imagepng(): 指定された引数は、124 行目の /usr/home/dev1/public_html/inline/iframe_special_gd.php の有効な画像リソースではありません

警告: imagecopymerge(): 指定された引数は、129 行目の /usr/home/dev1/public_html/inline/iframe_special_gd.php の有効な画像リソースではありません

この URL を画像として取得して、現在の画像の上にマージしようとしています:

$image = imagecreatefrompng('http://dev1.mogadore-deals2.com/images/gdprac/blank_template2.png');

imagecopymerge($powered, $image, 5, 10, 5, 10, 150, 148, 100);

    imagefttext($image, 8, 0, 163, 20, $color, '../images/gdprac/LUCIDASANSSTD-BOLD.OTF', 'Your Price:');
    imagefttext($image, 22, 0, 163, 48, $color, '../images/gdprac/LUCIDASANSSTD.OTF', '$'.$selling_price);
    imagefttext($image, 7, 0, 168, 70, $color, '../images/gdprac/LUCIDASANSSTD.OTF', 'Original Price');
    imagefttext($image, 11, 0, 182, 90, $color, '../images/gdprac/LUCIDASANSSTD.OTF', '$'.$certificate_value);
    imagefttext($image, 7, 0, 248, 70, $color, '../images/gdprac/LUCIDASANSSTD.OTF', 'Savings');
    imagefttext($image, 11, 0, 250, 90, $color, '../images/gdprac/LUCIDASANSSTD.OTF', '50%');
    imagefttext($image, 7, 0, 163, 153, $color, '../images/gdprac/LUCIDASANSSTD.OTF', 'Powered by:');

imagepng($image, '../images/gdprac/final_temp.png');
4

0 に答える 0