UPDATE NETJUKEBOX WINDOWS 7

Windows related discussion about netjukebox
Locked
nelsonliu
User
Posts: 2
Joined: Fri Apr 30, 2010 2:57 am

UPDATE NETJUKEBOX WINDOWS 7

Post by nelsonliu »

Hi, I'm having some problems updating netjukebox on windows 7
I followed a maximumpc article: http://www.maximumpc.com/article/howtos ... y_computer?
I'm on windows 7, again.
so, when i try to update, it says:
Can't open directory:
C:/Music/

* Check media_dir value in config.inc.php
* Check file/directory permission

here is my config.inc

Code: Select all

<?php
//  +------------------------------------------------------------------------+
//  | netjukebox, Copyright © 2001-2010 Willem Bartels                       |
//  |                                                                        |
//  | http://www.netjukebox.nl                                               |
//  | http://forum.netjukebox.nl                                             |
//  |                                                                        |
//  | This program is free software: you can redistribute it and/or modify   |
//  | it under the terms of the GNU General Public License as published by   |
//  | the Free Software Foundation, either version 3 of the License, or      |
//  | (at your option) any later version.                                    |
//  |                                                                        |
//  | This program is distributed in the hope that it will be useful,        |
//  | but WITHOUT ANY WARRANTY; without even the implied warranty of         |
//  | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the          |
//  | GNU General Public License for more details.                           |
//  |                                                                        |
//  | You should have received a copy of the GNU General Public License      |
//  | along with this program.  If not, see <http://www.gnu.org/licenses/>.  |
//  +------------------------------------------------------------------------+



//  +------------------------------------------------------------------------+
//  | Media directory                                                        |
//  +------------------------------------------------------------------------+
//  | Use a UNIX style directory with a trailing slash.                      |
//  |                                                                        |
//  | 'D:/Media/';                                                           |
//  | 'D:/Media/Music/';                                                     |
//  |                                                                        |
//  | If you want to run netjukebox from a USB disk than you can detect      |
//  | the drive letter with: substr(__FILE__, 0, 1)                          |
//  | The same trick can be used for the Codec directoty.                    |
//  +------------------------------------------------------------------------+
$cfg['media_dir']                   = 'C:/Music/';
$cfg['convert_undersquare']         = false;



//  +------------------------------------------------------------------------+
//  | Codec directory                                                        |
//  +------------------------------------------------------------------------+
//  | Use a native style directory with a trailing slash/backslash:          |
//  |                                                                        |
//  | Windows:        'D:\Console\Codec\\';                                  |
//  | Linux/Unix/OSX: '/usr/local/codec/';                                   |
//  |                                                                        |
//  | Be aware to escape the last back slash with an extra backslash.        |
//  | On a Windows system you can set the process priority to idle with:     |
//  | 'start /b /low D:\Console\Codec\\';                                    |
//  +------------------------------------------------------------------------+
$cfg['codec_dir']                   = 'start /b /low C:\xampp\htdocs\netjukebox\codecs\\';



//  +------------------------------------------------------------------------+
//  | Album features                                                         |
//  +------------------------------------------------------------------------+
//  | For album_copy_dir use a UNIX style directory with a trailing slash.   |
//  +------------------------------------------------------------------------+
$cfg['album_copy']                  = true;
$cfg['album_copy_dir']              = 'G:/MUSIC/';
$cfg['album_share']                 = true;
$cfg['album_rebuild']               = true;
$cfg['album_update_image']          = true;
$cfg['album_edit_genre']            = true;



//  +------------------------------------------------------------------------+
//  | Cache                                                                  |
//  +------------------------------------------------------------------------+
//  | Decoding to wav and creating zip files is relatively fast.             |
//  | When expire these files there will be more space for slower to         |
//  | transcode (mp3/ogg) files in the cache. It is advisable to set the     |
//  | expire time to at least the expected download or record time.          |
//  | When setting the expire value to 0 these files will only expire if the |
//  | cache exceeded the max size (ordered by idle time)                     |
//  +------------------------------------------------------------------------+
$cfg['cache_max_size']              = 100 * 1073741824; // 100 GiB
$cfg['cache_expire_wav']            = 3600;
$cfg['cache_expire_pack']           = 3600 * 4;



