Jump to content
Sign in to follow this  
man-machine

osPlayer v2

Recommended Posts

For all those who can play the files correctly on admin but then just get a "-" in the category results, this is the problem i had.

 

I read about the problems with mp3/ or /mp3/ in the includes/configure.php, but the best way to know where the problem is, is to write the following code in catalog/product_info.php. I´ll describe it precisely.

 

The manual says:

 

Line 72 : after

$product_info_query = tep_db_query("select p.products_id, pd.products_name, pd.products_description, p.products_model, p.products_quantity, p.products_image, pd.products_url, p.products_price, p.products_tax_class_id, p.products_date_added, p.products_date_available, p.manufacturers_id from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd where p.products_status = '1' and p.products_id = '" . (int)$HTTP_GET_VARS['products_id'] . "' and pd.products_id = p.products_id and pd.language_id = '" . (int)$languages_id . "'");

$product_info = tep_db_fetch_array($product_info_query);

 

Add :

/// osplayer v2 start

$product_mp3['folder'] = tep_get_mp3_folder($product_info['products_id']) ;

/// osplayer v2 end

 

Well, all you have to do is write this phrase under $product_mp3['folder']= ....... so you have it like this:

 

	$product_info_query = tep_db_query("select p.products_id, pd.products_name, pd.products_description, p.products_model, p.products_quantity, p.products_image, pd.products_url, p.products_price, p.products_tax_class_id, p.products_date_added, p.products_date_available, p.manufacturers_id from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd where p.products_status = '1' and p.products_id = '" . (int)$HTTP_GET_VARS['products_id'] . "' and pd.products_id = p.products_id and pd.language_id = '" . (int)$languages_id . "'");
$product_info = tep_db_fetch_array($product_info_query);

/// osplayer v2 start  
$product_mp3['folder'] = tep_get_mp3_folder($product_info['products_id']); 
echo DIR_FS_CATALOG_MP3 . $product_mp3['folder'];
/// osplayer v2 end

 

With this sentence, when you click on a product, before the title of the product you'll see the entire path of the folder where the OscPlayer searches the MP3, so check all the "/" and the root.

 

In my personal case, the problem is that i installed OscPlayer firstly as a localhost, and in includes/configure.php i forgot to change the "define('DIR_FS_CATALOG" so i had the path in my webserver as "C:\appserv\www\web", and not the folder of the webserver. I'm idiot, i know, but i hope this can help anyone :D

Share this post


Link to post
Share on other sites

I seem to be having problems with this when I enable https.

 

