Please read the following installation instructions carefully:
» SETUP REQUIREMENTS
• A server running PHP v4.3 or higher. Some of the syntax will NOT work on earlier versions. • A MySQL database to hold the script tables. • GD2 Graphic Library support for auto thumbnail creation, captcha & watermark display. • CURL enable for the Paypal IPN system. The script auto checks your configuration when you load the installer.
» SETUP (AUTO INSTALL)
1 => Create a database to hold the script tables. If you are unsure of this procedure contact your web hosting company. 2 => Open up the 'inc/db_connection.inc.php' file in a text editor and edit it to point to the database you just created. DO NOT comment out the prefix function. If you don`t need to change it leave it as it is. You MUST also specify a cookie name and a secret key. DO NOT use the defaults!! 3 => Again in your text editor, open up the 'admin/inc/password.inc.php' file and choose a username and password for your admin area. 4 => Upload all the files/folders into a directory on your web server. Example: /gallery/ 5 => Chmod the following folders to 777 to make them world writeable. (If your server accepts 755, then you should choose this as its known to be more secure):
/galleries/ /galleries/categories/ /galleries/categories/*folder (any folder you create) /log/
NOTE: It is recommended you remove the write permissions on your image folders when you have added your images. 6 => Access the '/install/index.php' file in your browser and follow the set up instructions to complete installation. Once setup is complete, delete the install dir. 7 => If the setup was successful log in to your admin area and select 'Settings' from the top menu. Update the settings to your own preferences.
http://www.yoursite.com/gallery/admin/
8 => Rename the 'admin' folder if you want to for additional security. If you do rename it, update the admin folder name in the 'inc/defined.inc.php' file. 9 => Thats it, all done. For script usage see below.
» SETUP (MANUAL INSTALL)
If the auto install has aborted or if you prefer to manually install the system, follow these instructions: 1 => Create a database to hold the script tables. If you are unsure of this procedure contact your web hosting company. 2 => Open up the 'inc/db_connection.inc.php' file in a text editor and edit it to point to the database you just created. DO NOT comment out the prefix function. If you don`t need to change it leave it as it is. 3 => Again in your text editor, open up the 'admin/inc/password.inc.php' file and choose a username and password for your admin area. 4 => Upload all the files/folders into a directory on your web server. Example: /gallery/ 5 => Chmod the following folders to 777 to make them world writeable. (If your server accepts 755, then you should choose this as its known to be more secure):
/galleries/ /galleries/categories/ /galleries/categories/*folder (any folder you create) /log/
NOTE: It is recommended you remove the write permissions on your image folders when you have added your images. 6 => Access your database using your MySQL admin program. PHPMYADMIN? Browse for and run the 'docs/schematic/tables.sql' file to set up the script tables. 7 => Log in to your admin area and select 'Settings' from the top menu. Update the settings to your own preferences.
http://www.yoursite.com/gallery/admin/
8 => Rename the 'admin' folder if you want to for additional security. If you do rename it, update the admin folder name in the 'inc/defined.inc.php' file. 9 => Thats it, all done. For script usage see below.
» SCRIPT USAGE
Firstly, you`ll need to create some categories and/or sub categories. Once this is done you can add your pictures. See the folder information below. Manage your pictures in your admin area. Disable and enable things to see how they work.
» AUTO THUMBNAIL CREATION
For the auto thumbnail creation feature to work, you will need to have GD graphic support enabled on your server. See the F.A.Q page for information on how to check for this feature. If you don`t have this you can manually create and upload your thumbnails. There is no option in Maian Gallery to improve thumbnail quality. Generally if your image is good quality, the thumbnail should be too. If you aren`t happy with the thumbnails generated, create your own manually and upload. See the F.A.Q page for some auto thumbnail software links.
» IMAGES PER ROW
There is no setting for this because the amount of rows is determined by the width of the main div in the stylesheet and also the width of the li tags. Altering this is a combination of the thumbnail display size and the settings in the stylesheet. This may be a little complicated if you don`t know how .CSS files work. Have a play around and see what happens.
» CATEGORY FOLDERS
When you create your categories you`ll need to specify and manually create your category folders. The current script version does not create the folders. So, if you have specified a category called 'Flowers', you might specify 'flowers' as your folder name and then create a folder in the main 'galleries/categories/' folder. If you then want a sub category called 'roses', specify 'flowers/roses' as your folder name and create a new folder inside the 'galleries/categories/flowers/' folder called 'roses'. Note that all categories you create must be writeable.
» WATERMARKS
The watermark feature enables you to mask original images. You may want to enable this if you are selling images. To enable the watermark function update your settings in your admin area. Various options can be changed for the watermarks. Watermarks work for the slideshow and are also category specific. The GD2 Library is required for the watermark feature.
» SLIDESHOW
Integrated into Maian Gallery is Jonathan Schemoul's superb Smooth Gallery slideshow. This slideshow is javascript based and can be enabled in your settings. The main control/layout settings can be found in the following files:
themes/*theme/jd.gallery.css themes/*theme/layout.css themes/*theme/js/jd.gallery.js
Default speed for slideshow is set in the 'inc/defined.inc.php' file. Image display sizes for the slideshow are in the slideshow stylesheets.
» SLIDESHOW MUSIC
I updated the Smooth Gallery slideshow to also include background music in .mp3 format. Music paths can be specified in your admin area. You can use a different file for each category or revert to the default one in the slideshow settings. .mp3 files need to be added to the 'mp3' folder.
» COMMENTS
If you wish you can enable user comments so visitors can comment on your pictures. Comments can be site wide or category specific. When enabling comments you also have the option of approving entries and also enabling the e-mail verification feature. Both features can be enabled together if you wish. Once a visitor has verified their e-mail address, they won`t need to again unless you delete it from the allowed e-mails or they use a different address.
» CART SYSTEM
Maian Gallery has an integrated cart system. This feature is ideally suited to photographers who may have images they wish to sell. Paypal is used for processing, so you`ll need a Paypal business account. See the IPN setup instructions. When pictures are purchased, download links are not sent. You`ll need to deal with the shipping seperately. You`ll see a couple of basic shipping options in the settings. The cart system is enabled in the settings. See the notes in the admin area on how to add buy options. For quickness you can batch add pricing options to an entire category of pictures if they have the same options.
» SEARCH ENGINE FRIENDLY URLS
Maian Gallery supports search engine friendly urls via mod_rewrite. To enable this function, rename the 'htaccess_COPY.txt' file to '.htaccess' and enable the option in your settings. Your server must support this feature. If it doesn`t you`ll see an internal server error. If your server does support it and you see an error, check your server error logs.
» EDITING TEMPLATES
To edit the script templates you need a text editor. Notepad will be fine., but a better, colour coded text editor is recommended. It is important that the data between <?php ?> tags remains in place or else the template may fail. Advanced users will know which variables are not so important. The '.tpl' files in the 'themes/*theme/tpl_files/' folder use data between braces which is parsed by the system. These files keep 99% of the HTML out of the main processing files. For more information see the 'themes/*theme/README.txt' file for more info. The e-mail templates also use braces. ie: {NAME} Again, be careful when editing not to remove these variables. All site paths are automatically parsed by the system, so no need to manually update paths in the e-mail templates.
» LANGUAGE
All the script language is in the 'lang/english.php' language file.
» CASCADING STYLESHEETS (.CSS)
v2.0+ has all style control elements/colours in the stylesheets. Besides the slideshow css files mentioned earlier, the main interface has the following stylesheets:
themes/*theme/stylesheet.css (Main Control) themes/*theme/calendar.css (For Search Calendar) themes/*theme/greybox/gb_styles.css (For Greybox pop up windows) themes/*theme/rss_style.css (RSS Styling) themes/*theme/category_menu.css (Category Styling) ** themes/*theme/mgallery.css (Generic Maian Gallery CSS File) **
Note that if you can`t find a colour, what you are seeing on screen may be a background image. The RSS stylesheet may not be applicable for all browsers. ** CSS file relevant to some themes ONLY.
» CAPTCHA CODE
All the settings and fonts for the captcha are in the 'captcha' directory. The reload gif is in the 'themes/*theme/images/captcha' directory. If you have multiple themes, also check the 'themes' page to see how to change the captcha text colour per theme on the fly.
» CLOSING NOTES
Hopefully this installation guide has helped you get the script up and running. Check out the F.A.Q page for some solutions to common problems. If you require any help at all, please post on the support forums. Thank you.