This is very simple but effective. Thanks.
Announcement
Collapse
No announcement yet.
How to Create a Pulsating Button using CSS Animation
Collapse
X
-
Hello Everybody,
I really like the Sticky Default Guest Notice, but I'm having problems with the pulsating Register Now text.
I went to css_additional.css and installed this code...
Everything worked fine, so then I went back & changed the code to this...PHP Code:.l-desktop .notice[data-notice-id='1'] { position: fixed; z-index: 2; bottom: 0; right: 0; margin: 10px; width: 400px; box-shadow: 0px 2px 8px 2px rgba(0,0,0,0.7); }
Nothing happened, The floating text message was there but no pulsating button. If someone could show me where I went wrong, I would be very happy. Maybe the order I put it in is wrong? I don't think I missed any code? Oh well,,,, HELP! Please go light on me as far as explaining things, I barely know the difference between HTML and a hot meal... Like my name says - I'm a RUBE!PHP Code:<a href="http://www.mywebsite.com/register/" class="b-button b-button--primary heartbeat">Register Now!</a> .l-desktop .notice[data-notice-id='1'] { position: fixed; z-index: 2; bottom: 0; right: 0; margin: 10px; width: 400px; box-shadow: 0px 2px 8px 2px rgba(0,0,0,0.7); } .heartbeat { -webkit-animation: pulse 1s ease infinite; -moz-animation: pulse 1s ease infinite; -ms-animation: pulse 1s ease infinite; -o-animation: pulse 1s ease infinite; animation: pulse 1s ease infinite; display: inline-block; } @-webkit-keyframes pulse { 0% { -webkit-transform: scale(1); } 25% { -webkit-transform: scale(1.1); } 50% { -webkit-transform: scale(1); } 100% { -webkit-transform: scale(1); } } @-moz-keyframes pulse { 0% { -moz-transform: scale(1); } 25% { -moz-transform: scale(1.1); } 50% { -moz-transform: scale(1); } 100% { -moz-transform: scale(1); } } @-ms-keyframes pulse { 0% { -ms-transform: scale(1); } 25% { -ms-transform: scale(1.1); } 50% { -ms-transform: scale(1); } 100% { -ms-transform: scale(1); } } @-o-keyframes pulse { 0% { -o-transform: scale(1); } 25% { -o-transform: scale(1.1); } 50% { -o-transform: scale(1); } 100% { -o-transform: scale(1); } } @keyframes pulse { 0% { transform: scale(1); } 50% { transform: scale(1.1); } 100% { transform: scale(1); }
Thank You for Your Time!!!!! RUBELast edited by RUBE; 11-22-2017, 11:05 AM. Reason: I'm having a problem with the format of my post, how can you make the code (container) windows taller?
- Top
- Translate
- Bottom
Comment
-
You should not add HTML code in CSS! There's no instruction that says so. Put all the necessary CSS code in css_additional template in AdminCP or CSS Editor in Sitebuilder.
Then put the HTML code for the Register button in the Notice itself. See post #11 to see what HTML code to use for the button.
My Amazon Affiliate Link
Fast vBulletin VPS Host:
This site is hosted by IONOS
- Top
- Translate
- Bottom
Comment
-
The line breaks in the source code were removed that's why the code container is not tall enough.Originally posted by RUBE View PostI'm having a problem with the format of my post, how can you make the code (container) windows taller?
My Amazon Affiliate Link
Fast vBulletin VPS Host:
This site is hosted by IONOS
- Top
- Translate
- Bottom
Comment
-
Code:<a href="http://www.mywebsite.com/register/" class="b-button heartbeat" style="background:red; color:white;">Register Now!</a>
Last edited by glennrocksvb; 02-12-2022, 12:59 PM.
My Amazon Affiliate Link
Fast vBulletin VPS Host:
This site is hosted by IONOS
- Top
- Translate
- Bottom
Comment
-
Did you follow all the 3 steps mentioned in the first post?
My Amazon Affiliate Link
Fast vBulletin VPS Host:
This site is hosted by IONOS
- Top
- Translate
- Bottom
Comment
-
Where do you want to use the pulsating button?
My Amazon Affiliate Link
Fast vBulletin VPS Host:
This site is hosted by IONOS
- Top
- Translate
- Bottom
Comment
-
Right click on the Register Now button on this site and then select Inspect to see how the hearbeat and b-button classes are added to the class attribute in the HTML tag.
My Amazon Affiliate Link
Fast vBulletin VPS Host:
This site is hosted by IONOS
- Top
- Translate
- Bottom
Comment
-
i followed the instructions and it returns "cant save CSS error". I have vb5. have anyone seen this before?Originally posted by glennrocksvb View PostWant buttons that grab attention like what this forum has for the Register Now button for guests?
Instructions:- Add these CSS in css_additional template in AdminCP or via Sitebuilder > Style CSS Editor.
Code:.heartbeat { -webkit-animation: pulse 1s ease infinite; -moz-animation: pulse 1s ease infinite; -ms-animation: pulse 1s ease infinite; -o-animation: pulse 1s ease infinite; animation: pulse 1s ease infinite; display: inline-block; } @-webkit-keyframes pulse { 0% { -webkit-transform: scale(1); } 25% { -webkit-transform: scale(1.1); } 50% { -webkit-transform: scale(1); } 100% { -webkit-transform: scale(1); } } @-moz-keyframes pulse { 0% { -moz-transform: scale(1); } 25% { -moz-transform: scale(1.1); } 50% { -moz-transform: scale(1); } 100% { -moz-transform: scale(1); } } @-ms-keyframes pulse { 0% { -ms-transform: scale(1); } 25% { -ms-transform: scale(1.1); } 50% { -ms-transform: scale(1); } 100% { -ms-transform: scale(1); } } @-o-keyframes pulse { 0% { -o-transform: scale(1); } 25% { -o-transform: scale(1.1); } 50% { -o-transform: scale(1); } 100% { -o-transform: scale(1); } } @keyframes pulse { 0% { transform: scale(1); } 50% { transform: scale(1.1); } 100% { transform: scale(1); } }2. Add hearbeat CSS class to any button or HTML tag you want to use in HTML/Ad/PHP modules, Announcemens, Notices, etc. You can add the heartbeat CSS class to any element you want to pulsate not just to buttons.
3. If you are using this for buttons, you also need to add b-button and b-button--primary or b-button--special CSS classes to the button.
Demo:
<button href="https://www.paypal.me/noypiscripter/5" class="b-button b-button--special heartbeat" target="_blank">My ♥ beats like this</button>
- Top
- Translate
- Bottom
Comment
Latest Posts
Collapse
-
Reply to some ideas for new modsin Chit Chatby desmomax
I finally created a mod that allows you to add an icon to each post with options for sharing on other platforms. I honestly thought it was absurd that...
Today, 03:59 AM -
by flohseHi Glenn, what do you think about adding "Like Counts" similar to "Like Counts on Postbit and Profile" (when this mod is in use) in...Yesterday, 11:28 PM
-
Reply to push notification prompt?by desmomaxhy glenn
have you thought about this?Yesterday, 05:44 AM


Comment