I'm trying to make a text box at the bottom of a page more obvious - how would I go about making a link which when clicked moves the browser to the bottom of the page and then makes the text box glow around the edges then fades (as in the glow pulses, I don't want the text box to fade!)?
Asked
Active
Viewed 1,115 times
0
-
Well, I know how to make the 'redirect', and I know how to make the box glow but I have no clue how to automate it – eddhall Feb 25 '14 at 15:10
-
you can use jquery's animate feature... – Ram Singh Feb 25 '14 at 15:15
2 Answers
2
I have a crude implementation for you. It uses the abrupt anchor tag click to move you to the text box, however, you could use jQuery's animate function to make it pretty. It does have the effect with the pulse you wanted.
$(function() {
$("#glow-trigger").on('click', function(e) {
var glower = $('.glow');
window.setInterval(function() {
glower.toggleClass('active');
}, 1000);
});
});

OnResolve
- 4,016
- 3
- 28
- 50
1
You can use the following function to scroll to an element. Just give the id or class to the function to which you want to scroll:
function scrollto(element) {
$('html, body').animate({scrollTop: ($(element).offset().top)}, 'slow');
}
For the glow effect you can use JQuery highlight function.
$(element).show("highlight");

twain
- 1,305
- 11
- 16