0byt3m1n1
Path:
/
home
/
artemisi
/
public_html
/
phpGenImageTest__3e4c3ab
/
[
Home
]
File: titlemaker.php
<?php include("class.makeImg.php"); $old = error_reporting(E_ALL); $bgimg = $_GET['bgimg']; if (strlen($bgimg)<1) $bgimg = "bluegradient.jpg"; $title = $_GET['title']; if (strlen($title)<1) $title = "Bid Item"; $font = $_GET['font']; if (strlen($font)<1) $font = "BOOKOS.TTF"; $size = $_GET['size']; if (strlen($size)<1) $size = 20; $angle = $_GET['angle']; if (strlen($angle)<1) $angle = 0; $os = $_GET['offset']; if (strlen($os)<1) $os = 1; $swidth = $_GET['depth']; if (strlen($swidth)<1) $swidth = 2; $bbox = imagettfbbox($size, $angle, "fonts/$font", $title); //$msg_height = abs($bbox[7] - $bbox[1]); $msg_height = abs($bbox[7]); $infoImg = GetImageSize("images/$bgimg"); $imgHeight = $infoImg[1]; $titleY = ($imgHeight / 2) + (1*($msg_height / 2)); //die ("$size; $angle; $font; titleY is: $titleY<br>bbox= ".implode('; ',$bbox)."<br>imginfo= ".implode('; ',$infoImg)); ## Initialize ## $mkImg = New putTxtOnImg(); $mkImg->imgSource("images/$bgimg"); ## Message to Put in the Image ## $mkImg->Message($title); ## Personal Font (TTF and full path required) ## $mkImg->Font("fonts/$font"); ## Font Size ( >6 if using TTF font) ## $mkImg->FontSize($size); ## X-Y Coordinates ## $mkImg->Coordinate(10,$titleY); ## Rotation of text (is using Font) ## $mkImg->Angle($angle); ## Text Color ## $mkImg->Colors("0 0 0"); ## If You Want The Shadow, write this ## $mkImg->Shadow("60 60 60"); ## set the offset of the shadow ## $mkImg->ShadowOffset($os); ## set the depth of the shadow ## $mkImg->ShadowWidth($swidth); ## Generate New Image From bgimg ## $mkImg->WriteTXT($size); error_reporting($old); ?>