{"id":20961672,"url":"https://github.com/elchininet/thumb","last_synced_at":"2026-05-21T06:06:00.043Z","repository":{"id":98705867,"uuid":"62574737","full_name":"elchininet/Thumb","owner":"elchininet","description":"Small PHP class to create image thumbnails using the PHP GD Library","archived":false,"fork":false,"pushed_at":"2021-02-17T18:29:55.000Z","size":49,"stargazers_count":0,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-20T00:52:30.663Z","etag":null,"topics":["image-cropper","image-cropping","image-manipulation","image-resize","image-resizer","image-resizing","library","php","thumbnail","thumbnails"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/elchininet.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2016-07-04T16:16:12.000Z","updated_at":"2021-02-17T18:31:16.000Z","dependencies_parsed_at":"2023-05-07T07:30:45.963Z","dependency_job_id":null,"html_url":"https://github.com/elchininet/Thumb","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elchininet%2FThumb","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elchininet%2FThumb/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elchininet%2FThumb/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elchininet%2FThumb/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/elchininet","download_url":"https://codeload.github.com/elchininet/Thumb/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243358306,"owners_count":20277995,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["image-cropper","image-cropping","image-manipulation","image-resize","image-resizer","image-resizing","library","php","thumbnail","thumbnails"],"created_at":"2024-11-19T02:15:15.800Z","updated_at":"2025-12-28T08:07:33.354Z","avatar_url":"https://github.com/elchininet.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Thumb\n\nSmall PHP class to create image thumbnails using the PHP GD Library\n\nInstallation\n============\n\n1.\tCopy the php file from the src folder into a folder on your\n\tserver. It needs to be readable by your web server.\n\n2.\tInclude the file in your php with include or require methods.\n\nClass Methods\n=============\n\n    loadImage(string $name)\n_Load the path to the original image_\n\u003e**$name** A string representing the path of the image.\n\n---\n\n    save(string $name [, int $quality = 100] [, int $type = false])\n_Save the resulting image on disk_\n\u003e**$name** A string representing the path of the resulting image.\n\n\u003e**$quality** An optional int between 0 and 100 that set the quality of the resulting image.\n\n\u003e**$type** An optional int that set the format of the resulting image.\n\n\u003ePosible values:\n\u003e* IMAGETYPE_JPEG\n\u003e* IMAGETYPE_PNG\n\u003e* IMAGETYPE_GIF\n\n---\n\n    show([int $type = false] [,boolean $base64 = false])\n_Show the resulting image directly on the page_\n\u003e**$type** An optional int that set the format of the resulting image.\n\n\u003ePosible values:\n\u003e* IMAGETYPE_JPEG\n\u003e* IMAGETYPE_PNG\n\u003e* IMAGETYPE_GIF\n\n\u003e**$base64** An optional boolean that specifies whether the flow of the image need to be printed directly on the page or if you want to return a base64 representation thereof for use as \"src\" parameter of an \"img\" element.\n\n---\n\n    resize(int $value, string $reference)\n_Resize the image keeping its proportions_\n\u003e**$value** An int that set the width or the height of the resizing.\n\n\u003e**$reference** A string that set if the image will be resized by its width or its height.\n\n\u003ePosible values:\n\u003e* width\n\u003e* height\n\n---\n\n    crop(int $width, int $height [, string $position = 'center'])\n_Create a crop of the image_\n\u003e**$width** An int that set the width of the cropping.\n\n\u003e**$height** An int that set the height of the cropping.\n\n\u003e**$position** An optional string that specify the position of the crop.\n\n\u003ePosible values:\n\u003e* center (default value)\n\u003e* top\n\u003e* right\n\u003e* bottom\n\u003e* left\n\n---\n\nDemo\n============\n\n[Functional demo](https://xprimiendo.com/demo/en/php-class-to-create-image-thumbanils/)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Felchininet%2Fthumb","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Felchininet%2Fthumb","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Felchininet%2Fthumb/lists"}