Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function rollUpForm()
- {
- // Adding a input to the body beginning
- $('<input>', {
- id: 'inputRollControl',
- type: 'text',
- value: '1',
- css: {
- display: 'none'
- }
- }).prependTo('body');
- // Getting the new element
- var inputControl = $('#inputRollControl');
- // Removing the style to focus on element and the page will roll up
- inputControl.removeAttr('style');
- // Focusing the element
- inputControl.focus();
- // Hiding the element controll again
- inputControl.attr('style', 'display: none');
- }
- // para ir para uma div
- $('html,body').animate({
- scrollTop: $("#blocoZero").offset().top},
- 'slow');
- // Topo
- $('html,body').animate({
- scrollTop: 0},
- 'slow');
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement