News:

Join the Facebook Fan Page.

Main Menu

Snowflakes

Started by Chen Zhen, December 24, 2018, 06:44:11 AM

Previous topic - Next topic

Chen Zhen

Link to the mod

Snowflakes Display Modification c/o Chen Zhen
Copyright 2014 - 2023, Chen Zhen @ web-develop.ca
Compatible with the SMF 2.0.X & SMF 2.1.X branches
Requirements: PHP 7.1 or better, modern mainstream browser


This installation process will add options to the mod settings template
which will allow an administrator to opt various types of snowflake and animated image scripts.
This will allow all your users to view these scripts on all of your website pages.

Distributed under the GNU Lesser General Public License version 3



Available effects:
  • Four types of snowflakes: Snowflakes, Flurry, Diverse & Snowstorm
  • Fireworks
  • Flying Bats
  • Xmas Lights
  • Xmas Light Strands
  • Xmas Wired Lights
  • Random (some/all of the above)
  • Many more available under the headings of "Diverse" & "Halloween" (ie. rain, leaves, bees, butterflies, doves, etc.)
  • Your own images can be uploaded in the Halloween, Diverse or Xmas Wired Lights options

Available options:
  • Various settings for all of the effects (available when each are selected in the admin)
  • Enable/disable options for:  modification, members, specific actions/sub-actions, mobile or tablet detection
  • Ability to enable/disable JQuery library for the SMF 2.0 branch (ie. disable when already available from another modification)
  • Upload/change images for some of the effects



Version History
---------------
v1.83
+ added: option to disable light effects on vertical cursor range

v1.82
! fixed: save selected image in Snowflakes admin

v1.81
! fixed: abs() no longer supports numeric conversion in PHP 8.0.0+

v1.80
! fixed: check if array is set in HTTP mobile headers function

v1.79
+ added: default actions that render Snowflakes disabled
! removed: redundant/duplicate code from some files
! fixed: majority of the main scripts loaded after the DOM
! fixed: top_section/welcome container detection to hide lights during user interface

v1.78
! fixed: undefined variable concerning current action

v1.77
+ added: option to hide the Google Translate Toolbar
! fixed: all lights/snowflakes containers contain the notranslate class in case of Google Translate usage

v1.76
! fixed: check $_REQUEST where $context action|sub-action are not available

v1.75
+  added: additional native JavaScript files
!* fixed: check for JQuery prior to adding its library (SMF 2.0)
!* fixed: buffer amendments function reworked
!  fixed: uninstall process now removes all JavaScript files

v1.74
! fixed: no image directory check for empty path name

v1.73
! fixed: Xmas Wired Lights display none/flex for mouseover/mouseout
! fixed: Diverse & Fireworks use last child of body tag instead of #wrapper id
! fixed: missing concatenating assignment operator for $context['settings_insert_below']
! fixed: body overflowY & position properties for Fireworks
! fixed: Xmas Light Strands script for SMF 2.0

v1.72
! fixed: conflict with SMF 2.0.X branch post preview template

v1.71
! fixed: checking if constants are already defined

v1.7
+ added: new wired lights effect
! fixed: mobile/tablet detection
! fixed: snowstorm options for SMF 2.0 branch
! fixed: explosion animation for smash lights effect

v1.62
+ added: mouseenter/mouseover events for menus and search
+& added: admin options for mouseover/mouseenter events
! adjusted ion.sound to only use HTML5 audio
! fixed: onload event for various scripts that do not use JQuery (affects SMF 2.0)

v1.61
+ added: one additional light smash mp3 file
! fixed: smash lights script to only play one sound per bulb smash
! fixed: smash lights script to ensure it only loads one instance

v1.6
+& added: new light strands effect
+ any script requiring sound will now use the Ion.Sound 3.0.7 plug-in
+ all scripts are now compressed for stable versions
- SoundManager2 completely removed from smash lights script
! fixed: Javascript objects for snowstorm effect
! fixed: admin settings for snowstorm effect
! fixed: Javascript for smash lights effect
! fixed: Javascript node for smash lights effect now loaded using DOM
! fixed: css for exploding lights
! fixed: default offset height for smash lights effect on SMF 2.1 branch
! fixed: default settings for smash lights effect no longer sets or disables append & admin-view options

v1.5
+& added: mobile detection as another disable option
+& added: tablet detection as another disable option
+& license changed to: GNU Lesser General Public License version 3
! permission settings fixed: for both SMF branches
! profile menu icon fixed: for SMF 2.0 branch

v1.42
+& added: profile permissions to the Snowflakes admin template
+& disabling Snowflakes for actions/subactions behavior has changed (see help text in admin)
! fixed: misspelled help text
! fixed: member database function (missing key column for replace/insert)

v1.41
+& added: permission to allow membergroups profile option of enable/disable Snowflakes
! fixed: profile and permission functions
! fixed: SMF 2.1 profile area hook

v1.4
+& added: admin options to disable Snowflakes during specific SMF actions and/or subactions

v1.3
+ updated included JQuery library to v3.3.1
+ added: admin option to select Xmas lights container height
- removed utf-8 language files (existing language files are utf-8)
- eliminated redundant flash files
! fixed: deprecated msie detection
! fixed: css for lights
! fixed: instance of window.onload changed to eventListener
! fixed: instances of (window).load(function(){...}) changed to (window).on("load, function(){...})
! lights offset now "em" instead of "px" and floating value input allowing negative to positive range: -10.99 to 10.99

v1.2
+ added: random Snowflake script option
+ added: optional top px offset value for Xmas Lights script
! fixed: help text
! fixed: token validation for SMF 2.1.X
! fixed: image resizing for invalid or corrupt file types
! fixed: form multipart/form-data on Snowflakes admin template
! Snowflakes image folder no longer removed during the uninstall process

v1.1
+ Snowflakes now utilizes its own snowflakes_settings table
+ all settings are now mostly script/effect specific
+ added: lightbulbs script
+ installer now applies defaults where no settings exist for specific scripts
+ users have option to disable Snowflakes within their profile settings
+ membergroup permissions
+ file edit no longer necessary
! fixed: issue within snowflakesSMF.php file which affected some environments

v1.0
+ adds options for Snowflakes under the heading of Modification Settings
+ many options available for control ( more are pending )
+ 7 optional scripts available for varied effects

Disclaimer:

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.





My SMF Mods & Plug-Ins

WebDev

"Either you repeat the same conventional doctrines everybody is saying, or else you say something true, and it will sound like it's from Neptune." - Noam Chomsky

Steve

Nice job! The only thing I could wish for is the ability to have more than one choice selectable (not counting the random option). :)
DO NOT pm me for support!

-Rock Lee-

It seems pretty good, I'll install it in a test forum to see it better. Great job @Chen Zhen


Regards!
¡Regresando como cual Fenix! ~ Bomber Code
Ayudas - Aportes - Tutoriales - Y mucho mas!!!

Chen Zhen


Thanks  ;D

Quote from: Steve on December 24, 2018, 11:09:50 AM
Nice job! The only thing I could wish for is the ability to have more than one choice selectable (not counting the random option). :)

The random effect option lets you opt the effects you want in the form of a check list.
Do you mean to let the member opt the effect instead of just the Admin?

My SMF Mods & Plug-Ins

WebDev

"Either you repeat the same conventional doctrines everybody is saying, or else you say something true, and it will sound like it's from Neptune." - Noam Chomsky

Steve

As I understand it, the random effect rotates through whatever is checked so that there is only one effect happening at a time.

I wish I could select two or more of the effects and have them all show at the same time.

But that's only a wish. Like I said, great job on the mod as it is. :D
DO NOT pm me for support!

Chen Zhen

I just released version 1.6 which has some important updates.
Please uninstall plus delete the older version, then download & install the newer one.
Read the change-log in the app or in this mods initial post for details.

This update mainly concerns fixing the snowstorm & lights effects.
It also adds a newer light-strands effect.

The lights effect was previously using Soundmanager2 and its script was conflicting with other jQuery on the page.
This has been fixed in Snowflakes v1.6 along with using ion.sound v3.0.7 instead of Soundmanager2.




@Steve:
I can look into what you requested although I will have to test them with each other to see if they do not conflict (variable & function wise).
Having that many scripts running on the page at one time may almost certainly cause a performance concern.




My SMF Mods & Plug-Ins

WebDev

"Either you repeat the same conventional doctrines everybody is saying, or else you say something true, and it will sound like it's from Neptune." - Noam Chomsky

Steve

No worries Chen Zhen. It was only wishful thinking and I don't want you going through a lot of work just to do this.

Thanks for the update. :D
DO NOT pm me for support!

Steve

Hmm ... I see only options for the snowflakes. No lights, no bats, etc.
DO NOT pm me for support!

Chen Zhen

@Steve:

I just tested it on both SMF 2.0 & SMF 2.1 branches.
As well as installing when it was installed previously and when it was not.
In all scenarios it functions as expected with no PHP errors, no Javascript errors, no conflicts and nothing missing in any admin menu.
Although this was using the default theme in those tests.
What theme are you using?


I can not seem to duplicate what was reported.
Please uninstall it from your forum, clear the forum cache, clear the browser cache/history, download the version from here again and then install it.
Let me know if it works properly or not after those steps.

Thanks.


My SMF Mods & Plug-Ins

WebDev

"Either you repeat the same conventional doctrines everybody is saying, or else you say something true, and it will sound like it's from Neptune." - Noam Chomsky

Steve

My apologies Chen Zhen. I'm an idiot. I totally missed the dropdown box which switches effects. It works as advertised.
DO NOT pm me for support!

Chen Zhen

@Steve:
No problem and I'm glad it works as expected.




Even though I chose the name "Snowflakes", it has many effects including the ability to customize the images for "Diverse" & "Halloween".
Diverse provides a drop effect and Halloween provides a hover effect.
Which have options to change size, density, speed, images, etc.
You can make floating bees, leaves, falling rain drops or whatever you want.

What I should do is provide the ability to save multiple configurations for those 2 options.


My SMF Mods & Plug-Ins

WebDev

"Either you repeat the same conventional doctrines everybody is saying, or else you say something true, and it will sound like it's from Neptune." - Noam Chomsky

Chen Zhen


Snowflakes v1.61 is now available.

This update fixes issues with the smash lights effect.
Please read the change-log located in the initial post of the thread for details.

Regards.

My SMF Mods & Plug-Ins

WebDev

"Either you repeat the same conventional doctrines everybody is saying, or else you say something true, and it will sound like it's from Neptune." - Noam Chomsky

landyvlad

Anyone have a link to a forum where this is in use so I can see what it looks like ?
"Put as much effort into your question as you'd expect someone to give in an answer"

Please do not PM, IM or Email me with questions on astrophysics or theology.  You will get better and faster responses by asking homeless people in the street. Thank you.

Be the person your dog thinks you are.

Chen Zhen


Snowflakes has been updated to version 1.62.
This update includes some bug fixes and extra admin options.

The newer settings can make it so when a user has their mouse over specific HTML/XHTML containers, the lights will be temporarily disabled.
This will allow you to have those lights at the top in the position you want but not interfere with any links or navigation.




@landyvlad:

I have this mod enabled on my website and it is set to random.
You can click on the Forum link in the nav bar multiple times to see different effects.
However, due to the season I have 2 of the effects turned off (6 are enabled).

My SMF Mods & Plug-Ins

WebDev

"Either you repeat the same conventional doctrines everybody is saying, or else you say something true, and it will sound like it's from Neptune." - Noam Chomsky

Chen Zhen


Snowflakes has been updated to version 1.7
This update includes some bug fixes and another added wired lights effect.
The new effect has multiple image options including the ability to add your own images.

My SMF Mods & Plug-Ins

WebDev

"Either you repeat the same conventional doctrines everybody is saying, or else you say something true, and it will sound like it's from Neptune." - Noam Chomsky

Dave J

Hi,

Not working in SMF 2.1 RC2 with default theme.

Installs without error but when clicking on 'settings' just gives a blank page. Nothing listed in error log either.

6 hooks installed and listed as active.

No other mods installed.

Works OK on 2.0.15
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.

Dave J

Quote from: davejo on September 28, 2019, 08:53:44 AM
Hi,

Not working in SMF 2.1 RC2 with default theme.

Installs without error but when clicking on 'settings' just gives a blank page. Nothing listed in error log either.

6 hooks installed and listed as active.

No other mods installed.

Works OK on 2.0.15

Update:

It doesn't play nice with SMFPacks Shoutbox in 2.0.15. When enabled it has the error as seen in the first & second image below. When I activate 'Apend to body' the error is then smaller as seen in the second/third image below.

There are no erros in the SMF log and no errors on the cPanel either. I've tested it on various different themes including default and different sites. The php for all sites is 5.6. I have tested it on the Pro version and free version of the Shoutbox with the same results.

It's such a shame as I really like this mod.
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.

Chen Zhen


I would take a look at what you reported but atm it appears the SMF 2.1 version of that shoutbox mod is paid/pro only.
Although I suppose I can test the SMF 2.0.15 version from this forum to see if it has the same problem you reported.


My SMF Mods & Plug-Ins

WebDev

"Either you repeat the same conventional doctrines everybody is saying, or else you say something true, and it will sound like it's from Neptune." - Noam Chomsky

Dave J

Quote from: Chen Zhen on November 04, 2019, 10:05:21 PM

Although I suppose I can test the SMF 2.0.15 version from this forum to see if it has the same problem you reported.

Thanks Chen I would really like to use this mod.
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.

Chen Zhen


I just tested this on SMF 2.0.15 with the SMF Packs shoutbox installed and enabled.
Both mods seem to be working without conflict.
Atm I am not able to duplicate the javascript issue you reported (as per your first posted image).

My SMF Mods & Plug-Ins

WebDev

"Either you repeat the same conventional doctrines everybody is saying, or else you say something true, and it will sound like it's from Neptune." - Noam Chomsky

Advertisement: