Originally posted by RUBE
View Post
Announcement
Collapse
No announcement yet.
How to Create a Pulsating Button using CSS Animation
Collapse
X
-
- Top
- Translate
- Bottom
-
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.
- Top
- Translate
- Bottom
Leave a comment:
-
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...
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); }
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
Leave a comment:
-
Nice little css. I'd like to have that little pin show up in the right corner of the notice. Any chance you could share how to do this?
- Top
- Translate
- Bottom
Leave a comment:
-
Just add class="heartbeat" to the <a> tag for Join Now button after you added the CSS to css_additional template.
- Top
- Translate
- Bottom
- Likes 1
Leave a comment:
-
If I want to make my "Join Now" button pulse [which is not a stock img], how do i link it in the html tag?
- Top
- Translate
- Bottom
Leave a comment:
-
You're welcome. Thanks for the coffee!
- Top
- Translate
- Bottom
-
Add the "b-button" class to the button. If you want it to look like the primary button, also add "b-button--primary". There is also "b-button--special" class if you want. These are default vB5 classes to style the buttons.
HTML Code:<a href="https://www.christforums.org/register/" class="b-button b-button--primary heartbeat">Register Now!</a>
- Top
- Translate
- Bottom
Leave a comment:
-
Did you add the css in the first post to your css_additional template?
- Top
- Translate
- Bottom
Leave a comment:
-
I seem to have forgotten how to implement this. I added the above code to my css. And I want to add the pulsating button to my notices.
This is what I included in my notice:
<center><a href="https://www.christforums.org/register/" class="heartbeat">Register Now!</a></center>
Why is this not working?
William
- Top
- Translate
- Bottom
Leave a comment:
-
Originally posted by glennrocksvb View PostYou don't use it as an HTML tag but use it in a class attribute in an HTML tag.
The easiest way to get free 10GB storage! Direct access to your cloud storage, with any program, without consuming any local disk space. Play music, view photos, edit documents and others directly from the cloud like you would from a local drive - from anywhere in the world.
- Top
- Translate
- Bottom
Leave a comment:
Users Viewing This Page
Collapse
There is 1 user viewing this forum topic.
- Guest
Latest Posts
Collapse
-
Comment on Topic Starter Ribbon for vBCloudby glennrocksvbThanks for confirming the fix works.Today, 08:20 AM
-
Reply to Topic Starter Ribbon for vBCloudby glennrocksvbI have updated the template code in the first post. Please try it again.Today, 06:38 AM
Leave a comment: