inherit
First Contributor
66253
0
Mar 18, 2024 11:09:20 GMT -8
aRMY83
2,925
December 2005
army83
|
Post by aRMY83 on Dec 7, 2013 13:33:07 GMT -8
Thought I'd share what I came across the other day when doing a jQuery search for "pulsate".
Let us do a simple "Member is Online" in the Mini-Profile to pulsate.
Place this code in your Global Footer:
<script type="text/javascript"> $(document).ready(function() { function pulsate() { $(".pulsate").animate({opacity: 0.2}, 1200, 'linear') .animate({opacity: 1}, 1200, 'linear', pulsate); <---- See below } pulsate(); }); </script>
Note: Remove this <---- See below before placing the above code in the Global Footer.
Change this above for amount of opacity (transparency) needed. Default = 0.2
Now to have "Member is Online" pulsate:
Go to Admin > Structure > Layout Templates > Mini-Profile
and look for (line 27 or so)
{if $[user.is_online]}<br /><span class="italic">Member is Online</span>{/if}
and place this:
<div class="pulsate"> just before Member
and this </div> right after Online
so it will now look like this:
{if $[user.is_online]}<br /><span class="italic"><div class="pulsate">Member is Online</div></span>{/if}
You can change this:
animate({opacity: 1}, 1000, 'linear', pulsate);
within the code, but not necessary, as it's only a small part of the fade-in/fade-out animation. However, it can be change to a higher number, but would not recommend anything above 1 for a smooth animation process.
|
|
inherit
First Contributor
66253
0
Mar 18, 2024 11:09:20 GMT -8
aRMY83
2,925
December 2005
army83
|
Post by aRMY83 on Dec 20, 2013 11:12:57 GMT -8
Thanks jrryan and as you mentioned "pulsating pm", that I just may try myself.
|
|
inherit
First Contributor
66253
0
Mar 18, 2024 11:09:20 GMT -8
aRMY83
2,925
December 2005
army83
|
Post by aRMY83 on Dec 20, 2013 16:36:29 GMT -8
I have not even played around with what it can do or cannot do, but I'm sure with a bit of experimenting, anything is possible with this code. There may be areas that this code will not work, but with the skills of coding you have, I'm sure you will find more things that it can do than cannot do.
By all means, input here what you find that works so that all of us may benefit from this code.
|
|
Former Member
inherit
guest@proboards.com
188496
0
Dec 4, 2024 8:15:35 GMT -8
Former Member
0
January 1970
Former Member
|
Post by Former Member on Dec 21, 2013 5:16:43 GMT -8
What is pulsate? What is its purpose?
|
|
inherit
First Contributor
66253
0
Mar 18, 2024 11:09:20 GMT -8
aRMY83
2,925
December 2005
army83
|
Post by aRMY83 on Dec 21, 2013 5:42:43 GMT -8
I also use it for: <div class="pulsate">I am offline</div> or in your case jrryan, Offline
|
|
Former Member
inherit
guest@proboards.com
188496
0
Dec 4, 2024 8:15:35 GMT -8
Former Member
0
January 1970
Former Member
|
Post by Former Member on Dec 21, 2013 12:30:00 GMT -8
@womenonly It makes in this case the word in your mini profile which on my forum is "online" fade in and out like a sign that flashes on and off. When you go to my forum and scroll through the threads you have members who are naturally online and offline which is displayed in the mini profile. When anyone is online it fades in and out, or pulsates. Look at my profile: www.thescooterprofessor.proboards.com/thread/3330/Thank you.
|
|
Former Member
inherit
guest@proboards.com
131621
0
Dec 4, 2024 8:15:35 GMT -8
Former Member
0
January 1970
Former Member
|
Post by Former Member on Dec 22, 2013 10:51:38 GMT -8
Just for others to know, I made the text in my notification bubbles (including PMs) pulsate by Forum Wrapper:
<div class="tip-number"><div class="pulsate">$[navigation.menu.notification.total]</div></div>
Awesome freakin' code! =)
|
|
inherit
The Great Cinnamon Roll
191518
0
Oct 19, 2016 22:17:44 GMT -8
David Clark
Care for some tai chi with your chai tea?
17,602
March 2013
davidlinc1
|
Post by David Clark on Jan 2, 2014 9:07:01 GMT -8
I've moved this over at aRMY83's request.
|
|
inherit
195082
0
Mar 20, 2022 7:33:21 GMT -8
PF
1,089
June 2013
weedster
|
Post by PF on Jul 17, 2014 20:14:08 GMT -8
Hi, I followed the instructions for this code but it's not working on my forum. Any suggestions? Thanks.
|
|
inherit
First Contributor
66253
0
Mar 18, 2024 11:09:20 GMT -8
aRMY83
2,925
December 2005
army83
|
Post by aRMY83 on Jul 18, 2014 3:33:15 GMT -8
Hello PFURL link please and would you mind placing your complete Mini-Profile code as to what you have using code tags so that I/we can take a look at it.
|
|
inherit
195082
0
Mar 20, 2022 7:33:21 GMT -8
PF
1,089
June 2013
weedster
|
Post by PF on Jul 18, 2014 6:42:36 GMT -8
Hello PFURL link please and would you mind placing your complete Mini-Profile code as to what you have using code tags so that I/we can take a look at it. The word 'forum' is hyperlinked to my forum but it's here: link
Here's the code:
{if $[user.is_online]}<br /><span class="italic"><div class="pulsate">Member is Online</div></span>{/if} </div><br /> {/if} {if $[user.badges_miniprofile]} <div class="$[user.badges_miniprofile_container_class]"> {foreach $[user.badges_miniprofile]} $[user.badges_miniprofile.icon]
|
|
inherit
First Contributor
66253
0
Mar 18, 2024 11:09:20 GMT -8
aRMY83
2,925
December 2005
army83
|
Post by aRMY83 on Jul 18, 2014 12:45:58 GMT -8
Hello again Heeeeey...
Did you place this in your Global Footer as instructed:
<script type="text/javascript"> $(document).ready(function() { function pulsate() { $(".pulsate").animate({opacity: 0.2}, 1200, 'linear') .animate({opacity: 1}, 1200, 'linear', pulsate); } pulsate(); }); </script>
Just gave your code a go and it worked just fine on my test site, however, I'm not sure why you have this
{if $[user.is_online]}<br /><span class="italic"><div class="pulsate">Member is Online</div></span>{/if} </div><br /> {/if} {if $[user.badges_miniprofile]} <div class="$[user.badges_miniprofile_container_class]"> {foreach $[user.badges_miniprofile]} $[user.badges_miniprofile.icon]
entered twice.
Remove {/if} and see what happens. I did on the test site and it did not make a difference for me.
|
|
inherit
195082
0
Mar 20, 2022 7:33:21 GMT -8
PF
1,089
June 2013
weedster
|
Post by PF on Jul 18, 2014 12:57:04 GMT -8
Hello again Heeeeey... Did you place this in your Global Footer as instructed: <script type="text/javascript"> $(document).ready(function() { function pulsate() { $(".pulsate").animate({opacity: 0.2}, 1200, 'linear') .animate({opacity: 1}, 1200, 'linear', pulsate); } pulsate(); }); </script> Just gave your code a go and it worked just fine on my test site, however, I'm not sure why you have this{if $[user.is_online]}<br /><span class="italic"><div class="pulsate">Member is Online</div></span>{/if} </div><br /> {/if}{if $[user.badges_miniprofile]} <div class="$[user.badges_miniprofile_container_class]"> {foreach $[user.badges_miniprofile]} $[user.badges_miniprofile.icon] entered twice. Remove {/if} and see what happens. I did on the test site and it did not make a difference for me. Hi, I removed the extra {/if} and checked that the code is in the Global Footer. It still doesn't work for some reason. I must be doing something wrong because it doesn't work on my test site either.
|
|
inherit
First Contributor
66253
0
Mar 18, 2024 11:09:20 GMT -8
aRMY83
2,925
December 2005
army83
|
Post by aRMY83 on Jul 18, 2014 13:21:12 GMT -8
Outside of what we have discussed, I don't have any other suggestions to get it working for you. (Sorry)
|
|
inherit
195082
0
Mar 20, 2022 7:33:21 GMT -8
PF
1,089
June 2013
weedster
|
Post by PF on Jul 18, 2014 13:56:28 GMT -8
Outside of what we have discussed, I don't have any other suggestions to get it working for you. (Sorry) Okay, just to double check, I have the code in the Global Footer positioned above another code for the page view counter. Would that matter? Also, I have the line of code in the mini profile layout template. I think that's placed correctly, so could it be the Global Footer positioning? Also, how do I fix it so that the mini profile shows when someone is offline too? Right now it only shows when someone is online.
|
|