tailieunhanh - Học JavaScript qua ví dụ part 48
JavaScript trình diễn là tuyệt vời để tạo album ảnh, danh sách đấu giá, trình bày kỹ thuật số, phòng trưng bày nghệ thuật, carousels 3D, và như vậy (xem Hình ). Một khi bạn nhận được một trình chiếu cơ bản làm việc, bạn có thể sử dụng lại mã số để tạo ra các trình diễn khác và thay đổi hình ảnh cho phù hợp. | Introduction to Slideshows 441 Figure After clicking on the image this alert box displays the window s dimensions. Introduction to Slideshows Figure A carousel slideshow http dynamicindex14 . JavaScript slide shows are great for creating photo albums auction listings digital presentations art galleries 3D carousels and so on see Figure . Once you get a basic slide show working you can reuse the code to create other slide shows and change the images accordingly. There are numerous sites on the Web where you can get excellent JavaScript slideshow libraries that have already been created and free for reuse. The examples provided in this text are to give you some insight on how a simple JavaScript From the Library of 442 Chapter 12 Working with Images and Links slideshow is created how to control the start and stop of the slideshow how to create clickable images and simple animation. Once you understand the basics understanding and debugging existing code will be much easier. When you build a slide show the visitor of your site must be a first consideration for example what is the bandwidth and type of browser or will the load time be too slow if you are loading a large number of images Navigation is another important consideration. Will the visitor be able to control the slideshow manually or will it automatically start when the page loads and stop when it exits or when it has completed a specified number of cycles You might want to create buttons to control the slideshow such as start pause go back forward speed up slow down stop and so on. You might want to create optional hyperlinks or clickable images where each frame leads to a different URL. You might want to randomly display the images or show them in a certain sequence. The size of the images also weighs into a well-constructed slideshow. When you have a series of images coming from different sources they will probably not have the same
đang nạp các trang xem trước