Home > Web Front-end > JS Tutorial > A brief discussion on how to add headers and copyrights to the jquery fullpage plug-in

A brief discussion on how to add headers and copyrights to the jquery fullpage plug-in

亚连
Release: 2018-05-25 17:16:51
Original
1380 people have browsed it

Below I will share with you a brief discussion on the method of adding headers and copyrights with the jquery fullpage plug-in. It has a good reference value and I hope it will be helpful to everyone.

Preface

We create a page through the jquery-fullpage plug-in, and the entire page is full-screen scrolling. However, we want to add a copyright to the last page, which is only about 100px high, without requiring a full screen for the copyright. How to do it? I searched and found various methods. Modify the source code, etc., or write your own code to judge. Dizzy. In fact, the official solution has been provided.

Below, let’s briefly talk about how to implement it

In fact, only the html part is needed to implement it

<p class="fullpage">
 <p class="section fp-auto-height">这里写头部</p>
 <p class="section">page1</p>
 <p class="section">page2</p>
 <p class="section">page3</p>
 <p class="section">page4</p>
 <p class="section fp-auto-height">这里写版权</p>
</p>
Copy after login

As above, I won’t talk about the js code. As long as you can run it, there will be no problem. Here you only need to add an fp-auto-height class to the head and bottom.

Isn’t it effective?

Hey, that’s because you only quoted js and not css. Just quote the following css.

https://github.com/alvarotrigo/fullPage.js/blob/master/dist/jquery.fullpage.css

In fact, the key code is just the following

.fp-auto-height.fp-section,
.fp-auto-height .fp-slide,
.fp-auto-height .fp-tableCell{
 height: auto !important;
}

.fp-responsive .fp-auto-height-responsive.fp-section,
.fp-responsive .fp-auto-height-responsive .fp-slide,
.fp-responsive .fp-auto-height-responsive .fp-tableCell {
 height: auto !important;
}
Copy after login

The above is what I compiled for everyone. I hope it will be helpful to everyone in the future.

Related articles:

Loop scheme in Ajax

Quick solution for ajax to return object Object

Introduction to the 4 common request methods of ajax in jQuery

The above is the detailed content of A brief discussion on how to add headers and copyrights to the jquery fullpage plug-in. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template