I've had it working nicely up until now, but now i've secured the site when I go to add a new mp3 folder it throws me out - no error message or anything, it just takes me back to the login page for the Administration Access Level Account that I've got added to the site. If I then disable https (through admin/includes/configure.php) it works again. I have had a quick look through the code, but if anyone's got any pointers (as there's a lot of code there) it would be apreciated, or has anyone had this problem before?

 

 

 

Also, does anyone know how to change it so that it uses the Product Model for the file name rather than the prouct name? This would be much more useful for me and also cut down on the risk of adding 'daft' characters to the file name that the server doesn't like (such as '/' which caused a few problems.)

Share this post


Link to post
Share on other sites

<vent>

What the #$&^ is up with IE 7 that every other browser in the world works but it?!

</vent>

 

So osPlayer works quite nicely... except in IE.

 

Has anyone run into this issue and resolved it?

 

Haven't put much time in to getting it sussed as of yet (as I just found the problem). Hoping someone may just know the answer.

 

If I figure it out before a reply I'll post here.

 

Thanks,

Iggy


Everything's funny but nothing's a joke...

Share this post


Link to post
Share on other sites
<vent>

What the #$&^ is up with IE 7 that every other browser in the world works but it?!

</vent>

 

So osPlayer works quite nicely... except in IE.

 

Has anyone run into this issue and resolved it?

 

Haven't put much time in to getting it sussed as of yet (as I just found the problem). Hoping someone may just know the answer.

 

If I figure it out before a reply I'll post here.

 

Thanks,

Iggy

 

My bad. It seems that, although this is a new XP install and IE was brought up to 7, it still had Flash 6 (?!) installed. Updated the Flash Player and all was well. Sorry for the post.

 

Iggy


Everything's funny but nothing's a joke...

Share this post


Link to post
Share on other sites
Where do I download this?

 

OsPlayer

 

Grab the OSPLAYER 2.1 con idioma Español version

 

Iggy


Everything's funny but nothing's a joke...

Share this post


Link to post
Share on other sites
For all those who can play the files correctly on admin but then just get a "-" in the category results, this is the problem i had.

 

I read about the problems with mp3/ or /mp3/ in the includes/configure.php, but the best way to know where the problem is, is to write the following code in catalog/product_info.php. I´ll describe it precisely.

 

The manual says:

Well, all you have to do is write this phrase under $product_mp3['folder']= ....... so you have it like this:

 

	$product_info_query = tep_db_query("select p.products_id, pd.products_name, pd.products_description, p.products_model, p.products_quantity, p.products_image, pd.products_url, p.products_price, p.products_tax_class_id, p.products_date_added, p.products_date_available, p.manufacturers_id from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd where p.products_status = '1' and p.products_id = '" . (int)$HTTP_GET_VARS['products_id'] . "' and pd.products_id = p.products_id and pd.language_id = '" . (int)$languages_id . "'");
$product_info = tep_db_fetch_array($product_info_query);

/// osplayer v2 start  
$product_mp3['folder'] = tep_get_mp3_folder($product_info['products_id']); 
echo DIR_FS_CATALOG_MP3 . $product_mp3['folder'];
/// osplayer v2 end

 

With this sentence, when you click on a product, before the title of the product you'll see the entire path of the folder where the OscPlayer searches the MP3, so check all the "/" and the root.

 

In my personal case, the problem is that i installed OscPlayer firstly as a localhost, and in includes/configure.php i forgot to change the "define('DIR_FS_CATALOG" so i had the path in my webserver as "C:\appserv\www\web", and not the folder of the webserver. I'm idiot, i know, but i hope this can help anyone :D

 

 

I like this one, the path show but the player didn't play, just a quick check, should the path shown ia:

 

home/xx.com/public_html/catalog/data/mp3/xx

 

or

 

http://www.xx.com/catalog/data/mp3/xx

 

??

 

another thing is will lacking of one "/" be the reason the folder cannot be located?? i.e. could it should be something:

 

home/xx.com/public_html/catalog/data/mp3/xx[red]/[/red]

 

i am trouble shooting to figure out what's go wrong~~appreciate if any successor can help.

 

Thank you.

Share this post


Link to post
Share on other sites

i figure this out when i go back to admin page, where the path is shown,

 

/home/xxx/public_html/catalog/data/mp3/xxx/

 

this is great as i now have the same path shown in both catalog and admin mp3 manager where i am comfortable that the path is definately correct.

 

the only problem is: the player still can't locate the mp3 at catalog whereas the mp3 is played at admin site.

 

<_< <_<

Share this post


Link to post
Share on other sites

I was having the same sound problem on my catalog page.

 

Here is my fix

Find this line in your configure.php

 

// osCPlayer v2 player start

define('DIR_FS_CATALOG_MP3', DIR_FS_CATALOG . '/data/mp3/');

define('DIR_WS_CATALOG_MP3', DIR_WS_CATALOG . '/data/mp3/');

// osCPlayer v2 player end

 

and replace with

 

// osCPlayer v2 player start

define('DIR_FS_CATALOG_MP3', DIR_FS_CATALOG . '/data/mp3/');

define('DIR_WS_CATALOG_MP3', '/data/mp3/');

// osCPlayer v2 player end

 

 

hope this helps

 

Peace


Using IE6 with today’s websites is like driving a horse and buggy in New York City during rush hour traffic and expecting everyone else to accommodate to you. It’s simply time to upgrade.

Share this post


Link to post
Share on other sites
I was having the same sound problem on my catalog page.

 

Here is my fix

Find this line in your configure.php

 

// osCPlayer v2 player start

define('DIR_FS_CATALOG_MP3', DIR_FS_CATALOG . '/data/mp3/');

define('DIR_WS_CATALOG_MP3', DIR_WS_CATALOG . '/data/mp3/');

// osCPlayer v2 player end

 

and replace with

 

// osCPlayer v2 player start

define('DIR_FS_CATALOG_MP3', DIR_FS_CATALOG . '/data/mp3/');

define('DIR_WS_CATALOG_MP3', '/data/mp3/');

// osCPlayer v2 player end

hope this helps

 

Peace

 

Thanks, unfortunately no diff is noted at my end, i guess is how is the configure part at the top. i even by pass all the DIR_WS_CATALOG by showing the exact path,i.e.:

 

define('DIR_WS_CATALOG_MP3', 'http://www.xx.com/catalog/data/mp3/');

 

But still doesn't work. The data & mp3 folder permission already set to 777, there are people saying that the .htaccess file mght stop the mp3 fpr loading...i think i shall pay concentration on this, but does anyone know how would .htaccess stop the mp3 from playing??

Share this post


Link to post
Share on other sites
Thanks for the great add-on!

 

I've got a completely different question. Is there a way to integrate "Buy Now" or add to cart buttons to player?

 

How would you integrate an online shop to each singer playlist when your users want to listen to music and buy the same singers album ?

 

Thanks

Share this post


Link to post
Share on other sites
I like this one, the path show but the player didn't play, just a quick check, should the path shown ia:

 

home/xx.com/public_html/catalog/data/mp3/xx

 

or

 

http://www.xx.com/catalog/data/mp3/xx

 

??

 

another thing is will lacking of one "/" be the reason the folder cannot be located?? i.e. could it should be something:

 

home/xx.com/public_html/catalog/data/mp3/xx[red]/[/red]

 

i am trouble shooting to figure out what's go wrong~~appreciate if any successor can help.

 

Thank you.

 

I use back the same trick to check for my accuracy of WS catalog MP3

 

echo DIR_WS_CATALOG_MP3 . $product_mp3['folder'];

 

and successful to ensure the path is correct:

 

http://www.xx.com/catalog/data/mp3/xxx/

 

but the mp3 still didn play..

Edited by day2

Share this post


Link to post
Share on other sites
I was having the same sound problem on my catalog page.

 

Here is my fix

Find this line in your configure.php

 

// osCPlayer v2 player start

define('DIR_FS_CATALOG_MP3', DIR_FS_CATALOG . '/data/mp3/');

define('DIR_WS_CATALOG_MP3', DIR_WS_CATALOG . '/data/mp3/');

// osCPlayer v2 player end

 

and replace with

 

// osCPlayer v2 player start

define('DIR_FS_CATALOG_MP3', DIR_FS_CATALOG . '/data/mp3/');

define('DIR_WS_CATALOG_MP3', '/data/mp3/');

// osCPlayer v2 player end

hope this helps

 

Peace

 

This did the trick for me! Thanks!!! When I first installed the player everything was working fine, and when I moved to another server I started having trouble with the sound in catalog. Tried everything, but this did it for me.

 

I wanted to mention that I had a hard time installing this great contribution the first time, until I used one of those programs to compare files and then it was very easy to make the changes I needed without screwing other contributions up.

 

I love how helpful people are on these forums!!!

 

jailaxmi

Edited by jailaxmi

I repeat myself when under stress, I repeat myself when under stress, I repeat myself...

 

--King Crimson (“Discipline”)

Share this post


Link to post
Share on other sites

OK, this has nothing to do with the installation of OsPlayer, and if this isn't the right place to post this, please redirect me.

 

The issue that recently came up with the OsPlayer is that my ScanAlert service is saying that there is a possible cross-site scripting vulnerability with the OsPlayer script, and I am wondering if anyone has had to deal with this too.

 

Since I am no coder, I am very confused as to what should be changed, where and how, and even after reading all the material they referred me to I cannot see how this javascript could allow cross-site scripting and if so, how to fix it.

 

Anyway, any help would be greatly appreciated! :'(

 

Thanks,

 

jailaxmi


I repeat myself when under stress, I repeat myself when under stress, I repeat myself...

 

--King Crimson (“Discipline”)

Share this post


Link to post
Share on other sites
Hi floppy...

 

Need your urgent help! You say you set it up with Register_Globals Off - How? I need to get this working on my site, but I need to keep Register_Globals off. I have the same error. No info is written to the SQL database products_mp3, and the mp3manager.php page just refreshes with no error and no info carried accross from the product page. Help! If you could send me info re the register_globals issue and perhaps a copy of your mp3manager.php code would be most grateful - or any help!!! Anyone???

 

Thanks in advance.

 

Did either of you solve this??

This has been driving me nuts!!

Can't create folders, can't upload files

 

Help!!

Share this post


Link to post
Share on other sites

Does anyone know if it is posible to increase the size of the characters from 25 to maybe 40 ? I tried changing this line.

 

size="25" maxlength="25"

 

to

 

size="40" maxlength="40"

 

It created it but then I create the folder it says success but then I get this error.

 

There isn't any mp3 folder for this product !

Clic the button below to create one . Folder will look like this : (Create Button) I click it and then

 

I click the button and then get another error

 

ROOT_FOLDER_ERROR

 

What can I do to fix this?

Share this post


Link to post
Share on other sites
Does anyone know if it is posible to increase the size of the characters from 25 to maybe 40 ? I tried changing this line.

 

size="25" maxlength="25"

 

to

 

size="40" maxlength="40"

 

It created it but then I create the folder it says success but then I get this error.

 

There isn't any mp3 folder for this product !

Clic the button below to create one . Folder will look like this : (Create Button) I click it and then

 

I click the button and then get another error

 

ROOT_FOLDER_ERROR

 

What can I do to fix this?

Anyone ?

Share this post


Link to post
Share on other sites

Sorry, No idea, but I wonder if you or anybody else knows how to fix an access issue, once I click on the mp3manager button it directs me to the page stating access denied.

I changed every new file and folder to chmod 777, and I am just not sure what to do next.

 

I tried to comment out most of the mp3manager.php file, and still not hope until I removed the require application_top.php file os it worked once I comment out the " require('includes/application_top.php');" I mean did not give me the access denied any more, but I have to get the mp3manager back to work, and I am not sure what to do next, any clue?

 

Any idea or comment will help.

 

Thanks,

Dun.

Share this post


Link to post
Share on other sites

Hi All,

Does anybody solved the issue of having osplayer play a 30, 60 seconds preview of the complete mp3 file.

I am trying to mount a Karaoke Shop, and would like to have a 60 seconds preview of the song (osplayer streaming only the first 60 seconds of the complete downloable file), without having to make another demo file.

 

Could it be possible, decompiling the swf into fla, and reprogram?

Thanks.

Share this post


Link to post
Share on other sites

Hi All,

Does anybody solved the issue of having osplayer play a 30, 60 seconds preview of the complete mp3 file.

I am trying to mount a Karaoke Shop, and would like to have a 60 seconds preview of the song (osplayer streaming only the first 60 seconds of the complete downloable file), without having to make another demo file.

 

Could it be possible, decompiling the swf into fla, and reprogram?

Thanks.

Share this post


Link to post
Share on other sites

The FLA is available on the contribution page, if I'm not mistaken its in the Spanish version.


Using IE6 with today’s websites is like driving a horse and buggy in New York City during rush hour traffic and expecting everyone else to accommodate to you. It’s simply time to upgrade.

Share this post


Link to post
Share on other sites

I'm getting an error that drives me nuts, I think I need to scrap this and use a program that works correctly.

 

 

In the admin section it works fine for the first mp3 files I upload to the first directory

 

Then I create another product, and click Mp3 manager

 

It says Folder not created - create folder?

 

I click yes

 

 

it says folder success, please click continue

 

I click continue and the dumb thing goes right back to "No folder created - create folder?

 

The folder is fine, why can't the program recognize a folder it created 5 seconds ago?

Share this post


Link to post
Share on other sites

I just don't get it, maybe if your folder name is too large it doesn't work right

 

Because i went right back, added another produce, and used a different name and it suddenly works again, but for product id50 no matter what i do it refuses to recognize the directory.

 

Odd, but for online stores you should have support for big folder names. Every name of a product I have in my store is going to have a big name because it's the Artist - Cd name

Share this post


Link to post
Share on other sites
I just don't get it, maybe if your folder name is too large it doesn't work right

 

Because i went right back, added another produce, and used a different name and it suddenly works again, but for product id50 no matter what i do it refuses to recognize the directory.

 

Odd, but for online stores you should have support for big folder names. Every name of a product I have in my store is going to have a big name because it's the Artist - Cd name

Yes it looks like you cannot make the folder name to big because if not it does not create it even though the next screen says it does but after that screen you would receive another one with a error. I had posted here at the top on July 30 if anyone knew how to fix that problem, for now I have to put the folder names smaller.

Edited by tegralens

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×