//  +------------------------------------------------------------------------+
//  | Image                                                                  |
//  +------------------------------------------------------------------------+
//  | $cfg['image_read_embedded'] = true;                                    |
//  | Read embeded APIC or PICTURE image from first media file if no other   |
//  | image is found.                                                        |
//  |                                                                        |
//  | $cfg['image_share'] = true;                                            |
//  | Share image for another forum or website.                              |
//  | See the webinterface for the BB-Code, HTML-Code or URL only.           |
//  |                                                                        |
//  | $cfg['image_share_mode'] = 'mode';                                     |
//  | played: Recently played or streamed album.                             |
//  | new: New album.                                                        |
//  +------------------------------------------------------------------------+
$cfg['image_read_embedded']         = false;
$cfg['image_share']                 = true;
$cfg['image_share_mode']            = 'played';
$cfg['image_front']                 = 'cd_front';
$cfg['image_back']                  = 'cd_back';
$cfg['image_front_cover_treshold']  = 300 * 300;



//  +------------------------------------------------------------------------+
//  | PDF cover                                                              |
//  +------------------------------------------------------------------------+
//  | true: View the PDF cover inline.                                       |
//  | false: Force downloading the PDF cover.                                |
//  +------------------------------------------------------------------------+
$cfg['pdf_inline']                  = true;



//  +------------------------------------------------------------------------+
//  | Image service                                                          |
//  +------------------------------------------------------------------------+
//  | For the Amazon web service a AWSAccessKeyId and AWSSecretAccessKey is  |
//  | needed. Get these free from: http://aws.amazon.com                     |
//  +------------------------------------------------------------------------+
/*
$cfg['AWSAccessKeyId']	            = '';
$cfg['AWSSecretAccessKey']          = '';
$cfg['image_service_name'][]        = 'Amazon';
$cfg['image_service_url'][]         = 'http://ecs.amazonaws.com/onca/xml?Service=AWSECommerceService&AWSAccessKeyId=%awsaccesskeyid&Operation=ItemSearch&ResponseGroup=Images&SearchIndex=Music&Type=Lite&Artist=%artist&Title=%album&Timestamp=%timestamp';
$cfg['image_service_preg'][]        = '';

$cfg['image_service_name'][]        = 'Amazon (uk)';
$cfg['image_service_url'][]         = 'http://ecs.amazonaws.co.uk/onca/xml?Service=AWSECommerceService&AWSAccessKeyId=%awsaccesskeyid&Operation=ItemSearch&ResponseGroup=Images&SearchIndex=Music&Type=Lite&Artist=%artist&Title=%album&Timestamp=%timestamp';
$cfg['image_service_preg'][]        = '';

$cfg['image_service_name'][]        = 'Amazon (de)';
$cfg['image_service_url'][]         = 'http://ecs.amazonaws.de/onca/xml?Service=AWSECommerceService&AWSAccessKeyId=%awsaccesskeyid&Operation=ItemSearch&ResponseGroup=Images&SearchIndex=Music&Type=Lite&Artist=%artist&Title=%album&Timestamp=%timestamp';
$cfg['image_service_preg'][]        = '';
*/

$cfg['image_service_name'][]        = 'Slothradio';
$cfg['image_service_url'][]         = 'http://www.slothradio.com/covers/?adv=1&artist=%artist&album=%album&genre=p&imgsize=x&locale=us&sort=salesrank';
$cfg['image_service_preg'][]        = '#<!-- RESULT ITEM START -->.+?><img src="(http://.+?)" width="([0-9]+?)" height="([0-9]+?)"#s';

