Coder Social home page Coder Social logo

dummy-image's Introduction

Instructions for Setting Up A Dynamic Dummy Image Generator on your own Server - http://dummyimage.com

What are the requirements?
	You need to have a server than can run PHP code and supports the GD library. Since PHP 4.3 the GD library has been bundled in. For more info go to http://us2.php.net/manual/en/ref.image.php
	It will also help to have mod_rewrite enabled.
	
What do I do?
	Upload code.php, color.class.php, mplus-1c-medium.ttf, and the included .htaccess file to a directory on your server. If you want a copy of the documentation then upload index.php and if you want the documentation to look good upload /css which contains reset.css and dummyimage.css. If you can't pass the image dimensions from the URL (I.e. http://yourserver.com/yourdir/123x345 doesn't show you an image) then look at the .htaccess file.
	You can always pass the image dimension variables to the script by doing http://yourserver.com/yourdir/code.php?x=123x345

Sample .htaccess file
	If you can't see a .htaccess file (Windows hides it by default) copy htaccess.txt to your server and rename it to .htaccess 
	
Credit
	Code written by Russell Heimlich - http://www.russellheimlich.com/blog
	Contact: http://www.russellheimlich.com/contact.html
	
	Some code was written by Ruquay K Calloway http://ruquay.com/sandbox/imagettf/ to detect the text bounding box better (see comments in the PHP code.)

dummy-image's People

Contributors

mattreimer avatar

Stargazers

 avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.