Init commit

This commit is contained in:
Christian Haschek
2015-10-27 17:19:33 +01:00
parent 7c104db66f
commit 441eb23daf
29 changed files with 22 additions and 3 deletions

0
LICENSE Executable file → Normal file
View File

23
README.md Executable file → Normal file
View File

@@ -6,7 +6,7 @@ If you own a server (even an home server) you can host your own PictShare instan
## Features
- Uploads without logins or validation (that's a good thing, right?)
- Simple API to upload any image from remote servers to your instance via URL or base64 encoded image
- Simple API to upload any image from remote servers to your instance via URL
- 100% file based - no database needed
- PictShare removes all exif data so you can upload photos from your phone and all GPS tags and camera model info get wiped
- Builtin and simple resizing and caching
@@ -16,7 +16,22 @@ If you own a server (even an home server) you can host your own PictShare instan
Lets's say you have uploaded this image: ```https://www.pictshare.net/b260e36b60.jpg``` but you want to use it as your avatar in some forum that only allows 100x100 pixel images.
Instead of editing it yourself you just use ```https://www.pictshare.net/100x100/b260e36b60.jpg```
Just by editing the URL the image gets resized and the resized version gets cached to the disk so it loads much faster.
Just by editing the URL and adding the size (in width**x**height) the image gets resized and the resized version gets cached to the disk so it loads much faster on the next request.
## How does the API work?
PictShare has a simple REST API to upload remote pictures. The API can be accessed via the backend.php file like this:
```https://pictshare.net/backend.php?getimage=<URL of the image you want to upload>```.
#### Example:
Request: ```https://pictshare.net/backend.php?getimage=https://www.0xf.at/css/imgs/logo.png```
The server will answer with the file name and the server path in JSON:
```
{"status":"OK","type":"png","hash":"10ba188162.png","url":"http:\/\/pictshare.net\/10ba188162.png"}
```
## Security and privacy
- By hosting your own images you can delete them any time you want
@@ -28,5 +43,9 @@ Just by editing the URL the image gets resized and the resized version gets cach
- PHP 5 GD library
- Some hostname or subdomain. Site might get messed up if it's not stored in the root directory of the webserver
## Installing PictShare
- Just unpack it on your webserver (remember, pictshare needs to be in a root directory) and it should work out of the box
## Coming soon
- Restricted uploads so you can control who may upload on your instance
- API upload via Base64 encoded images

0
backend.php Executable file → Normal file
View File

0
classes/easyphpthumbnail.php Executable file → Normal file
View File

0
classes/html.php Executable file → Normal file
View File

0
classes/image.php Executable file → Normal file
View File

0
classes/model.php Executable file → Normal file
View File

0
classes/simpleimage.php Executable file → Normal file
View File

0
css/imgs/Thumbs.db Executable file → Normal file
View File

0
css/imgs/bg.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 9.2 KiB

After

Width:  |  Height:  |  Size: 9.2 KiB

0
css/imgs/content.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 2.9 KiB

After

Width:  |  Height:  |  Size: 2.9 KiB

0
css/imgs/footer.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 3.8 KiB

After

Width:  |  Height:  |  Size: 3.8 KiB

0
css/imgs/header.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 20 KiB

After

Width:  |  Height:  |  Size: 20 KiB

0
css/imgs/header_empty.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 4.5 KiB

After

Width:  |  Height:  |  Size: 4.5 KiB

0
css/imgs/header_logo.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 18 KiB

After

Width:  |  Height:  |  Size: 18 KiB

0
css/imgs/hs_logo.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 14 KiB

After

Width:  |  Height:  |  Size: 14 KiB

0
css/main.css Executable file → Normal file
View File

0
css/normalize.css vendored Executable file → Normal file
View File

0
css/pictshare.css Executable file → Normal file
View File

0
inc/core.php Executable file → Normal file
View File

0
index.php Executable file → Normal file
View File

0
js/helper.js Executable file → Normal file
View File

0
js/jquery-2.1.0.min.js vendored Executable file → Normal file
View File

0
js/main.js Executable file → Normal file
View File

0
js/plugins.js Executable file → Normal file
View File

0
js/vendor/modernizr-2.6.2.min.js vendored Executable file → Normal file
View File

0
js/vendor/zepto.min.js vendored Executable file → Normal file
View File

0
models/pictsharemodel.php Executable file → Normal file
View File

0
template.php Executable file → Normal file
View File