TEH UPLAOD CODEZ
 Your own B3tapix, on your own site


If you want to set up a mechanism for uploading images on your site like you do in B3tapix, you can use this script (a derivative of the B3tapix script).

This can be useful if you want to be able to upload images without using FTP (it's easier and sometimes FTP is disabled)

Download the script here!

INSTRUCTIONS

Requirements
You need a server with PHP and the ability to create a directory and set its permissions.

Setup
Download the
ZIP file, decompress it and transfer uplaod.php to your web site (probably via FTP).
Assuming you have www.domain.com, let's say you want to install it in the main directory of your web site, so that the script would be visible at  www.domain.com/uplaod.php
.

These are the steps to set up the environment:
1) Create a folder (for example pics) in the main directory of your web site.
2) Change the directory's permission so that it is writable by httpd. A slightly less safe but much simpler way is to make the directory writable by anyone. Your FTP program should have a command like chmod. Using chmod, set the permissions for the directory to 777. Another way to say the same thing is to make it a+w (all can write), this depends from your FTP software.
3) Change three variables at the beginning of uplaod.php to reflect your settings:

     $password = "";

Insert here the password you will have to insert to be able to upload. If you leave the line as it is, no password will be required to upload, and anyone will be able to do it.

     $pict_dir = "/pics";

Insert here the name of the writable directory created at steps 1 & 2 above. Leave the slash before, don't add a slash at the end.

     $http_dir = "http://www.domain.com/pics/";

Change this line to reflect your domain and your directory name.

4) Upload the script to your web site & test it. Remember: 99% of the install problems come from not setting the permissions!

Should you have any problem, I will be glad to help: f d-o-t bonomi a-t silab d-o-t it