SCM Music Player for SMF

Started by dougiefresh, January 10, 2017, 04:22:47 AM

Previous topic - Next topic

dougiefresh

Link to Mod



SCM MUSIC PLAYER FOR SMF v2.6
By Dougiefresh -> Link to Mod



Introduction
This mod adds the ability to start playing MP3, WAV or OGG file(s) in the background automatically using the SMC Media Player.

Admin Settings
Under Admin => Configuration => Modification Settings, there is a new section called SCM Music Player.  In that area, many settings of this mod can be controlled, such as:
> Enable playing background music?
> Background music volume level
> Autoplay the background music?
> Shuffle music playlist before starting?
> Repeat mode:
> Placement of Player Bar
> Show playlist by default?
> SMC media player skin selection.

With version 1.2, you can disable the player in the following areas:
o On Board Index
o On Message Index
o In Topics
o In My Messages
o In Profile
o In Admin area
o In Moderate area
o In Calendar

There is also a new permission under Admin => Forum => Permissions:
o Listen to Site Music

Related Discussion
o Music Mod?

Compatibility Notes
This mod was tested on SMF 2.0.12, but should work on any version of SMF 2.0.x.  SMF 1.x and SMF 2.1 is not and will not be supported.

Translators
o Spanish Latin: Rock Lee

Changelog
The changelog can be viewed at XPtsp.com.

License
Copyright (c) 2016 - 2019, Douglas Orend
All rights reserved.

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.

2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

4Kstore


¡¡NEW MOD: Sparkles User Names!!!

gaswigg

Hi I think this is a great mod but I see some problems. I have it installed on 4 forums and all 4 have the same problem once this mod is installed.

1 When you login in for admin it takes several times to get logged in This is what I get.
An Error Has Occurred!
Unable to verify referring url. Please go back and try again.

2 When I try and delete a post it comes up with about the same error but I can't remove the post at all no matter how many times I try
An Error Has Occurred!
Unable to verify referring url. Please go back and try again.

This all ends the second I uninstall the mod can you help Im running 2.0.13 on all 4 forums and am using sunset 2.0.1.5 for a theme

Thanks
Glen


perplexed

Hi this is great.  One problem we have is that we would like to hide this from guests and anyone not logged into the forum.  Is it possible to do that?

perplexed

Quote from: perplexed on February 19, 2017, 08:46:10 AM
Hi this is great.  One problem we have is that we would like to hide this from guests and anyone not logged into the forum.  Is it possible to do that?

Hi, is it possible to hide this from guests?

dougiefresh

Uploaded v1.1 - February 22nd, 2017
o Added "Listen To Site Music" permission to the mod.




@gaswigg: This update MAY solve ths issue you are seeing.  I'm not sure, though, because I can't reproduce the bug report.....

Quote from: perplexed on February 19, 2017, 08:46:10 AM
Hi this is great.  One problem we have is that we would like to hide this from guests and anyone not logged into the forum.  Is it possible to do that?
This feature has been added for this version.  Thank you!

perplexed

Quote from: dougiefresh on February 22, 2017, 10:20:31 AM
Uploaded v1.1 - February 22nd, 2017
o Added "Listen To Site Music" permission to the mod.




@gaswigg: This update MAY solve ths issue you are seeing.  I'm not sure, though, because I can't reproduce the bug report.....

Quote from: perplexed on February 19, 2017, 08:46:10 AM
Hi this is great.  One problem we have is that we would like to hide this from guests and anyone not logged into the forum.  Is it possible to do that?
This feature has been added for this version.  Thank you!

That's awesome, thanks so much. I will download it now :)

perplexed

Hi again,

installed the player, everything seems to be working, but members on mobile devices are telling me they can't see the player at all.  Does it work on an ipad?  thanks

dougiefresh

No clue.  I don't own any Apple products....


Dave J

Works good on SMF 2.1 with no errors Dougie
If you want quizzes to add to the new SMF2.1 quiz mod go here . There are also walkthroughs in the forum to explain how to install them and other tips.

dougiefresh

