Kplaylist intergration

Locked
D3M0Nz
Joomla! Fledgling
Joomla! Fledgling
Posts: 3
Joined: Mon Dec 18, 2006 12:59 am

Kplaylist intergration

Post by D3M0Nz » Mon Dec 18, 2006 1:04 am

What im really looking for is a feature to allow me to megre user/pass from kplaylist to Joomla Very much like the PHPBB one. Nice if those two would be able to working together as well.

jjinks
Joomla! Apprentice
Joomla! Apprentice
Posts: 10
Joined: Fri Jan 27, 2006 5:44 pm

Re: Kplaylist intergration

Post by jjinks » Sun May 06, 2007 10:58 pm

I agree, I think it would be a much needed integration.

mehdi
Joomla! Explorer
Joomla! Explorer
Posts: 437
Joined: Tue Oct 04, 2005 3:56 pm

Re: Kplaylist intergration

Post by mehdi » Tue May 08, 2007 4:51 pm

hi,
I never understood well why this script could be interesting ....
There's already some joomla  components that allows to build playlist .
And also what about simple flash that read an xml to display a playlist ?
Customisation of kplaylist looks limited.......

Can I get a clue of what you find seducing in this script ?
Any example of website, that attract lot of visitor with this kind of script ?
You can PM me the examples , if you are affraid  to be accused of spam.

I  *** MAY *** release publically ,  "one day" ,  an integration  (avoid  deception by not expecting anything).
But frankly , I wouldn't distribute a stuff I don't  use myself. Sorry. (otherwise providing support would be hard).
So if I'm not so convinced by the utility of the script, this would hardly happen.
Also, I wonder if there's not better alternatives than kplaylist.

thanks

jjinks
Joomla! Apprentice
Joomla! Apprentice
Posts: 10
Joined: Fri Jan 27, 2006 5:44 pm

Re: Kplaylist intergration

Post by jjinks » Wed May 09, 2007 4:20 pm

I have only used kplaylist for a couple days now, but so far I must strongly disagree with you. I installed and tested over 5 joomla mp3 players and was not satisfied. I still cant find 1 thing I would change about Kplaylist except for Joomla integration.

- Kplaylist allows huge libraries of music
- Its winamp compatible (much better than any embedded player)
- It has search functions
- It has the ability to create custom playlists
- Users can upload their own mp3s
- Creates its own XML file (no programming needed)

Check out my install:
tatown dot com / play

D3M0Nz
Joomla! Fledgling
Joomla! Fledgling
Posts: 3
Joined: Mon Dec 18, 2006 12:59 am

Re: Kplaylist intergration

Post by D3M0Nz » Sun May 27, 2007 3:39 pm

I've been using this script for years and jjinks points out the best features that i havent been able to find in of the products made for joomla

Also wanna add that Kplaylist is supporting icecast(radio) servers now which could be used to create a module
Last edited by D3M0Nz on Wed May 30, 2007 5:54 pm, edited 1 time in total.

mirthen
Joomla! Apprentice
Joomla! Apprentice
Posts: 13
Joined: Sat Jun 23, 2007 6:26 am

Re: Kplaylist intergration

Post by mirthen » Sat Jun 23, 2007 6:38 am

ive been using kplaylist for about 6 months now. the main reasons i like it...(some mentioned above already)

1) supports near infinite music databases, just depends on php settings.
2) supports archive downloading, aka download selected in zip/rar/whatever.
3) full ID3 v1/v2 support.
3) can search, which uses id3 tags, can search album/artist/song so on.
4) tree like view of database, easy to browse music, if they are sorted on hard drive neatly atleast.

the only other free music system ive found that can compare is Zina, which ive used as well, and has module support for most CMS out there, with some joomla support. kplaylist works great in a wrapper, and making a script to import joomla users to kplaylist would not be hard, least as long as the passwords are encrypted the same in the database. atleast with basic users it wouldnt be hard, just have a default template for the database for basic users, then inject the username and password.

if you look on the kplaylist forums there are lots of people who would like it to be made into a module for whatever CMS. the author has mentioned doing it, but so far no support is there for it.

being i am going to be using joomla now, and i am dead set on using kplaylist in it, i will be doing some toying around with a module or something to sync the users to kplaylist from joomla. dont know if it will be a full module, or something just customized for my own setup. but if someone else would like to tackle this, please do as i have no real experience with joomla and would be starting from scratch here :)
Last edited by mirthen on Sat Jun 23, 2007 6:40 am, edited 1 time in total.

mirthen
Joomla! Apprentice
Joomla! Apprentice
Posts: 13
Joined: Sat Jun 23, 2007 6:26 am

Re: Kplaylist intergration

Post by mirthen » Sun Jun 24, 2007 8:27 am

well so far i have added security so only joomla logged in users can access kplaylist in a wrapper. using code here .. http://forum.joomla.org/index.php/topic ... #msg171996

my kplaylist php file(s) looks like this..

Code: Select all

<?php

define( '_VALID_MOS', 1 );

include_once('../globals.php' );
require_once('../configuration.php' );
require_once('../includes/joomla.php' );

$mainframe = new mosMainFrame( $database, $_REQUEST['option'], '.' );
$mainframe->initSession();

$my = $mainframe->getUser();
if ($my->id){
// all the kplaylist content here i just use an include system so its easy to update later..
include('kplaylist.php');
}
?>
this page is a index.php file in a kplaylist sub dir in the joomla directory. the wrapper calls this index file.

next step is users. in the wrapper.php i have started modifying it, not done yet, but here is a basic outline of what im doing...

kplaylist.php settings..
i changed the $cfg['disablelogin'] = 0; to 1 so the login screen is gone.
i change $cfg['assumeuserid'] = 1; so it will read from a cookie which is explained below. anyways it looks like this now...

Code: Select all

if (isset($_COOKIE['kplid'])) {
$cfg['assumeuserid'] = $_COOKIE['kplid'];
} else {
$cfg['assumeuserid'] = 2;
}
now the cookie stuff i will explain in a sec. the else part will eventually point to a user id that is like a "default" account with basic settings. i might also put the disablelogin setting into this if statement, so it will require login if the cookie is missing for some reason, just for added security.

thats it for the kplaylist.php


now changes in the wrapper.php that calls up kplaylist...
a cookie is set to send a user id to kplaylist when the wrapper is first called from joomla. using..

Code: Select all

setcookie('kplid',$kplidvalue);
the $kplidvalue is retrieved from the mysql database where the kplaylist data is stored. using the joomla username it checks if that username is in the kplaylist DB, if it is, then it sets the variable to that users ID, which is sent to the wrapper via the cookie. if that user name is not in the database then it will create a user using preset defaults for all of the kplaylist settings, then pass on the new user id via the cookie. then the kplaylist.php takes over, and that if statement above grabs the user id, sets it to the default. this should work even when multiple people are using it at the same time, since it changes based upon the cookie, so userA and userB both access it at the same time, each one gets their own page since they each have a different cookie.

and thats about it really. its hacked and then hacked again, but thus far it works. it should also be rather easy to replace kplaylist with newer versions in the future using this method since all thats really needed is to change those settings in the kplaylist.php file.

i dont have the wrapper.php part finished yet, but i do have it setting the cookie, and have tested it with different user IDs, each time kplaylist recorded the users and their actions. the ONLY thing ive noticed is that in the users page under admin in kplaylist, it no longer shows if a user is "on/off" since they never actually logged on. but this point is mute since you can see if a user is logged in using joomla.

if no one has any better ideas on this right now, im gonna continue on this path, and perhaps share my modified versions of kplaylist and the wrapper when im done. any feedback would be appreciated on this.

mirthen
Joomla! Apprentice
Joomla! Apprentice
Posts: 13
Joined: Sat Jun 23, 2007 6:26 am

Re: Kplaylist intergration

Post by mirthen » Sun Jun 24, 2007 8:53 am

well, ran into a rather large problem... have to smack myself for not thinking about this prior too. anyways, yeah kplaylist access is nice and secure now... a little too secure... since winamp is unable to get the streams from the downloaded m3u file... being it doesnt have the cookies needed to access joomla.... sigh... atleast the download and archive features still work :)

well i know i can get around this, just a matter of changing even more code. did something similar to zina for another CMS, but dropped that project to work with kplaylist and joomla.

mirthen
Joomla! Apprentice
Joomla! Apprentice
Posts: 13
Joined: Sat Jun 23, 2007 6:26 am

Re: Kplaylist intergration

Post by mirthen » Sun Jun 24, 2007 10:16 pm

i have a way to use the above method, and still allow streams(play). the file that the wrapper calls now looks like this...

Code: Select all

<?php
if (isset($_GET['streamsid']) && isset($_GET['c']) && isset($_GET['stag']) && isset($_GET['file'])) {
include('kplaylist.php');
} else {
	define( '_VALID_MOS', 1 );
	include_once('../globals.php' );
	require_once('../configuration.php' );
	require_once('../includes/joomla.php' );
	$mainframe = new mosMainFrame( $database, $_REQUEST['option'], '.' );
	$mainframe->initSession();
	$my = $mainframe->getUser();
	if ($my->id) {
		include('kplaylist.php');
	} else {
		header("Location: http://myjoomla.site/");
	}
}
?>
 
yeah that last   should be there, or something else that a browser will parse, so the auto height for the wrapper works.

the added part kinda opens a security hole in kplaylist. since if those url vars are set it will bypass the joomla added part. but so far i have not found a way to get into the full kplaylist using all those vars set to anything. it will either try to give you a .m3u file for the stream, or it will just load up a blank page. so not sure how well this keeps kplaylist from public use. i know that anyone with the m3u file can stream the music, regardless of being logged into joomla, but i dont see any way around that to keep allowing winamp and others to stream the music.

im sure i could add a session id or something to the m3u file outputs, so that winamp will send that session id when it requests the mp3's, but i have yet to get into that. doing that will allow the streams, and keep kplaylist restricted to only joomla logged in users.

D3M0Nz
Joomla! Fledgling
Joomla! Fledgling
Posts: 3
Joined: Mon Dec 18, 2006 12:59 am

Re: Kplaylist intergration

Post by D3M0Nz » Mon Jun 25, 2007 3:16 pm

nice work man lovin it so far

aruba
I've been banned!
Posts: 38
Joined: Fri Jun 15, 2007 8:52 pm

Re: Kplaylist intergration

Post by aruba » Tue Jun 26, 2007 8:44 am

have any of you guys looked at jinzora?
http://jinzora.com/

mirthen
Joomla! Apprentice
Joomla! Apprentice
Posts: 13
Joined: Sat Jun 23, 2007 6:26 am

Re: Kplaylist intergration

Post by mirthen » Sat Jul 07, 2007 7:47 am

loading that up now to give it a shot. yeah i would love to see kplaylist integrated into joomla, but if there is something just as good or better out there... yeah i will jump ship :)

mirthen
Joomla! Apprentice
Joomla! Apprentice
Posts: 13
Joined: Sat Jun 23, 2007 6:26 am

Re: Kplaylist intergration

Post by mirthen » Sun Jul 08, 2007 3:35 am

well, i gave it a shot. took me some time to get the hang of its use and admin stuff. in the end, i still prefer to use kplaylist. i am going to scrap doing the wrapper integration of kplaylist, and start with a fresh copy of kplaylist, using the individual files, not the single php file, and do a complete integration of it into joomla. gonna be one hell of a task not knowing much of the kplaylist code and such, but it will keep me busy atleast :)

anyways, about that jinzora, i didnt care much for how it handeled the downloads and such. one of the parts of kplaylist i like is the download features. in jinzora its kinda hidden in the playlist stuff, took me a few hours of messing with it just to figure out how to download multiple files at once in a zip. in kplaylist its all right there, download selected or download album. quite nice. another issue i had with jinzora was the templates n such, half didnt work with joomla, least with defaults. and the other half are just ugly and look quite odd sitting in joomla.

so gonna stick with using kplaylist in a wrapper for now, and will be working away on complete integration of kplaylist 1.7 into joomla. hopefully once i integrate 1.7, it will be easy to modify future versions of kplaylist to integrate them as well. once i have something working to give, i will of course start a extension thread for it so people can test and whatnot.


Locked

Return to “Wishlists and Feature Requests - Archive”