Jump to content


Photo

Image cropping when should scale


  • Please log in to reply
No replies to this topic

#1 cyber-drugs

cyber-drugs
  • Members
  • Pip
  • Newbie
  • 2 posts

Posted 25 May 2005 - 08:15 PM

http://cyber-lane.co...t/PC/images.php

The above image is being cropped when it should be re-sizing, can someone help me with the code to fix it?

[!--PHP-Head--][div class=\'phptop\']PHP[/div][div class=\'phpmain\'][!--PHP-EHead--]
[span style=\"color:#0000BB\"]<?
$flag [/span][span style=\"color:#007700\"]= [/span][span style=\"color:#0000BB\"]imagecreatefrompng[/span][span style=\"color:#007700\"]([/span][span style=\"color:#DD0000\"]\'Graphics/Backgrounds/africa.png\'[/span][span style=\"color:#007700\"]);
[/span][span style=\"color:#0000BB\"]$mask [/span][span style=\"color:#007700\"]= [/span][span style=\"color:#0000BB\"]imagecreatefrompng[/span][span style=\"color:#007700\"]([/span][span style=\"color:#DD0000\"]\'Graphics/Nodes/shapes.png\'[/span][span style=\"color:#007700\"]);

[/span][span style=\"color:#0000BB\"]imagealphablending[/span][span style=\"color:#007700\"]([/span][span style=\"color:#0000BB\"]$flag[/span][span style=\"color:#007700\"], [/span][span style=\"color:#0000BB\"]1[/span][span style=\"color:#007700\"]);
[/span][span style=\"color:#0000BB\"]imagealphablending[/span][span style=\"color:#007700\"]([/span][span style=\"color:#0000BB\"]$mask[/span][span style=\"color:#007700\"], [/span][span style=\"color:#0000BB\"]1[/span][span style=\"color:#007700\"]);

[/span][span style=\"color:#0000BB\"]imagecopy[/span][span style=\"color:#007700\"]([/span][span style=\"color:#0000BB\"]$flag[/span][span style=\"color:#007700\"], [/span][span style=\"color:#0000BB\"]$mask[/span][span style=\"color:#007700\"], [/span][span style=\"color:#0000BB\"]200[/span][span style=\"color:#007700\"],[/span][span style=\"color:#0000BB\"]200[/span][span style=\"color:#007700\"],[/span][span style=\"color:#0000BB\"]0[/span][span style=\"color:#007700\"],[/span][span style=\"color:#0000BB\"]0[/span][span style=\"color:#007700\"],[/span][span style=\"color:#0000BB\"]135[/span][span style=\"color:#007700\"],[/span][span style=\"color:#0000BB\"]101[/span][span style=\"color:#007700\"]);

[/span][span style=\"color:#FF8000\"]//------------------------------------

[/span][span style=\"color:#0000BB\"]$mask [/span][span style=\"color:#007700\"]= [/span][span style=\"color:#0000BB\"]imagecreatefrompng[/span][span style=\"color:#007700\"]([/span][span style=\"color:#DD0000\"]\'Graphics/Nodes/shapes2.png\'[/span][span style=\"color:#007700\"]);

[/span][span style=\"color:#0000BB\"]imagealphablending[/span][span style=\"color:#007700\"]([/span][span style=\"color:#0000BB\"]$flag[/span][span style=\"color:#007700\"], [/span][span style=\"color:#0000BB\"]1[/span][span style=\"color:#007700\"]);
[/span][span style=\"color:#0000BB\"]imagealphablending[/span][span style=\"color:#007700\"]([/span][span style=\"color:#0000BB\"]$mask[/span][span style=\"color:#007700\"], [/span][span style=\"color:#0000BB\"]1[/span][span style=\"color:#007700\"]);

[/span][span style=\"color:#0000BB\"]imagecopy[/span][span style=\"color:#007700\"]([/span][span style=\"color:#0000BB\"]$flag[/span][span style=\"color:#007700\"], [/span][span style=\"color:#0000BB\"]$mask[/span][span style=\"color:#007700\"], [/span][span style=\"color:#0000BB\"]400[/span][span style=\"color:#007700\"],[/span][span style=\"color:#0000BB\"]400[/span][span style=\"color:#007700\"],[/span][span style=\"color:#0000BB\"]0[/span][span style=\"color:#007700\"],[/span][span style=\"color:#0000BB\"]0[/span][span style=\"color:#007700\"],[/span][span style=\"color:#0000BB\"]135[/span][span style=\"color:#007700\"],[/span][span style=\"color:#0000BB\"]101[/span][span style=\"color:#007700\"]);

[/span][span style=\"color:#FF8000\"]//------------------------------------

[/span][span style=\"color:#0000BB\"]$final [/span][span style=\"color:#007700\"]= [/span][span style=\"color:#0000BB\"]imagecreatefrompng[/span][span style=\"color:#007700\"]([/span][span style=\"color:#DD0000\"]\'Graphics/PDA.png\'[/span][span style=\"color:#007700\"]);
[/span][span style=\"color:#0000BB\"]$mask [/span][span style=\"color:#007700\"]= [/span][span style=\"color:#0000BB\"]$flag[/span][span style=\"color:#007700\"];

[/span][span style=\"color:#0000BB\"]imagealphablending[/span][span style=\"color:#007700\"]([/span][span style=\"color:#0000BB\"]$final[/span][span style=\"color:#007700\"], [/span][span style=\"color:#0000BB\"]1[/span][span style=\"color:#007700\"]);
[/span][span style=\"color:#0000BB\"]imagealphablending[/span][span style=\"color:#007700\"]([/span][span style=\"color:#0000BB\"]$mask[/span][span style=\"color:#007700\"], [/span][span style=\"color:#0000BB\"]1[/span][span style=\"color:#007700\"]);

[/span][span style=\"color:#0000BB\"]imagecopy[/span][span style=\"color:#007700\"]([/span][span style=\"color:#0000BB\"]$final[/span][span style=\"color:#007700\"], [/span][span style=\"color:#0000BB\"]$mask[/span][span style=\"color:#007700\"], [/span][span style=\"color:#0000BB\"]0[/span][span style=\"color:#007700\"],[/span][span style=\"color:#0000BB\"]0[/span][span style=\"color:#007700\"],[/span][span style=\"color:#0000BB\"]0[/span][span style=\"color:#007700\"],[/span][span style=\"color:#0000BB\"]0[/span][span style=\"color:#007700\"],[/span][span style=\"color:#0000BB\"]400[/span][span style=\"color:#007700\"],[/span][span style=\"color:#0000BB\"]300[/span][span style=\"color:#007700\"]);

[/span][span style=\"color:#FF8000\"]//------------------------------------

[/span][span style=\"color:#0000BB\"]Header[/span][span style=\"color:#007700\"]([/span][span style=\"color:#DD0000\"]\"Content-type: image/jpeg\"[/span][span style=\"color:#007700\"]);
[/span][span style=\"color:#0000BB\"]imagepng[/span][span style=\"color:#007700\"]([/span][span style=\"color:#0000BB\"]$final[/span][span style=\"color:#007700\"]);
[/span][span style=\"color:#0000BB\"]?>
[/span]
[/span][!--PHP-Foot--][/div][!--PHP-EFoot--]

Many thanks. :)




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users