Quote from: perplexed on February 23, 2017, 11:00:18 AM
installed the player, everything seems to be working, but members on mobile devices are telling me they can't see the player at all.  Does it work on an ipad?  thanks
Looks like this is the answer to your question: Playing audio on iPad.  For those too lazy to read the article, the relevant portion is quoted here:
QuoteIn Safari on iOS (for all devices, including iPad), where the user may be on a cellular network and be charged per data unit, preload and autoplay are disabled. No data is loaded until the user initiates it. This means the JavaScript play() and load() methods are also inactive until the user initiates playback, unless the play() or load() method is triggered by user action. In other words, a user-initiated Play button works, but an onLoad="play()" event does not.
Since I don't have a iPhone or iPad (not an Apple fan), I can't test to see if this is the case.

4Kstore

There is a way to only see the player on the index Page?

¡¡NEW MOD: Sparkles User Names!!!

dougiefresh

#13
Quote from: 4Kstore on March 19, 2017, 12:00:52 PM
There is a way to only see the player on the index Page?
No, this mod tends to be a global player for the website, not a single page type....

EDIT:  Let me stare at the code some....  There has to be a way....

dougiefresh

Quote from: MaryLouW on January 09, 2017, 08:51:52 PM
This one works perfectly!!  It's playing on my board right now in another window.  You know the old saying, a woman is NEVER satisfied, right?   Well.. it's true! 

I have one more request for this mod.
It would be nice if I could create song groups.  That is, songs for St. Pat's day, Patriotic, Christmas, New Years, Easter, Valentines, etc.  In each category, I could put songs related to that category, then when I change my board skin for the event, I could also select the song category to go with the theme.

For example, when I install my Christmas theme, I would like to select a list that played only Christmas songs.
When I install the St. Patrick's Day theme, would like to select only Irish music to be played.

Would be good if people could create their own categories and then put the music in the corresponding "folders" on the server. 

Is this possible without a ton of work?
I'm looking into the feature request.  I would think attaching the music to a starting post would be easier, though....  Would that work?

Quote from: dougiefresh on March 19, 2017, 01:35:46 PM
Quote from: 4Kstore on March 19, 2017, 12:00:52 PM
There is a way to only see the player on the index Page?
No, this mod tends to be a global player for the website, not a single page type....

EDIT:  Let me stare at the code some....  There has to be a way....
I'm looking into this feature request as well....

4Kstore


¡¡NEW MOD: Sparkles User Names!!!

dougiefresh

#16
Uploaded v1.2 - March 23th, 2017
o Changed admin area for mod into its own seperate admin area.
o Admin area now has 3 subsections: Settings, Playlists, Skins.
o Added various options to disable player for multiple areas.



Quote from: 4Kstore on March 19, 2017, 12:00:52 PM
There is a way to only see the player on the index Page?
Added options to disable player for board index, message index, in topics, profile, PMs, members page, calendar, admin and moderation areas for the this version.  Attached is a screenshot of the new settings page....  Do I need to add something to disable for portals as well? 

4Kstore

Thanks man, I will test it today.
Great work!

¡¡NEW MOD: Sparkles User Names!!!

nofapturkiye

Okey i am really excited about this mod but there is an error for me , it says this when i try to add track

Fatal error: Call to undefined function safe_serialize() in /home/nofaptur/public_html/Sources/Subs-SCMP_Admin.php on line 201


what i did was to find a  demo.mp3 file on internet and  copy paste  .mp3 link to the  song url part.  Was that wrong to do ?  It would be really helpfull if you be more specific about how to add songs . If this Works i will be super happy for my forum. I am waiting for your answer man


Dave J

Quote from: nofapturkiye on March 26, 2017, 05:04:45 PM
Okey i am really excited about this mod but there is an error for me , it says this when i try to add track

Fatal error: Call to undefined function safe_serialize() in /home/nofaptur/public_html/Sources/Subs-SCMP_Admin.php on line 201


what i did was to find a  demo.mp3 file on internet and  copy paste  .mp3 link to the  song url part.  Was that wrong to do ?  It would be really helpfull if you be more specific about how to add songs . If this Works i will be super happy for my forum. I am waiting for your answer man

Hi

You have to upload a real track and not a link to it. On the setting page, see attachment below, you chose a music file from a location on your hard drive and then upload it.

I should add that the image is taken form my 2.1 test forum, as I have not installed it on live site it might look a bit different.
If you want quizzes to add to the new SMF2.1 quiz mod go here . There are also walkthroughs in the forum to explain how to install them and other tips.

Advertisement: