IMPORTANT

FM Design is in read-only mode, please click here for more information.

Latest topics
» Forum Closure
by Ange Tuteur Mon 01 Jan 2018, 01:28

» Chit Chat Thread
by Valoish Sun 31 Dec 2017, 19:15

» Font/Text background color.
by Valoish Sun 31 Dec 2017, 19:11

» Forumactif Messenger - Instant Message Application for Forumotion
by Wolfuryo Sun 31 Dec 2017, 18:24

» [GAME] Count to One Million!
by brandon_g Fri 29 Dec 2017, 18:58

» Post Cards
by manikbiradar Wed 20 Dec 2017, 07:50

» Forumactif Edge - Releases
by Ange Tuteur Thu 14 Dec 2017, 11:25

» [GAME] Countdown from 200,000
by Valoish Wed 13 Dec 2017, 23:22

» GeekPolice Tech Support Forums - GeekPolice.net
by Dr Jay Mon 11 Dec 2017, 19:12

» Asking about some plugin for Forumotion
by Dr Jay Mon 11 Dec 2017, 19:10

» [GAME] What are you thinking right now?
by Van-Helsing Sat 09 Dec 2017, 14:51

» Widget : Similar topics
by ranbac Wed 06 Dec 2017, 18:11

» Change the Background of the Forum and put an image and how to make prefixs?
by Clement Wed 06 Dec 2017, 15:19

» Hello from Western Australia
by SarkZKalie Wed 06 Dec 2017, 05:34

» Numbering of messages in the topic
by SLGray Mon 04 Dec 2017, 22:40

Recent Tutorials
Top posting users this month
Who is online?
In total there are 5 users online :: 0 Registered, 0 Hidden and 5 Guests :: 2 Bots

None

[ View the whole list ]


Most users ever online was 172 on Fri 19 Feb 2016, 05:17

[Suggestion] Holiday Feature/Option

View previous topic View next topic Go down

avatar
SLGray
Valued Member
Title :
Owner of 2 Forums
Gender : Male
Age : 44
Posts : 2465
Points : 4846
Reputation : 290
Location : United States
Language : English
Browser : Browser : Mozilla Firefox Forum Version : Forum Version : ModernBB
Awards :
View all awards
View user profile http://www.fmthemes.forumotion.com https://www.facebook.com/FM-Themes-655055824604957 https://twitter.com/FMThemes https://pinterest.com/FMThemes

PostSLGray on Tue 13 Sep 2016, 23:04

I do not know if this is possible, or if you want to do it, but how about adding an option to decorate the forum for the holidays.

Example: 

Halloween
Theme's color changes to a shade of orange.
Maybe a Halloween image and text (Happy Halloween!) in the header of the forum.
This will all be automatically, and you can turn it off or on.
avatar
Ange Tuteur
Administrator
Title :
Coffee Addict
Gender : Male
Age : 22
Posts : 4725
Points : 9672
Reputation : 2352
Location : Macungie, PA
Language : EN10, FR5
Browser : Browser : Brave Forum Version : Forum Version : Forumactif Edge
Awards :
View all awards
View user profile https://github.com/SethClydesdale https://twitter.com/sethc1995

PostAnge Tuteur on Wed 14 Sep 2016, 13:52

@SLGray hmm... I like it. It should be possible to detect the day using JavaScript and apply decorations on that specific day. I'll add it to my notes. Surprised

--------

Ange Tuteur
Tips and TricksContact Me

avatar
SLGray
Valued Member
Title :
Owner of 2 Forums
Gender : Male
Age : 44
Posts : 2465
Points : 4846
Reputation : 290
Location : United States
Language : English
Browser : Browser : Mozilla Firefox Forum Version : Forum Version : ModernBB
Awards :
View all awards
View user profile http://www.fmthemes.forumotion.com https://www.facebook.com/FM-Themes-655055824604957 https://twitter.com/FMThemes https://pinterest.com/FMThemes

PostSLGray on Wed 14 Sep 2016, 20:05

Thanks for considering my suggestion.
avatar
Valoish
Graphic Designer
Title :
Gender : Female
Age : 21
Posts : 3665
Points : 4853
Reputation : 360
Location : NYC
Language : English, Russian, Hebrew
Browser : Browser : Opera Forum Version : Forum Version : phpBB2
Awards :
View all awards
View user profile http://www.canvasforums.com https://twitter.com/Valoishx3

PostValoish on Wed 14 Sep 2016, 20:07

>u>
<u<
This is a cute idea.
If you need help with decorations, lemme know :B

--------

"I was afraid. And my own insecurity crushed him." - Youku x Boku SS
avatar
Ace 1
Valued Member
Title :

Beta Tester
Gender : Unspecified
Age : 18
Posts : 2153
Points : 3026
Reputation : 92
Location : USA
Language : English ?
Browser : Browser : Google Chrome Forum Version : Forum Version : phpBB3
Awards :
View all awards
View user profile http://fmdesign.forumotion.com/u190

PostAce 1 on Thu 15 Sep 2016, 17:39

I saw this and thought I could do it, but @Ange Tuteur, for some reason, your scrollbar buttons don't change when I mess with them ._.

The code works finely however. I even matched the color with the color of your "view newest post" pictures and I used your little formula Wink

http://help.forumotion.com/t147986p30-forumactif-edge-a-free-modern-and-responsive-forum-theme#1023873

And it still works when a user changes the theme from an already selected theme to the default Razz

Code:
$(function() {
  var halloween = {
    month: 8,
    day: 31
  },

  now = new Date(),

  styles =
    '<style id="halloween">' +
      '.color-primary, .title, h2.u, .h3, .inner h1.page-title, .mainmenu:after, .forumline tbody .catHead, form.search-form input.search-keywords, input.search-button, .pagination span a, a.button1, a.button2, button.button2, input.button1, input.button2, input.button, #profile-advanced-add a, img[src*="?poll"], .fa_pseudo_radio:after, #tabs, body div.sceditor-dropdown .button, .codebox dt, blockquote cite, .sceditor-container .sceditor-toolbar, body #fa_toolbar, body #fa_toolbar_hidden, body #fa_toolbar #fa_right #notif_list li.see_all, #fae_sticky_nav_panel a:after, img[src*="color=primary"], .table1 thead th, .breadcrumbs, input[type="button"], input[type="submit"], input[type="reset"], input[type="file"], .fmd_awards td, #fmd_achievement_list .award, #achievement_progress div, #logo-desc { background-color: #F70; color: #000; }' +
      '::-webkit-scrollbar-thumb { background-color: #F70; }' +
      '#fa_theme_selector { background-color: #000; }' +
      '#navbar, #tabs { background-color: #630; }' +
      '#navbar .mainmenu:hover, #tabs a:hover, .mainmenu.fa_navactif, #tabs .activetab, #fa_theme_selector:hover, #fa_theme_selector:focus { color: #F70 !important; }' +
      'input[type="text"]:hover, input.post:hover, input.inputbox:hover, textarea:hover, select:hover, input[type="text"]:focus, input.post:focus, input.inputbox:focus, textarea:focus, select:focus, body div.sceditor-dropdown input:focus, body div.sceditor-dropdown textarea:focus, .fa_pseudo_checkbox:hover, .fa_pseudo_radio:hover, .sceditor-container, h2.post-content, h3.post-content, h4.post-content, .lastpost-avatar, #wio_new_avatar, .avatar-mini img, .avatar { border-color: #F70 !important; }' +
      '.pagination span a:hover, a.button1:hover, a.button2:hover, button.button2:hover, input.button1:hover, input.button2:hover, input.button:hover, #profile-advanced-add a:hover, input.search-button:hover, body div.sceditor-dropdown .button:hover, img[src*="color=primary"]:hover, input[type="button"]:hover, input[type="submit"]:hover, input[type="reset"]:hover, input[type="file"]:hover, form.search-form, ::-webkit-scrollbar-thumb:hover, ::-webkit-scrollbar-thumb:hover { background-color: #E60; color: #FFF !important; }' +
      '.forum-status[style*="state=new"] { background-color: #F81 !important; }' +
      'form.search-form input.search-keywords, input.search-button { border-color: #F81 !important; }' +
      '.pagination span a:active, .pagination span a:focus, .pagination span strong, a.button1:active, a.button2:active, button.button2:active, input.button1:active, input.button2:active, input.button:active, input[type="button"]:active, input[type="submit"]:active, input[type="reset"]:active, input[type="file"]:active, a.button1:focus, a.button2:focus, button.button2:focus, input.button1:focus, input.button2:focus, input.button:focus, input.search-button:focus, #tabs a:after, body div.sceditor-dropdown .button:active, body div.sceditor-dropdown .button:focus, body #fa_search #fa_textarea, body #fa_search #fa_magnifier, img[src*="color=primary"]:active, input[type="button"]:focus, input[type="submit"]:focus, input[type="reset"]:focus, input[type="file"]:focus, ::-webkit-scrollbar-thumb:active, ::-webkit-scrollbar-button:active { background-color: #C40; }' +
      '#fa_toolbar, #fa_toolbar_hidden { border-color: #C40 !important; }' +
      'a:not([style^="color"]), .forumline tbody .catHead a, .h3 a, .h3 span, .table1 thead th a, .title a, h2.u a { color: #000 !important; }' +
      'a:not([style^="color"]):not([class^="button"]):hover { color: #666 !important; }' +
      '.color-secondary, .forum-status[style*="locked=true"], img[src*="color=secondary"] { background-color: #650; }' +
      '#page-footer a, #footer_end, #footer_end a { color: #FFF !important; }' +
      '#page-footer a:hover, #footer_end a:hover { color: #AAA !important; }' +
      '::selection { background-color: #F70 !important; }' +
  '</style>';

  if ( now.getMonth() == halloween.month && now.getDate() == halloween.date && $('#fa_theme_selector').val() == 'Select a theme' ) {
    // Adds styles to <head> tag if default theme is loaded
    $('head').append(styles);
  }

  $('#fa_theme_selector').change(function() {
    // Checks if the default theme is chosen and sets theme accordingly
    $(this).val() != 'Select a theme'
      ?
        $('#halloween').remove()
      :(
        $('head').append(styles),
        $('#fa_theme_selector').css('background-color', 'black')
    );
  });

});

Hope this helps a little bit. Rose
avatar
Ange Tuteur
Administrator
Title :
Coffee Addict
Gender : Male
Age : 22
Posts : 4725
Points : 9672
Reputation : 2352
Location : Macungie, PA
Language : EN10, FR5
Browser : Browser : Brave Forum Version : Forum Version : Forumactif Edge
Awards :
View all awards
View user profile https://github.com/SethClydesdale https://twitter.com/sethc1995

PostAnge Tuteur on Fri 16 Sep 2016, 13:32

@SLGray wrote:Thanks for considering my suggestion.
No problem. Smile

@Valoish wrote:>u>
<u<
This is a cute idea.
If you need help with decorations, lemme know :B
Sure thing, thanks ! ^^

@Ace 1 wrote:I saw this and thought I could do it, but @Ange Tuteur, for some reason, your scrollbar buttons don't change when I mess with them ._.

The code works finely however. I even matched the color with the color of your "view newest post" pictures and I used your little formula Wink

http://help.forumotion.com/t147986p30-forumactif-edge-a-free-modern-and-responsive-forum-theme#1023873

And it still works when a user changes the theme from an already selected theme to the default Razz

Code:
$(function() {
  var halloween = {
    month: 8,
    day: 31
  },

  now = new Date(),

  styles =
    '<style id="halloween">' +
      '.color-primary, .title, h2.u, .h3, .inner h1.page-title, .mainmenu:after, .forumline tbody .catHead, form.search-form input.search-keywords, input.search-button, .pagination span a, a.button1, a.button2, button.button2, input.button1, input.button2, input.button, #profile-advanced-add a, img[src*="?poll"], .fa_pseudo_radio:after, #tabs, body div.sceditor-dropdown .button, .codebox dt, blockquote cite, .sceditor-container .sceditor-toolbar, body #fa_toolbar, body #fa_toolbar_hidden, body #fa_toolbar #fa_right #notif_list li.see_all, #fae_sticky_nav_panel a:after, img[src*="color=primary"], .table1 thead th, .breadcrumbs, input[type="button"], input[type="submit"], input[type="reset"], input[type="file"], .fmd_awards td, #fmd_achievement_list .award, #achievement_progress div, #logo-desc { background-color: #F70; color: #000; }' +
      '::-webkit-scrollbar-thumb { background-color: #F70; }' +
      '#fa_theme_selector { background-color: #000; }' +
      '#navbar, #tabs { background-color: #630; }' +
      '#navbar .mainmenu:hover, #tabs a:hover, .mainmenu.fa_navactif, #tabs .activetab, #fa_theme_selector:hover, #fa_theme_selector:focus { color: #F70 !important; }' +
      'input[type="text"]:hover, input.post:hover, input.inputbox:hover, textarea:hover, select:hover, input[type="text"]:focus, input.post:focus, input.inputbox:focus, textarea:focus, select:focus, body div.sceditor-dropdown input:focus, body div.sceditor-dropdown textarea:focus, .fa_pseudo_checkbox:hover, .fa_pseudo_radio:hover, .sceditor-container, h2.post-content, h3.post-content, h4.post-content, .lastpost-avatar, #wio_new_avatar, .avatar-mini img, .avatar { border-color: #F70 !important; }' +
      '.pagination span a:hover, a.button1:hover, a.button2:hover, button.button2:hover, input.button1:hover, input.button2:hover, input.button:hover, #profile-advanced-add a:hover, input.search-button:hover, body div.sceditor-dropdown .button:hover, img[src*="color=primary"]:hover, input[type="button"]:hover, input[type="submit"]:hover, input[type="reset"]:hover, input[type="file"]:hover, form.search-form, ::-webkit-scrollbar-thumb:hover, ::-webkit-scrollbar-thumb:hover { background-color: #E60; color: #FFF !important; }' +
      '.forum-status[style*="state=new"] { background-color: #F81 !important; }' +
      'form.search-form input.search-keywords, input.search-button { border-color: #F81 !important; }' +
      '.pagination span a:active, .pagination span a:focus, .pagination span strong, a.button1:active, a.button2:active, button.button2:active, input.button1:active, input.button2:active, input.button:active, input[type="button"]:active, input[type="submit"]:active, input[type="reset"]:active, input[type="file"]:active, a.button1:focus, a.button2:focus, button.button2:focus, input.button1:focus, input.button2:focus, input.button:focus, input.search-button:focus, #tabs a:after, body div.sceditor-dropdown .button:active, body div.sceditor-dropdown .button:focus, body #fa_search #fa_textarea, body #fa_search #fa_magnifier, img[src*="color=primary"]:active, input[type="button"]:focus, input[type="submit"]:focus, input[type="reset"]:focus, input[type="file"]:focus, ::-webkit-scrollbar-thumb:active, ::-webkit-scrollbar-button:active { background-color: #C40; }' +
      '#fa_toolbar, #fa_toolbar_hidden { border-color: #C40 !important; }' +
      'a:not([style^="color"]), .forumline tbody .catHead a, .h3 a, .h3 span, .table1 thead th a, .title a, h2.u a { color: #000 !important; }' +
      'a:not([style^="color"]):not([class^="button"]):hover { color: #666 !important; }' +
      '.color-secondary, .forum-status[style*="locked=true"], img[src*="color=secondary"] { background-color: #650; }' +
      '#page-footer a, #footer_end, #footer_end a { color: #FFF !important; }' +
      '#page-footer a:hover, #footer_end a:hover { color: #AAA !important; }' +
      '::selection { background-color: #F70 !important; }' +
  '</style>';

  if ( now.getMonth() == halloween.month && now.getDate() == halloween.date && $('#fa_theme_selector').val() == 'Select a theme' ) {
    // Adds styles to <head> tag if default theme is loaded
    $('head').append(styles);
  }

  $('#fa_theme_selector').change(function() {
    // Checks if the default theme is chosen and sets theme accordingly
    $(this).val() != 'Select a theme'
      ?
        $('#halloween').remove()
      :(
        $('head').append(styles),
        $('#fa_theme_selector').css('background-color', 'black')
    );
  });

});

Hope this helps a little bit. Rose
You have the right idea going on, the only thing is that it's not edit-friendly ; the user would need to know how to define objects, edit the style string, and setup conditions for their custom holidays. This isn't bad if you're making a preset list of holidays, which is most likely what we'll be doing, but I do want to add some flexibility in so that people can add holidays which aren't available. I was thinking something along these lines :

1. User defines the holiday names and dates in a "holidays" object.
2. We loop over the object to check if today is any of the holidays.
3. If we get a hit, we'll add a class name to the body for that holiday.

I think including preset CSS for the holiday will be perfect, but it'll be optional in case the admin wants to make their own styles for that holiday. This is an example of what I mean :
Code:
$(function() {

  var month = {
    'January' : 1,
    'February' : 2,
    'March' : 3,
    'April' : 4,
    'May' : 5,
    'June' : 6,
    'July' : 7,
    'August' : 8,
    'September' : 9,
    'October' : 10,
    'November' : 11,
    'December' : 12
  },

  thisMonth = new Date().getMonth(),
  i;

  for (i in month) {
    if (month[i] - 1 == thisMonth) {
      document.body.className += ' month-' + i.toLowerCase();
      break;
    }
  }

});
This is an example using objects btw, you can use an easier and faster method for months by utilizing arrays instead. Wink

This'll add a class to the body depending on the month. Since we're currently in September, the class would be
Code:
.month-september
, so you can style by the month. loove

--------

Ange Tuteur
Tips and TricksContact Me

avatar
Ace 1
Valued Member
Title :

Beta Tester
Gender : Unspecified
Age : 18
Posts : 2153
Points : 3026
Reputation : 92
Location : USA
Language : English ?
Browser : Browser : Google Chrome Forum Version : Forum Version : phpBB3
Awards :
View all awards
View user profile http://fmdesign.forumotion.com/u190

PostAce 1 on Fri 16 Sep 2016, 16:56

Oh, well that makes sense for multiple holidays.

Intuitive

View previous topic View next topic Back to top

Create an account or log in to leave a reply

You need to be a member in order to leave a reply.

Create an account

Join our community by creating a new account. It's easy!


Create a new account

Log in

Already have an account? No problem, log in here.


Log in

 
Permissions in this forum:
You cannot reply to topics in this forum