$cfg['image_service_name'][]        = 'Slothradio (uk)';
$cfg['image_service_url'][]         = 'http://www.slothradio.com/covers/?adv=1&artist=%artist&album=%album&genre=p&imgsize=x&locale=uk&sort=salesrank';
$cfg['image_service_preg'][]        = '#<!-- RESULT ITEM START -->.+?><img src="(http://.+?)" width="([0-9]+?)" height="([0-9]+?)"#s';

$cfg['image_service_name'][]        = 'Slothradio (de)';
$cfg['image_service_url'][]         = 'http://www.slothradio.com/covers/?adv=1&artist=%artist&album=%album&genre=p&imgsize=x&locale=de&sort=salesrank';
$cfg['image_service_preg'][]        = '#<!-- RESULT ITEM START -->.+?><img src="(http://.+?)" width="([0-9]+?)" height="([0-9]+?)"#s';



//  +------------------------------------------------------------------------+
//  | No album artist                                                        |
//  +------------------------------------------------------------------------+
$cfg['no_album_artist'][]           = 'compilation';
$cfg['no_album_artist'][]           = 'radio';
$cfg['no_album_artist'][]           = 'remix';
$cfg['no_album_artist'][]           = 'singles';
$cfg['no_album_artist'][]           = 'various';



//  +------------------------------------------------------------------------+
//  | Auto suggest limit (search results)                                    |
//  +------------------------------------------------------------------------+
$cfg['autosuggest_limit']           = 25;



//  +------------------------------------------------------------------------+
//  | Media extensions                                                       |
//  +------------------------------------------------------------------------+
$cfg['media_extension'][]           = 'aac';
$cfg['media_extension'][]           = 'ape';
$cfg['media_extension'][]           = 'asf';
$cfg['media_extension'][]           = 'avi';
$cfg['media_extension'][]           = 'flac';
$cfg['media_extension'][]           = 'm4a';
$cfg['media_extension'][]           = 'm4v';
$cfg['media_extension'][]           = 'mp3';
$cfg['media_extension'][]           = 'mp4';
$cfg['media_extension'][]           = 'mpc';
$cfg['media_extension'][]           = 'mpeg';
$cfg['media_extension'][]           = 'mpg';
$cfg['media_extension'][]           = 'ogg';
$cfg['media_extension'][]           = 'swf';
$cfg['media_extension'][]           = 'tta';
$cfg['media_extension'][]           = 'wma';
$cfg['media_extension'][]           = 'wmv';
$cfg['media_extension'][]           = 'wv';



//  +------------------------------------------------------------------------+
//  | Search internet                                                        |
//  +------------------------------------------------------------------------+
$cfg['search_name'][]               = 'allmusic';
$cfg['search_url_artist'][]         = 'http://www.allmusic.com/cg/amg.dll?P=amg&opt1=1&sql=';
$cfg['search_url_album'][]          = 'http://www.allmusic.com/cg/amg.dll?P=amg&opt1=2&sql=';
$cfg['search_methode'][]            = 'post';

$cfg['search_name'][]               = 'Last.fm';
$cfg['search_url_artist'][]         = 'http://www.last.fm/search?m=artists&q=';
$cfg['search_url_album'][]          = 'http://www.last.fm/search?m=albums&q=';
$cfg['search_methode'][]            = 'get';

$cfg['search_name'][]               = 'MusicMeter';
$cfg['search_url_artist'][]         = 'http://www.musicmeter.nl/album/search/?search[artist]=';
$cfg['search_url_album'][]          = 'http://www.musicmeter.nl/album/search/?search[title]=';
$cfg['search_methode'][]            = 'post';

$cfg['search_name'][]               = 'Rate your music';
$cfg['search_url_artist'][]         = 'http://rateyourmusic.com/search?type=a&searchterm=';
$cfg['search_url_album'][]          = 'http://rateyourmusic.com/search?type=l&searchterm=';
$cfg['search_methode'][]            = 'get';



//  +------------------------------------------------------------------------+
//  | Internet ip tools                                                      |
//  +------------------------------------------------------------------------+
$cfg['ip_tools']                    = 'http://www.dnsstuff.com/tools/ipall/?tool_id=67&ip=';



//  +------------------------------------------------------------------------+
//  | Download album (with 7-Zip)                                            |
//  +------------------------------------------------------------------------+
//  | The $cfg['default_charset'] is converted to UTF-8 so that              |
//  | -scs should always be set to UTF-8                                     |
//  |                                                                        |
//  | http://www.7-zip.org                                                   |
//  +------------------------------------------------------------------------+
$cfg['download_album_extension']    = 'zip';
$cfg['download_album_pack']         = $cfg['codec_dir'] . '7za a -mx0 -tzip -scsutf-8 %destination @%list';



//  +------------------------------------------------------------------------+
//  | Record (with CDRDAO)                                                   |
//  +------------------------------------------------------------------------+
//  | Use "cdrdao scanbus" from the cli to see a list with cdrom devices.    |
//  | Set the disired device with --device x,x,x in $cfg['record']           |
//  |                                                                        |
//  | http://sourceforge.net/projects/cdrdao/                                |
//  +------------------------------------------------------------------------+
$cfg['record']                      = $cfg['codec_dir'] . 'cdrdao write --device 1,1,0 --driver generic-mmc --eject --force -n %tocfile';
$cfg['record_cdtext']               = false;



//  +------------------------------------------------------------------------+
//  | Decode (for stream, download & record)                                 |
//  +------------------------------------------------------------------------+
$cfg['decode_stdout']['aac']        = $cfg['codec_dir'] . 'faad -d -o - %source';
$cfg['decode_stdout']['ape']        = $cfg['codec_dir'] . 'macpipe %source - -d';
$cfg['decode_stdout']['flac']       = $cfg['codec_dir'] . 'flac --decode --totally-silent --stdout %source';
$cfg['decode_stdout']['m4a']        = $cfg['codec_dir'] . 'faad -d -o - %source';
$cfg['decode_stdout']['mp3']        = $cfg['codec_dir'] . 'lame --decode --silent %source -';
$cfg['decode_stdout']['mpc']        = $cfg['codec_dir'] . 'mpcdec %source -';
$cfg['decode_stdout']['ogg']        = $cfg['codec_dir'] . 'oggdec --dither 3 --downmix --stdout %source';
$cfg['decode_stdout']['tta']        = $cfg['codec_dir'] . 'ttaenc -d -o - %source';
$cfg['decode_stdout']['wma']        = $cfg['codec_dir'] . 'wmadec -w -q %source';
$cfg['decode_stdout']['wv']         = $cfg['codec_dir'] . 'wvunpack -q %source -';



//  +------------------------------------------------------------------------+
//  | Encode (for stream & download)                                         |
//  +------------------------------------------------------------------------+
//  | For ID TAGS the following variables can be used:                       |
//  | %artist, %title, %album, %year, %comment, %disc, %track & %combined    |
//  |                                                                        |
//  | encode_image is optional and will be used with transcoding when there  |
//  | is an image available in the database. The image can be added with     |
//  | %image. Requires LAME 3.98 or patched LAME 3.97 by Nyaochi's           |
//  +------------------------------------------------------------------------+
$cfg['transcode_treshold']          = 150;

$cfg['encode_extension'][]          = 'mp3';
$cfg['encode_mime_type'][]          = 'audio/mpeg';
$cfg['encode_name'][]               = 'MP3 @ Low';
$cfg['encode_stdout'][]             = $cfg['codec_dir'] . 'lame --abr 64 --quiet --id3v2-only --noreplaygain --ta %artist --tt %title --tl %album --ty %year --tn %combined --tc %comment - -';
$cfg['encode_file'][]               = $cfg['codec_dir'] . 'lame --abr 64 --quiet --id3v2-only --replaygain-accurate --ta %artist --tt %title --tl %album --ty %year --tn %combined --tc %comment - %destination';
$cfg['encode_image'][]              = $cfg['codec_dir'] . 'lame --abr 64 --quiet --id3v2-only --replaygain-accurate --ti %image --ta %artist --tt %title --tl %album --ty %year --tn %combined --tc %comment - %destination';
$cfg['encode_bitrate'][]            = 64000;
$cfg['encode_vbr'][] 	            = true;

$cfg['encode_extension'][]          = 'mp3';
$cfg['encode_mime_type'][]          = 'audio/mpeg';
$cfg['encode_name'][]               = 'MP3 @ Portable';
$cfg['encode_stdout'][]             = $cfg['codec_dir'] . 'lame -V5 --quiet --id3v2-only --noreplaygain --ta %artist --tt %title --tl %album --ty %year --tn %combined --tc %comment - -';
$cfg['encode_file'][]               = $cfg['codec_dir'] . 'lame -V5 --quiet --id3v2-only --replaygain-accurate --ta %artist --tt %title --tl %album --ty %year --tn %combined --tc %comment - %destination';
$cfg['encode_image'][]              = $cfg['codec_dir'] . 'lame -V5 --quiet --id3v2-only --replaygain-accurate --ti %image --ta %artist --tt %title --tl %album --ty %year --tn %combined --tc %comment - %destination';
$cfg['encode_bitrate'][]            = 128000;
$cfg['encode_vbr'][] 	            = true;

$cfg['encode_extension'][]          = 'mp3';
$cfg['encode_mime_type'][]          = 'audio/mpeg';
$cfg['encode_name'][]               = 'MP3 @ HiFi';
$cfg['encode_stdout'][]             = $cfg['codec_dir'] . 'lame -V2 --quiet --id3v2-only --noreplaygain --ta %artist --tt %title --tl %album --ty %year --tn %combined --tc %comment - -';
$cfg['encode_file'][]               = $cfg['codec_dir'] . 'lame -V2 --quiet --id3v2-only --replaygain-accurate --ta %artist --tt %title --tl %album --ty %year --tn %combined --tc %comment - %destination';
$cfg['encode_image'][]              = $cfg['codec_dir'] . 'lame -V2 --quiet --id3v2-only --replaygain-accurate --ti %image --ta %artist --tt %title --tl %album --ty %year --tn %combined --tc %comment - %destination';
$cfg['encode_bitrate'][]            = 190000;
$cfg['encode_vbr'][] 	            = true;

/*
$cfg['encode_extension'][]          = 'ogg';
$cfg['encode_mime_type'][]          = 'application/x-ogg';
$cfg['encode_name'][]               = 'OGG @ Low';
$cfg['encode_stdout'][]             = $cfg['codec_dir'] . 'oggenc --quality 0 --quiet --title %title --artist %artist --album %album --date %year --tracknum %combined --comment comment=%comment --output - -';
$cfg['encode_file'][]               = $cfg['codec_dir'] . 'oggenc --quality 0 --quiet --title %title --artist %artist --album %album --date %year --tracknum %combined --comment comment=%comment --output %destination -';
$cfg['encode_image'][]              = '';
$cfg['encode_bitrate'][]            = 64000;
$cfg['encode_vbr'][] 	            = true;

$cfg['encode_extension'][]          = 'ogg';
$cfg['encode_mime_type'][]          = 'application/x-ogg';
$cfg['encode_name'][]               = 'OGG @ Portable';
$cfg['encode_stdout'][]             = $cfg['codec_dir'] . 'oggenc --quality 4 --quiet --title %title --artist %artist --album %album --date %year --tracknum %combined --comment comment=%comment --output - -';
$cfg['encode_file'][]               = $cfg['codec_dir'] . 'oggenc --quality 4 --quiet --title %title --artist %artist --album %album --date %year --tracknum %combined --comment comment=%comment --output %destination -';
$cfg['encode_image'][]              = '';
$cfg['encode_bitrate'][]            = 128000;
$cfg['encode_vbr'][] 	            = true;

$cfg['encode_extension'][]          = 'ogg';
$cfg['encode_mime_type'][]          = 'application/x-ogg';
$cfg['encode_name'][]               = 'OGG @ HiFi';
$cfg['encode_stdout'][]             = $cfg['codec_dir'] . 'oggenc --quality 6 --quiet --title %title --artist %artist --album %album --date %year --tracknum %combined --comment comment=%comment --output - -';
$cfg['encode_file'][]               = $cfg['codec_dir'] . 'oggenc --quality 6 --quiet --title %title --artist %artist --album %album --date %year --tracknum %combined --comment comment=%comment --output %destination -';
$cfg['encode_image'][]              = '';
$cfg['encode_bitrate'][]            = 192000;
$cfg['encode_vbr'][] 	            = true;
*/



//  +------------------------------------------------------------------------+
//  | Default charset                                                        |
//  +------------------------------------------------------------------------+
$cfg['default_charset']             = 'ISO-8859-1';



//  +------------------------------------------------------------------------+
//  | MySQLi configuration                                                   |
//  +------------------------------------------------------------------------+
$cfg['mysqli_host']                 = 'localhost';
$cfg['mysqli_db']                   = 'netjukebox';
$cfg['mysqli_user']                 = 'root';
$cfg['mysqli_password']             = '***********';
$cfg['mysqli_socket']               = '';



//  +------------------------------------------------------------------------+
//  | Authenticate                                                           |
//  +------------------------------------------------------------------------+
$cfg['anonymous_user']              = 'anonymous';
$cfg['session_lifetime']            = 3600 * 24 * 7;
$cfg['login_delay']                 = 2000;



//  +------------------------------------------------------------------------+
//  | Admin message                                                          |
//  +------------------------------------------------------------------------+
//  | [br]                                                                   |
//  | [b]bold[/b]                                                            |
//  | [i]italic[/i]                                                          |
//  | [img]small_back.png[/img]                                              |
//  | [url]http://www.example.com[/url]                                      |
//  | [url=http://www.example.com]example[/url]                              |
//  | [email]info@example.com[/email]                                        |
//  | [list][*]first[*]second[/list]                                         |
//  +------------------------------------------------------------------------+
$cfg['admin_about_message']         = '';
$cfg['admin_login_message']         = '';



//  +------------------------------------------------------------------------+
//  | Date & time                                                            |
//  +------------------------------------------------------------------------+
//  | When enabled ignore_dst_changes ignores daylight savings time changes. |
//  | The date_format syntax is identical to the PHP date() function.        |
//  +------------------------------------------------------------------------+
$cfg['ignore_dst_changes']          = true;
$cfg['date_format']                 = 'r';



//  +------------------------------------------------------------------------+
//  | Debug                                                                  |
//  +------------------------------------------------------------------------+
$cfg['debug_message']               = false;
$cfg['php_info']                    = false;
?>
PLEASE HELP!
jeremy
User
Posts: 36
Joined: Sun Apr 27, 2008 9:15 am

Re: UPDATE NETJUKEBOX WINDOWS 7

Post by jeremy »

I'm running everything find on Windows 7, and I don't see anything wrong with the syntax of your media directory. Did you get this working?
nelsonliu
User
Posts: 2
Joined: Fri Apr 30, 2010 2:57 am

Re: UPDATE NETJUKEBOX WINDOWS 7

Post by nelsonliu »

yes..i did. all i had to do was logout and log back in. Can you explain how to access netjukebox from a remote computer, not the host?
THANKS!
jeremy
User
Posts: 36
Joined: Sun Apr 27, 2008 9:15 am

Re: UPDATE NETJUKEBOX WINDOWS 7

Post by jeremy »

Don't know if you got this sorted or not, but you'll want to investigate the "port forwarding" feature of your router. This site may be of some help...

http://portforward.com/
Locked