Product Launch Plan On Ecommerce Template A PHP class that makes working with images as simple as possible. Best Credit Cards For Young Professionals
HDMI Port On Laptop Developed and maintained by Business Cards For Hair. Facebook Post Format
Best Credit Cards For Establishing Credit If this project has you loving PHP image manipulation again, please consider Project Gantt Chart Example to support its development. Hobby Makes Us
<?php try { // Create a new SimpleImage object $image = new \claviska\SimpleImage(); // Magic! ✨ $image ->fromFile('image.jpg') // load image.jpg ->autoOrient() // adjust orientation based on exif data ->resize(320, 200) // resize to 320x200 pixels ->flip('x') // flip horizontally ->colorize('DarkBlue') // tint dark blue ->border('black', 10) // add a 10 pixel black border ->overlay('watermark.png', 'bottom right') // add a watermark image ->toFile('new-image.png', 'image/png') // convert to PNG and save a copy to new-image.png ->toScreen(); // output to the screen // And much more! 💪 } catch(Exception $err) { // Handle errors echo $err->getMessage(); }- PHP 8.0+
- Stop Please Read Sign
5 Year RoadMap Template For PHP versions below 7.0, please use What Does A Article Look Like Facebook Post Clip Art
- Supports reading, writing, and converting GIF, JPEG, PNG, WEBP, BMP, AVIF formats.
- Reads and writes files, data URIs, and image strings.
- Manipulation: crop, resize, overlay/watermark, adding TTF text
- Drawing: arc, border, dot, ellipse, line, polygon, rectangle, rounded rectangle
- Filters: blur, brighten, colorize, contrast, darken, desaturate, edge detect, emboss, invert, opacity, pixelate, sepia, sharpen, sketch
- Utilities: color adjustment, darken/lighten color, extract colors
- Properties: exif data, height/width, mime type, orientation
- Color arguments can be passed in as any CSS color (e.g.
LightBlue), a hex color, or an RGB(A) array. - Support for alpha-transparency (GIF, PNG, WEBP, AVIF)
- Chainable methods
- Uses exceptions
- Load with Composer or manually (just one file)
- Blog Writing Word Document
Timeline PPT Inspiration Install with Composer: Cash Bonus Credit Cards
composer require claviska/simpleimage Best First Credit Card Or include the library manually: Creative Writing Assignments
<?php require 'src/claviska/SimpleImage.php';Instagram Story Size Chart SimpleImage is developed and maintained by Pinterest Blog Template. Copyright A Beautiful Site, LLC. Template Story New Post
Post It Notes Colors If you enjoy using SimpleImage, especially in commercial applications, please consider Customer Appreciation Email Examples to support its development. Chase Online Log On My Account Credit Card
Visual For A New Day Thanks! 🙌 Business Cards Promo
Success Road Map Licensed under the Example Of Simple Post To Create For A Beginner. News Blogger Template
Product Analysis Page Order of awesomeness: LinkedIn Job Posting Template
- Load an image
- Manipulate the image
- Save/output the image
Short Quotes For Instagram Truths API tips: Nerdwallet Best Credit Cards
- An asterisk denotes a required argument.
- Methods that return a SimpleImage object are chainable.
- You can pass a file or data URI to the constructor to avoid calling
fromFileorfromDataUri. - Static methods can be called with
$image::methodName()or\claviska\SimpleImage::methodName(). - Colors can be a CSS color (e.g.
white), a hex string (e.g. '#ffffff'), or an RGBA array. - You can pipe transparency to
normalizeColorwhen you pass a CSS color or hex string:white|0.25
How To Make An Post Loads an image from a data URI. Repost On Instagram Story Template
$uri* (string) - A data URI.
Launch On Believe Logo Returns a SimpleImage object. Make Business Cards In Word
New Home Post Design Loads an image from a file. Social Media Marketing Post Template
$file* (string) - The image file to load.
Professional Essay Template Returns a SimpleImage object. How Can I Post Story On Instagram From PC
New Website Laugh Post Inspo Creates a new image. EDM Producer
$width* (int) - The width of the image.$height* (int) - The height of the image.$color(string|array) - Optional fill color for the new image (default 'transparent').
Whats The Best Time To Post On Instagram Returns a SimpleImage object. New Post Story Ideas
Free Templates For News Websites Creates a new image from a string. Instagram Story Ideas For Testimonial
$string* (string) - The raw image data as a string. Example:$string = file_get_contents('image.jpg');
What Does Mint Look Like Returns a SimpleImage object. Can You Post On Instagram From Computer
App Launch PPT Template Generates a data URI. Complete The Story Writing Book
$mimeType(string) - The image format to output as a mime type (defaults to the original mime type).$options(array|int) - Array of options or Image quality as a percentage (default 100).
553680 Key Bank Credit Card Returns a string containing a data URI. Elegant Social Media Posts Design
How To Post A Post On Instagram Story Forces the image to be downloaded to the clients machine. Must be called before any output is sent to the screen. Beauty Blog Post Ideas
$filename* (string) - The filename (without path) to send to the client (e.g. 'image.jpeg').$mimeType(string) - The image format to output as a mime type (defaults to the original mime type).$options(array|int) - Array of options or Image quality as a percentage (default 100).
Read Our Blog Rectangular Returns a SimpleImage object. How To Find Someone On Facebook
Free Business Proposal Template Word Writes the image to a file. Please Read Icon
$mimeType(string) - The image format to output as a mime type (defaults to the original mime type).$options(array|int) - Array of options or Image quality as a percentage (default 100).
Project Launch Design Poster Returns a SimpleImage object. Your Text Here Arrow
Goals Presentation Slide Outputs the image to the screen. Must be called before any output is sent to the screen. Coming Soon Teaser Post
$mimeType(string) - The image format to output as a mime type (defaults to the original mime type).$options(array|int) - Array of options or Image quality as a percentage (default 100).
Blog Page Design Ideas Returns a SimpleImage object. Cute Post About Launch
Product Comparison Chart Template Generates an image string. Layout Of A Blog Post
$mimeType(string) - The image format to output as a mime type (defaults to the original mime type).$options(array|int) - Array of options or Image quality as a percentage (default 100).
Promotion Email Template Returns a SimpleImage object. Instagram Article Post
A Newspaper Report Generates an image. Example Of Facebook Post In February 26
$mimeType(string) - The image format to output as a mime type (defaults to the original mime type).$options(array|int) - Array of options or Image quality as a percentage (default 100).
Blogs Writting Returns an array: [mimeType, data] Social Media Post About Food
Tech Hirring Event Instead of providing the quality as an integer as the last function parameter you can also set various options depending on the targeted Mime type using an associative array. Free Project Timeline Template PowerPoint
$image->toFile($file, 'image/avif', [ // JPG, WEBP, AVIF (default 100) 'quality' => 100, // AVIF (default -1 which is 6) // range of slow and small file 0 to 10 fast but big file 'speed' => -1, ]);$image->toFile($file, 'image/bmp', [ // BMP: boolean (default true) 'compression' => true, // BMP, JPG (default null, keep the same) 'interlace' => null, ]);$image->toFile($file, 'image/gif', [ // GIF, PNG (default true) 'alpha' => true, ]);$image->toFile($file, 'image/jpeg', [ // BMP, JPG (default null, keep the same) 'interlace' => null, // JPG, WEBP, AVIF (default 100) 'quality' => 100, ]);$image->toFile($file, 'image/png', [ // GIF, PNG (default true) 'alpha' => true, // PNG: 0-10, defaults to zlib (default 6) 'compression' => -1, // PNG (default -1) 'filters' => -1, // has no effect on PNG images, since the format is lossless // 'quality' => 100, ]);$image->toFile($file, 'image/webp', [ // JPG, WEBP, AVIF (default 100) 'quality' => 100, ]);Instagram Plst Size Gets the image's current aspect ratio. Piling Social Media Post
Post Works Review Template Free Returns the aspect ratio as a float. Fun Instagram Story Ideas
Printable Newspaper Articles Gets the image's exif data. New Free Blogger Template Designs
Instagram Product Tag Template Returns an array of exif data or null if no data is available. Short Newspaper Articles For Kids That Can Fit In A Book
Brother Birthday Card Printable Gets the image's current height. Product Overview Slide Template
Children Blog Cartoon Returns the height as an integer. How To Post A Public Message On Facebook
Blog Layout Ideas Gets the mime type of the loaded image. Post Canva Fancy
How Do Writing Settings Influence The Creation Of Blog Posts Returns a mime type string. Resume Templates Microsoft Word Free Download
Before Launching A New Product Gets the image's current orientation. Credit Card Ads
We Want Your Credit Card Returns a string: 'landscape', 'portrait', or 'square' Blog UI Design Templates
Bank Of America Gold Tier Card Gets the image's current resolution in DPI. Business Punch Cards
Teamwork Vs Individual Work Returns an array of integers: [0 => 96, 1 => 96] How To Create Business Cards In Word
XLS Product Road Map Template Gets the image's current width. Story Insta Guiline
Creative Writing Coursework Inspiration Returns the width as an integer. How To Make Telegram
Business Welcome Letter Template Checks if the SimpleImage object has loaded an image. How To Start A Creative Writing
Magazine Article Template Microsoft Word Returns a boolean. Instagram Post Template PSD Free Download
How To Know Whether A Website Is Blog Or Not Note Instagram Post For Product Service
Best Credit Cards For Young Professionals The reset() method has been deprecated in SimpleImage 4.4.0. Calling the method has no effect. Sample Of A Production Plan With A Budget
Facebook Post Format Destroys the image resource. Bank Of America American Express Card
Hobby Makes Us Returns a SimpleImage object. Best Business Credit Cards For Balance Transfers
Facebook Post Clip Art Rotates an image so the orientation will be correct based on its exif data. It is safe to call this method on images that don't have exif data (no changes will be made). Returns a SimpleImage object. New Product Launch Plan Picture Drawing
Cash Bonus Credit Cards Proportionally resize the image to fit inside a specific width and height. Instagram Story Ideas For Product
$maxWidth* (int) - The maximum width the image can be.$maxHeight* (int) - The maximum height the image can be.
Creative Writing Assignments Returns a SimpleImage object. Examples Of Businesses Using Facebook
Template Story New Post Crop the image. Most Popular Product In The Last 10 Years
- $x1 - Top left x coordinate.
- $y1 - Top left y coordinate.
- $x2 - Bottom right x coordinate.
- $y2 - Bottom right x coordinate.
Chase Online Log On My Account Credit Card Returns a SimpleImage object. Product Launch Event Keynote Speaker Bright
Business Cards Promo Proportionally resize the image to a specific height. Instagram Template For Best Selling Products
News Blogger Template This method was deprecated in version 3.2.2 and will be removed in version 4.0. Please use resize(null, $height) instead. Dispancy Social Media Post
$height* (int) - The height to resize the image to.
LinkedIn Job Posting Template Returns a SimpleImage object. Creative Writing Workshop
Nerdwallet Best Credit Cards Proportionally resize the image to a specific width. Question List To Get To Know Someone
Repost On Instagram Story Template This method was deprecated in version 3.2.2 and will be removed in version 4.0. Please use resize($width, null) instead. New Program Launch Template
$width* (int) - The width to resize the image to.
Make Business Cards In Word Returns a SimpleImage object. Best Times To Post On Twitter
Social Media Marketing Post Template Flip the image horizontally or vertically. Things To Put On Instagram Story
$direction* (string) - The direction to flip: x|y|both
How Can I Post Story On Instagram From PC Returns a SimpleImage object. Travel Blog Images
EDM Producer Reduces the image to a maximum number of colors. Articul For Read
$max* (int) - The maximum number of colors to use.$dither(bool) - Whether or not to use a dithering effect (default true).
New Post Story Ideas Returns a SimpleImage object. Books Bloggers Should Read
Instagram Story Ideas For Testimonial Place an image on top of the current image. WordPress News Website
$overlay* (string|SimpleImage) - The image to overlay. This can be a filename, a data URI, or a SimpleImage object.$anchor(string) - The anchor point: 'center', 'top', 'bottom', 'left', 'right', 'top left', 'top right', 'bottom left', 'bottom right' (default 'center')$opacity(float) - The opacity level of the overlay 0-1 (default 1).$xOffset(int) - Horizontal offset in pixels (default 0).$yOffset(int) - Vertical offset in pixels (default 0).$calculateOffsetFromEdge(bool) - Calculate Offset referring to the edges of the image. $xOffset and $yOffset have no effect in center anchor. (default false).
Can You Post On Instagram From Computer Returns a SimpleImage object. Clip Art For Not Started
Complete The Story Writing Book Resize an image to the specified dimensions. If only one dimension is specified, the image will be resized proportionally. High Quality Image News And Blog
$width* (int) - The new image width.$height* (int) - The new image height.
Elegant Social Media Posts Design Returns a SimpleImage object. Business Cards For Hair
Beauty Blog Post Ideas Changes the resolution (DPI) of an image. Project Gantt Chart Example
$res_x* (int) - The horizontal resolution, in DPI.$res_y(int) - The vertical resolution, in DPI.
How To Find Someone On Facebook Returns a SimpleImage object. Project Management Planning Template
Please Read Icon Rotates the image. How To Text From Computer On Instagram
$angle* (int) - The angle of rotation (-360 - 360).$backgroundColor(string|array) - The background color to use for the uncovered zone area after rotation (default 'transparent').
Your Text Here Arrow Returns a SimpleImage object. Stop Please Read Sign
Coming Soon Teaser Post Adds text to the image. What Does A Article Look Like
$text*(string) - The desired text.$options(array) - An array of options.fontFile* (string) - The TrueType (or compatible) font file to use.size(int) - The size of the font in pixels (default 12).color(string|array) - The text color (default black).anchor(string) - The anchor point: 'center', 'top', 'bottom', 'left', 'right', 'top left', 'top right', 'bottom left', 'bottom right' (default 'center').xOffset(int) - The horizontal offset in pixels (default 0).yOffset(int) - The vertical offset in pixels (default 0).shadow(array) - Text shadow params.x* (int) - Horizontal offset in pixels.y* (int) - Vertical offset in pixels.color* (string|array) - The text shadow color.
calculateOffsetFromEdge(bool) - Calculate Offset referring to the edges of the image (default false).baselineAlign(bool) - Align the text font with the baseline. (default true).
$boundary(array) - If passed, this variable will contain an array with coordinates that surround the text: [x1, y1, x2, y2, width, height]. This can be used for calculating the text's position after it gets added to the image.
Cute Post About Launch Returns a SimpleImage object. Can We Upload Story On Instagram From PC
Layout Of A Blog Post Creates a thumbnail image. This function attempts to get the image as close to the provided dimensions as possible, then crops the remaining overflow to force the desired size. Useful for generating thumbnail images. Blog Writing Word Document
$width* (int) - The thumbnail width.$height* (int) - The thumbnail height.$anchor(string) - The anchor point: 'center', 'top', 'bottom', 'left', 'right', 'top left', 'top right', 'bottom left', 'bottom right' (default 'center').
Instagram Article Post Returns a SimpleImage object. How To Write A Blog On A Website
Example Of Facebook Post In February 26 Draws an arc. Examples Of Writing A Book Outlines
$x* (int) - The x coordinate of the arc's center.$y* (int) - The y coordinate of the arc's center.$width* (int) - The width of the arc.$height* (int) - The height of the arc.$start* (int) - The start of the arc in degrees.$end* (int) - The end of the arc in degrees.$color* (string|array) - The arc color.$thickness(int|string) - Line thickness in pixels or 'filled' (default 1).
Social Media Post About Food Returns a SimpleImage object. Pinterest Blog Template
Free Project Timeline Template PowerPoint Draws a border around the image. Customer Appreciation Email Examples
$color* (string|array) - The border color.$thickness(int) - The thickness of the border (default 1).
Piling Social Media Post Returns a SimpleImage object. Eyes Insta Story
Fun Instagram Story Ideas Draws a single pixel dot. Example Of Simple Post To Create For A Beginner
$x* (int) - The x coordinate of the dot.$y* (int) - The y coordinate of the dot.$color* (string|array) - The dot color.
New Free Blogger Template Designs Returns a SimpleImage object. Small Business Accept Credit Cards
Short Newspaper Articles For Kids That Can Fit In A Book Draws an ellipse. Creative Happy Birthday Cards
$x* (int) - The x coordinate of the center.$y* (int) - The y coordinate of the center.$width* (int) - The ellipse width.$height* (int) - The ellipse height.$color* (string|array) - The ellipse color.$thickness(int|string) - Line thickness in pixels or 'filled' (default 1).
Product Overview Slide Template Returns a SimpleImage object. Social Media Product Ad
How To Post A Public Message On Facebook Fills the image with a solid color. Product Launch Invite
$color(string|array) - The fill color.
Post Canva Fancy Returns a SimpleImage object. Product Stock Icon
Resume Templates Microsoft Word Free Download Draws a line. Corporate Instagram Post Ideas
$x1* (int) - The x coordinate for the first point.$y1* (int) - The y coordinate for the first point.$x2* (int) - The x coordinate for the second point.$y2* (int) - The y coordinate for the second point.$color(string|array) - The line color.$thickness(int) - The line thickness (default 1).
Credit Card Ads Returns a SimpleImage object. What Does A Business Blog Look Like
Blog UI Design Templates Draws a polygon. Sports Product Poster
$vertices* (array) - The polygon's vertices in an array of x/y arrays. Example:[ ['x' => x1, 'y' => y1], ['x' => x2, 'y' => y2], ['x' => xN, 'y' => yN] ]$color* (string|array) - The polygon color.$thickness(int|string) - Line thickness in pixels or 'filled' (default 1).
Business Punch Cards Returns a SimpleImage object. Mind Map Template Kids
How To Create Business Cards In Word Draws a rectangle. Apply Credit Card No Credit
$x1* (int) - The upper left x coordinate.$y1* (int) - The upper left y coordinate.$x2* (int) - The bottom right x coordinate.$y2* (int) - The bottom right y coordinate.$color* (string|array) - The rectangle color.$thickness(int|string) - Line thickness in pixels or 'filled' (default 1).
Story Insta Guiline Returns a SimpleImage object. Credit Card Benefits Template
How To Make Telegram Draws a rounded rectangle. Bank Of America Family Banking
$x1* (int) - The upper left x coordinate.$y1* (int) - The upper left y coordinate.$x2* (int) - The bottom right x coordinate.$y2* (int) - The bottom right y coordinate.$radius* (int) - The border radius in pixels.$color* (string|array) - The rectangle color.$thickness(int|string) - Line thickness in pixels or 'filled' (default 1).
How To Start A Creative Writing Returns a SimpleImage object. Instagram Announcement Post Template
Instagram Post Template PSD Free Download Applies the blur filter. 4 Post Display
$type(string) - The blur algorithm to use: 'selective', 'gaussian' (default 'gaussian').$passes(int) - The number of time to apply the filter, enhancing the effect (default 1).
Instagram Post For Product Service Returns a SimpleImage object. Cleaning Business Cards
Sample Of A Production Plan With A Budget Applies the brightness filter to brighten the image. New Instagram Story Templates
$percentage* (int) - Percentage to brighten the image (0 - 100).
Bank Of America American Express Card Returns a SimpleImage object. English Story Books For Kids
Best Business Credit Cards For Balance Transfers Applies the colorize filter. You Could Be Here Arrow
$color* (string|array) - The filter color.
New Product Launch Plan Picture Drawing Returns a SimpleImage object. How To Post Videos On Instagram Story From HP PC
Instagram Story Ideas For Product Applies the contrast filter. Success Story Email Template
$percentage* (int) - Percentage to adjust (-100 - 100).
Examples Of Businesses Using Facebook Returns a SimpleImage object. Instant Approval Business Credit Cards
Most Popular Product In The Last 10 Years Applies the brightness filter to darken the image. Easy Blogs For Beginners
$percentage* (int) - Percentage to darken the image (0 - 100).
Product Launch Event Keynote Speaker Bright Returns a SimpleImage object. How Do U Start A Blog
Instagram Template For Best Selling Products Applies the desaturate (grayscale) filter. Product Launch Support Icon
Dispancy Social Media Post Returns a SimpleImage object. It Post Incident Review Template
Creative Writing Workshop Applies the duotone filter to the image. Zassy Beauty New Product Launches
$lightColor* (string|array) - The lightest color in the duotone.$darkColor* (string|array) - The darkest color in the duotone.
Question List To Get To Know Someone Returns a SimpleImage object. Sample Of FB Post Need Help
New Program Launch Template Applies the edge detect filter. Product Launch Presentation
Best Times To Post On Twitter Returns a SimpleImage object. 100000 Secured Credit Card
Things To Put On Instagram Story Applies the emboss filter. News And Blog Layouts
Travel Blog Images Returns a SimpleImage object. New Service Product Launch
Articul For Read Inverts the image's colors. Product Launch Manager Illustration
Books Bloggers Should Read Returns a SimpleImage object. Business Cards Reviews
WordPress News Website Changes the image's opacity level. You Launched Your First Virtual Event
$opacity* (float) - The desired opacity level (0 - 1).
Clip Art For Not Started Returns a SimpleImage object. Personalpronomen Im Akkusativ
High Quality Image News And Blog Applies the pixelate filter. Bank Of America Net Banking
$size(int) - The size of the blocks in pixels (default 10).
Business Cards For Hair Returns a SimpleImage object. Cute Coming Soon Instagram Post
Project Gantt Chart Example Simulates a sepia effect by desaturating the image and applying a sepia tone. Taking Credit Card Payments For Small Business
Project Management Planning Template Returns a SimpleImage object. Set Design For Product Display
How To Text From Computer On Instagram Sharpens the image. New Product For Clothing Business Launch Instagram Post
$amount(int) - Sharpening amount (1 - 100, default 50)
Stop Please Read Sign Returns a SimpleImage object. Blank Newspaper Article
What Does A Article Look Like Applies the mean remove filter to produce a sketch effect. Food Social Media Post Size
Can We Upload Story On Instagram From PC Returns a SimpleImage object. Do Microsoft Word Have A Blog Template
Blog Writing Word Document Adjusts a color by increasing/decreasing red/green/blue/alpha values independently. Top Books To Read
$color* (string|array) - The color to adjust.$red* (int) - Red adjustment (-255 - 255).$green* (int) - Green adjustment (-255 - 255).$blue* (int) - Blue adjustment (-255 - 255).$alpha* (float) - Alpha adjustment (-1 - 1).
How To Write A Blog On A Website Returns an RGBA color array. Re Template Blank Page
Examples Of Writing A Book Outlines Darkens a color. Exclusive Launch Poster
$color* (string|array) - The color to darken.$amount* (int) - Amount to darken (0 - 255).
Pinterest Blog Template Returns an RGBA color array. Free Editable Mind Maps
Customer Appreciation Email Examples Extracts colors from an image like a human would do.™ This method requires the third-party library \League\ColorExtractor. If you're using Composer, it will be installed for you automatically. You Read It Pic
$count(int) - The max number of colors to extract (default 5).$backgroundColor(string|array) - By default any pixel with alpha value greater than zero will be discarded. This is because transparent colors are not perceived as is. For example, fully transparent black would be seen white on a white background. So if you want to take transparency into account, you have to specify a default background color.
Eyes Insta Story Returns an array of RGBA colors arrays. How To Advertise On Instagram
Example Of Simple Post To Create For A Beginner Gets the RGBA value of a single pixel. Debit Card Template
$x* (int) - The horizontal position of the pixel.$y* (int) - The vertical position of the pixel.
Small Business Accept Credit Cards Returns an RGBA color array or false if the x/y position is off the canvas. Product Reveal Social Post
Creative Happy Birthday Cards Lightens a color. Person Reading A Journal
$color* (string|array) - The color to lighten.$amount* (int) - Amount to darken (0 - 255).
Social Media Product Ad Returns an RGBA color array. Short Story For Kinder
Product Launch Invite Normalizes a hex or array color value to a well-formatted RGBA array. Product Reveal Party
$color* (string|array) - A CSS color name, hex string, or an array [red, green, blue, alpha].
Product Stock Icon You can pipe alpha transparency through hex strings and color names. For example: Incident Alert Template Word
Corporate Instagram Post Ideas #fff|0.50 <-- 50% white red|0.25 <-- 25% red Alpha Beta Greek Letters
What Does A Business Blog Look Like Returns an array: [red, green, blue, alpha] Retired Business Cards
Sports Product Poster SimpleImage throws standard exceptions when things go wrong. You should always use a try/catch block around your code to properly handle them. End Of Life Doula Business Cards
<?php try { $image = new \claviska\SimpleImage('image.jpeg') // ... } catch(Exception $err) { echo $err->getMessage(); }Mind Map Template Kids To check for specific errors, compare $err->getCode() to the defined error constants. Open Own Blog Or Website
<?php try { $image = new \claviska\SimpleImage('image.jpeg') // ... } catch(Exception $err) { if($err->getCode() === $image::ERR_FILE_NOT_FOUND) { echo 'File not found!'; } else { echo $err->getMessage(); } }Apply Credit Card No Credit As a best practice, always use the defined constants instead of their integers values. The values will likely change in future versions, and WILL NOT be considered a breaking change. Product Launch Formula
ERR_FILE_NOT_FOUND- The specified file could not be found or loaded for some reason.ERR_FONT_FILE- The specified font file could not be loaded.ERR_FREETYPE_NOT_ENABLED- Freetype support is not enabled in your version of PHP.ERR_GD_NOT_ENABLED- The GD extension is not enabled in your version of PHP.ERR_LIB_NOT_LOADED- A required library has not been loaded.ERR_INVALID_COLOR- An invalid color value was passed as an argument.ERR_INVALID_DATA_URI- The specified data URI is not valid.ERR_INVALID_IMAGE- The specified image is not valid.ERR_UNSUPPORTED_FORMAT- The image format specified is not valid.ERR_WEBP_NOT_ENABLED- WEBP support is not enabled in your version of PHP.ERR_WRITE- Unable to write to the file system.ERR_INVALID_FLAG- The specified flag key does not exist.
-
Credit Card Benefits Template Color arguments can be a CSS color name (e.g.
LightBlue), a hex color string (e.g.#0099dd), or an RGB(A) array (e.g.['red' => 255, 'green' => 0, 'blue' => 0, 'alpha' => 1]). Bank Of America Online Banking Demo -
Bank Of America Family Banking When
$thickness> 1, GD draws lines of the desired thickness from the center origin. For example, a rectangle drawn at [10, 10, 20, 20] with a thickness of 3 will actually be draw at [9, 9, 21, 21]. This is true for all shapes and is not a bug in the SimpleImage library. Marketing Strategy Template Excel
Instagram Announcement Post Template Tweak the behavior of a SimpleImage instance by setting instance flag values with the setFlag($key, $value) method. Beautiful Blog Samples
$image = new \claviska\SimpleImage('image.jpeg')->setFlag("foo", "bar");4 Post Display You can also pass an associative array to the SimpleImage constructor to set instance flags. Download Blog Logo
$image = new \claviska\SimpleImage('image.jpeg', ['foo' => 'bar']); // .. or without an $image $image = new \claviska\SimpleImage(flags: ['foo' => 'bar']);Cleaning Business Cards Note: setFlag() throws an ERR_INVALID_FLAG exception if the key does not exist (no default value). Monogram Business Cards
New Instagram Story Templates Setting sslVerify to false (defaults to true) will make all images loaded over HTTPS forgo certificate peer validation. This is especially usefull for self-signed certificates. Fill In Timeline Template
$image = new \claviska\SimpleImage('https://localhost/image.jpeg', ['sslVerify' => false]); // Would normally throw an OpenSSL exception, but is ignored with the sslVerify flag set to false.- Normalized color arguments (colors can be a CSS color name, hex color, or RGB(A) array).
- Normalized alpha (opacity) arguments: 0 (transparent) - 1 (opaque)
- Added text shadow to
textmethod. - Added
fromString()method to load images from strings. - Added
toString()method to generate image strings. - Added
arcmethod for drawing arcs. - Added
bordermethod for drawing borders. - Added
dotmethod for drawing individual pixels. - Added
ellipsemethod for drawing ellipses and circles. - Added
linemethod for drawing lines. - Added
polygonmethod for drawing polygons. - Added
rectanglemethod for drawing rectangles. - Added
roundedRectanglemethod for drawing rounded rectangles. - Added
adjustColormethod for modifying RGBA color channels to create relative color variations. - Added
darkenColormethod to darken a color. - Added
extractColorsmethod to get the most common colors from the image. - Added
getColorAtmethod to get the RGBA values of a specific pixel. - Added
lightenColormethod to lighten a color. - Added
toDownloadmethod to force the image to download on the client's machine. - Added
duotonefilter to create duotone images. - Added
sharpenmethod to sharpen the image. - Changed namespace from
abeautifulsitetoclaviska. - Changed
createmethod tofromNew. - Changed
loadmethod tofromFile. - Changed
load_base64method tofromDataUri. - Changed
outputmethod totoScreen.x - Changed
output_base64method totoDataUri. - Changed
savemethod totoFile. - Changed
textmethod to accept an array of options instead of tons of arguments. - Removed text stroke from
textmethod because it produced dirty results and didn't support transparency. - Removed
smoothmethod because its arguments in the PHP manual aren't documented well. - Removed deprecated method
adaptive_resize(usethumbnailinstead). - Removed
get_meta_data(usegetExif,getHeight,getMime,getOrientation, andgetWidthinstead). - Added How To Get Computer To Read An Article file. Please make sure your editor supports these settings before submitting contributions.
- Switched from four spaces to two for indentations (sorry PHP-FIG!).
- Switched from underscore_methods to camelCaseMethods.
- Organized methods into groups based on function
- Removed PHPDoc comments. At this time, I don't wish to incorporate them into the library.