📅  最后修改于: 2022-03-11 14:53:12.433000             🧑  作者: Mango
//Using jQuery code
$('#right-button').click(function() {
event.preventDefault();
$('#content').animate({
marginLeft: "+=200px"
}, "slow");
});
$('#left-button').click(function() {
event.preventDefault();
$('#content').animate({
marginLeft: "-=200px"
}, "slow");
});