- first step
Make sure that you have PHP4 (please use 4.0.6 or later), MySQL and Apache installed and working as they should.
Create a database on your mysql server with a suitable name.
- copy
Copy this package to your htdocs root under a directory called 'mp3db' (forced at the moment, will change later)
- config
Open the include/config.inc.php file and set the connection options for the sql server and the directories of the mp3db root
it should look something like this:
$sql_cfg['host']='localhost';
$sql_cfg['login']='mp3db';
$sql_cfg['password']='mp3db';
$sql_cfg['db']='mp3';
#this is where the program will look for files when scanning
$config['mp3db_local_root'] = 'g:/arkivet/musik/mp3/mp3ark';
#this is the basebath for generating playlists
$config['mp3db_root'] = '\\\\deathstar\\arkivet\\musik\\MP3\\mp3ark\\';
#$config['mp3db_root'] = 'http://192.168.1.64/mp3_music';
Create a file called master.ini (a template is provided with this package) in your mp3db_local_root directory.
This file should include some info about the archive:
[archive]
archive_ident=dsfist
this is the way the archive identifies files, longer or shorter than 6 characters.
this is supposede a unique identifier for your own mp3 archive.
archive_name=Deathstar mp3
the archive name, as displayed by the web interface.
owner=Thomas Frossman
the owners name, as displayed by the web interface.
Run the install.php file to create the tables. ( http://servername/mp3db/install.php
).
If the install file does its job without any errors you should delete it or at least rename it to install.php.txt or something so that it can't be run again.
Note: the install.php does not create the tables if they already exists so if you are upgrading from a previous beta release you have to delete the tables manually first (or changing them by hand).
- dir.ini
The albums are identified by a dir.ini in the albun directory (they are recursive)
There is a example mp3 archive for you to look at included with this archive.
It is located under docs/ex_archive/
dir.ini instructions:
[dirinfo]
type= (required)
What type of directory it is (Suggested alternatives: Misc, Album, Single)
Note: "Misc" is a special alternative which means that there are just a bunch of songs
in the direcory, it makes the www interface act differently when sorting.
Albums and other stuff get sorted by tracknumbers while "Misc"'s get sorted by track title
artist= (required)
The artists name (ie. Bender the offender, Pavement, Various)
Note: "Variuos" is the alternative to use when there are different artist in the diretory
title= (required)
Title of the directory album (ie. Young Americans, )
genre=
Genre, can be multiple values separated by forward slashes (/) (ie. rock/punk/disco)
year=
The year the album was made
-1 is the same as leaving the year= empty or not including it at all
albuminfo=
Info about the album
released=
The year the album was releases (if it's a remastered version or something like that)
error=
Free text, errors in the direcotory,, if a mp3 contains a glitch, a mp3 is missing in a album the info goes here..
[autoinfo]
Everything here is generated and managed by the mp3 database system for keeping
record of when the album was added to the archive, last updated etc...
Do not add own keys to this section.