Home > Web Front-end > HTML Tutorial > Make pie charts with CSS and SVG_html/css_WEB-ITnose

Make pie charts with CSS and SVG_html/css_WEB-ITnose

WBOY
Release: 2016-06-24 11:38:54
Original
1076 people have browsed it

Original source: lulux’s blog Welcome to share the original to Bole Headlines

When it comes to CSS technology, no one is more persistent than Lea Verou, but smart enough to work hard. Find various solutions to problems. Recently, Lea wrote, designed and published a book - CSS Secrets. This book is very interesting and includes some CSS tips and techniques for solving common problems. If you think your CSS skills are pretty good, read this book and you will be surprised. In this post, we post some snippets from the book, which were also featured in Lea’s recent talk at SmashingConf New York: Designing a Simple Pie Chart with CSS. Note that some demos may not run properly due to limited browser support. ??Edit

Pie chart , even the simplest form with only two colors is not simple to create using Web technology, although they are all common information content, ranging from simple Statistics include progress bar indicators and timers. This is usually achieved by using an external image editor to create multiple images for multiple values, or using a large JavaScript framework to design more complex charts.

Although this is not as difficult to achieve as it once seemed, there is no direct and easy way. However, there are better, more maintainable ways to do it.

Transform-based solution

This solution is the best from an HTML perspective: it only requires one element, and everything else can be done using pseudo-elements, transforms, and CSS gradients. We start with this simple element:

1

1

Now, let’s say we want to display a 20% scale pie chart. We will solve the issue of flexibility later. We first add a style to the element to make it a circle, which is our background:

Figure 1: The first step is to draw a circle (or to display 0 % scale pie chart)

1

2

3

4

5

.pie {

  width: 100px; height: 100px;

  border-radius: 50%;

  background: yellowgreen;

}

CSS

1

2

3

4

5

.pie {

width: 100px; height: 100px;

border-radius: 50%;

background: yellowgreen;

1

background-image: linear-gradient(to right, transparent 50%, #655 0);

}
Our pie chart shows percentages in green (specifically yellowgreen ) and brown ( #655 ). You might try using skew in transform for the proportional part, but after a few experiments it turns out that this is a very confusing solution. So we color the left and right parts of this pie chart with these two colors, and then for the percentage we want, we use a rotated pseudo-element to achieve that. We use a simple linear gradient to color the right half brown: CSS table>

Picture 2: Use a simple linear gradient to color the right semicircle brown

As shown in Figure 2, you are done. Now, we can go ahead and add styles to the pseudo-element to make it a mask:

CSS

1 background-image: linear-gradient(to right, transparent 50%, #655 0);

1

2

3

4

5

6

.pie::before {

  content: '';

  display: block;

  margin-left: 50%;

  height: 100%;

}

1

2

3

4

  • 5
  • 6
  • .pie:: before {

    content: '';

    display: block;

    margin-left: 50%;

    height: 100%;

    }

    Figure 3: The content within the dotted line indicates that the pseudo element will be used as a mask Area of ​​version

    You can see in Figure 3 that our pseudo-element is currently positioned relative to our pie element. Currently, it's not styled and doesn't cover anything, it's just a transparent rectangle. Before we start adding styles, let's analyze it first:

    1

    2

    3

    4

    5

    6

    7

    8

    9

    .pie::before {

      content: '';

      display: block;

      margin-left: 50%;

      height: 100%;

      border-radius: 0 100% 100% 0 / 50%;

      background-color: inherit;

      transform-origin: left;

    }

    Because we want it to cover the brown part of the circle, we need to apply a green background to it, using background-color: inherit to avoid repeated definitions, because We originally wanted it to be consistent with the background color of the parent element. We want it to rotate around the center point of the circle, which is on the left side of the pseudo element, so we need to apply a 0 50% to its transform-origin, or directly left. We don’t want it to be a rectangle, as it will extend past the edge of the pie, so we need to apply overflow: hidden to .pie , or a proper border-radius to make it a semicircle. To sum up, the CSS styles of pseudo-elements are as follows: CSS
    1 2 3 4 5 6 7 8 9 .pie::before { content: ''; display: block; margin-left: 50%; height: 100%; border-radius: 0 100% 100% 0 / 50%; background-color: inherit; transform-origin: left; }

    Figure 4: Pseudo-element after adding style (indicated by dotted lines here)

    Note: Do not use background: inherit; , use background-color : inherit ;, otherwise the gradient on the background image of the parent element will also be inherited

    Our pie chart is currently as shown in Figure 4. Now the fun starts! We can start rotating the pseudo-element by applying a rotate() transform to it. To show a 20% scale, we could give it a 72deg (0.2 x 360 = 72), or .2turn, which is more readable. You can see the results for different rotation angle values ​​in Figure 5.

    Figure 5: Pie charts showing different percentages, from left to right: 10% ( 36deg or .1turn ), 20% ( 72deg or .2turn ), 40% ( 144deg or .4turn )

    You might think we’re done, but it’s not that simple. Our pie chart has no problem displaying content from 0 to 50% size, but if we want to depict a 60% rotation (by applying .6turn ), the situation in Figure 6 will occur. But don't worry, we can fix this!

    Figure 6: For proportions exceeding 50%, our pie chart falls flat (here it is 60%)

    If we put 50%-100 % scale case As a separate question, it may be noted that one can use an inverted version of the previous solution: a brown pseudo-element rotated from 0 to .5turn. So, for a 60% pie chart, the CSS code for the pseudo-element is as follows:

    CSS

    tr>

    1

    2

    3

    4

    5

    6

    7

    8

    9

    10

    .pie::before {

      content: '';

      display: block;

      margin-left: 50%;

      height: 100%;

      border-radius: 0 100% 100% 0 / 50%;

      background: #655;

      transform-origin: left;

      transform: rotate(.1turn);

    }

    1 2 3 4 5 6 7 8 9 10
    .pie::before { content: ''; display: block; margin-left: 50%; height: 100%; border-radius: 0 100% 100% 0 / 50%; background: #655; transform-origin: left; transform: rotate(.1turn); }

    Figure 7: 60% correct way to open the pie chart~

    You can see the results in Figure 7. Since we've developed a method that can plot any percentage, we can even animate the pie chart from 0% to 100%, creating a fun progress bar:

    CSS

    1

    2

    3

    4

    5

    6

    7

    8

    9

    10

    11

    12

    13

    14

    15

    16

    17

    18

    19

    @keyframes spin {

      to { transform: rotate(.5turn); }

    }

     

    @keyframes bg {

      50% { background: #655; }

    }

     

    .pie::before {

      content: '';

      display: block;

      margin-left: 50%;

      height: 100%;

      border-radius: 0 100% 100% 0 / 50%;

      background-color: inherit;

      transform-origin: left;

      animation: spin 3s linear infinite,

                 bg 6s step-end infinite;

    }

    1

    2

    3

    4

    5

    6

    7

    1

    2

    20%

    60%

    8 9 10 11 12 13 14 15 16 17 18 19
    @keyframes spin { to { transform: rotate(.5turn); } } @keyframes bg { 50% { background: #655; } } .pie::before { content: ' '; display: block; margin-left: 50%; height: 100%; border-radius: 0 100% 100 % 0 / 50%; background-color: inherit; transform-origin: left; animation: spin 3s linear infinite, bg 6s step-end infinite; }
    See the Pen zGbNLJ by Airen (@airen) on CodePen. There is no problem with the display, but what if we add styles to multiple static pie charts with different percentages? What is the most common use case? Ideally, we would like to be able to simply enter something like:
    1 2
    20%
    60%

    Then you can get two pie charts, one representing 20% ​​and one representing 60%. First, let's study how to do it using inline styles. Then we can write a short script to parse the text content, add inline styles accordingly, and make the code elegant, encapsulated, maintainable, and most importantly One point, accessibility.

    One difficulty with using inline styles to control pie chart percentages is that the CSS code for setting the percentages is done with pseudo-elements. And as you know, we can't style pseudo-elements inline, so we need to innovate.

    Note: If the values ​​you want to use are within a range that does not require repeated complex calculations, you can use the same techniques, including debugging the animation step by step through them. Look at a simple example of this technique.

    See the Pen YXgNOK by Airen (@airen) on CodePen.

    The solution comes from one of the unlikeliest of places. We're going to use the animation we've already introduced, but in a paused state. Instead of making it run like a normal animation, we're going to use negative delay so that it can statically pause at a certain point. Weird? A negative animation-delay value is not only allowed by the specification, but also very useful in cases like this:

    Negative delays are valid. Similar to the delay of 0s, it means that the animation will be executed immediately, but it will run automatically based on the absolute value of the delay, so if the animation has started running before the specified time, it will run directly from the active time. . ?CSS Animations Level 1

    Because our animation is paused, its first frame is the only one we show (defined by our animation-delay). The percentage shown on the pie chart will be the total time of our animation-delay. For example, the current duration is 6s, and our animation-delay value is -1.2s to display a percentage of 20%. To simplify calculations, we set a duration of 100s. Remember that because our animation is paused forever, the delay size we assign to it has no effect.

    There is one last problem: the animation is assigned to the pseudo element, but we want to set the inline style for the .pie element. Since there is no animation on the

    , we can set animation-delay to it as an inline style, and then apply animation-delay: inherit; to the pseudo-element. To sum up, the HTML codes for the 20% and 60% pie charts are as follows:

    1

    2

    1 2

    The CSS code for the animation just proposed is as follows (the .pie rule is omitted as there is no change):

    CSS

    1

    2

    3

    4

    5

    6

    7

    8

    9

    10

    11

    12

    13

    14

    @keyframes spin {

      to { transform: rotate(.5turn); }

    }

     

    @keyframes bg {

      50% { background: #655; }

    }

     

    .pie::before {

      /* [Rest of styling stays the same] */

      animation: spin 50s linear infinite, bg 100s step-end infinite;

      animation-play-state: paused;

      animation-delay: inherit;

    }

    1

    2

    3

    4

    5

    6

    7

    8

    9 10

    11

    1

    2

    3

    4

    $$('.pie').forEach(function(pie) {

      var p = parseFloat(pie.textContent);

      pie.style.animationDelay = '-' p 's';

    });

    12 13 14
    @keyframes spin { to { transform: rotate(.5turn); } } @keyframes bg { 50% { background: #655; } } .pie::before { /* [Rest of styling stays the same] */ animation: spin 50s linear infinite, bg 100s step-end infinite; animation-play-state: paused; animation-delay: inherit; }
    At this time, you can Change the HTML tag to use percentages as content, as originally intended, and then add animation-delay inline styles to it through a simple script. JavaScript
    1 2 3 4 $$('.pie').forEach(function(pie) { var p = parseFloat(pie.textContent); pie.style.animationDelay = '-' p 's'; });

    Figure 8: Picture before hidden text

  • Convert the height of the pie chart to line-height (or add a line with the same height value -height, but this value is meaningless duplication of code, since line-height automatically calculates the value of height).
  • Set the size and position of the pseudo-element using absolute positioning so it doesn't crowd the text.
  • Add text-align: center; to center the text horizontally.
  • The final code is as follows:

    CSS

    1

    2

    3

    4

    5

    6

    7

    8

    9

    10

    11

    12

    13

    14

    15

    16

    17

    18

    19

    20

    21

    22

    23

    24

    25

    26

    27

    28

    29

    30

    .pie {

      position: relative;

      width: 100px;

      line-height: 100px;

      border-radius: 50%;

      background: yellowgreen;

      background-image: linear-gradient(to right, transparent 50%, #655 0);

      color: transparent;

      text-align: center;

    }

     

    @keyframes spin {

      to { transform: rotate(.5turn); }

    }

    @keyframes bg {

      50% { background: #655; }

    }

     

    .pie::before {

      content: '';

      position: absolute;

      top: 0; left: 50%;

      width: 50%; height: 100%;

      border-radius: 0 100% 100% 0 / 50%;

      background-color: inherit;

      transform-origin: left;

      animation: spin 50s linear infinite, bg 100s step-end infinite;

      animation-play-state: paused;

      animation-delay: inherit;

    }

    1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30
    .pie { position: relative; width: 100px; line-height: 100px; border- radius: 50%; background: yellowgreen; background-image: linear-gradient(to right, transparent 50%, #655 0); color: transparent ; text-align: center; } @keyframes spin { to { transform: rotate(.5turn ); } } @keyframes bg { 50% { background: #655; } } .pie::before { content: ''; position: absolute; top: 0; left: 50%; width: 50%; height: 100%; border-radius: 0 100% 100% 0 / 50%; background-color: inherit; transform-origin: left; animation: spin 50s linear infinite, bg 100s step-end infinite; animation-play-state: paused; animation-delay: inherit; }

    See the Pen qdvRMv by Airen (@airen) on CodePen.

    SVG-based solution

    SVG makes a lot of graphics work It gets even simpler, and pie charts are no exception. However, creating a pie chart using a path requires complex mathematical calculations. We can use a little trick instead.

    We start with a circle:

    Now, apply some basic styles to it:

    1

    2

    3

    1

    2

    3

    1

    2

    3

    4

    5

    circle {

      fill: yellowgreen;

      stroke: #655;

      stroke-width: 30;

    }

    CSS

    Note: As you may know, these CSS properties can also be used as attributes on SVG elements, which may be convenient if portability is taken into consideration .

    Figure 9: Starting with a green SVG circle with a fat #655 stroke

    You can see what we drew in Figure 9 A stroked circle. SVG strokes have more than just stroke and stroke-width attributes. There are also a number of less popular stroke-related properties that can be used to fine-tune strokes. One of them is stroke-dasharray, which is used to create dashed strokes. For example, we can use the following:

    1

    2

    3

    4

    5

    circle {

    fill: yellowgreen;

    1

    stroke-dasharray: 20 10;

    stroke: #655;

    stroke-width: 30;

    }

    1

    stroke-dasharray: 0 189;

    CSS
    1 stroke-dasharray: 20 10;
    Figure 10: A simple dashed stroke, Create through the stroke-dasharray attribute. What this line of code means is that our dashed line is a length of 20 plus a margin of 10, as shown in Figure 10. Here, you may be curious about what the relationship between this SVG stroke attribute and the pie chart is. It might be clearer if we applied a dash width of 0 to the stroke, and a margin greater than or equal to the circumference of our current circle (calculating the circumference: C = 2πr , so here C = 2π × 30 ≈ 189): CSS
    1 stroke -dasharray: 0 189;

    Figure 11: Effects corresponding to different stroke-dasharray values; from left to right: 0 189; 40 189; 95 189; 150 189

    Such as As shown in the first circle in Figure 11, its stroke has been removed, leaving only a green circle. But when we start increasing the first value, something interesting happens (Figure 11): because the margin is too long, we don’t have a dashed stroke, just a stroke covering the circumference of the circle we specified. Percentage of length.

    You may have started to figure out what's going on: if we reduce the radius of the circle to a certain point, it may become completely covered by its stroke, and end up with something very similar to Something about pie charts. For example, you can see in Figure 12: When applying a radius of 25 and a stroke-width of 50, it looks like this:

    Figure 12: Our SVG The image starts to look like a pie chart O(∩_∩)O

    Remember: SVG strokes are always half inside and half outside (centered) relative to the edge of the element. It should be possible to control this behavior in the future.

    1

    2

    3

    4

    5

    6

    7

    8

    9

    10

      

     

    circle {

      fill: yellowgreen;

      stroke: #655;

      stroke-width: 50;

      stroke-dasharray: 60 158; /* 2π × 25 ≈ 158 */

    }

    1

    2

    3

    4

    5

    6

    7

    8

    9 10

    1

    2

    3

    4

    5

    svg {

      transform: rotate(-90deg);

      background: yellowgreen;

      border-radius: 50%;

    }

    circle { fill: yellowgreen; stroke: #655; stroke-width: 50; stroke-dasharray: 60 158; /* 2π × 25 ≈ 158 */ }
    Now, it’s very easy to turn it into something like the pie chart we made in the previous solution: Just add a larger green circle below the stroke and rotate it 90° counterclockwise so that its starting point is in the top middle. Because the element is also an HTML element, we can add styles to it: CSS table>

    Figure 13: The final SVG pie chart

    You can see the final result in Figure 13. This technique makes it easier to animate pie charts from 0% to 100%. We just need to create a CSS animation to change the stroke-dasharray from 0 158 to 158 158:

    CSS

    1 2 3 4 5 svg { transform: rotate( -90deg); background: yellowgreen; border-radius: 50%; }

    1

    2

    3

    4

    5

    6

    7

    8

    9

    10

    11

    @keyframes fillup {

      to { stroke-dasharray: 158 158; }

    }

     

    circle {

      fill: yellowgreen;

      stroke: #655;

      stroke-width: 50;

      stroke-dasharray: 0 158;

      animation: fillup 5s linear infinite;

    }

    1

    2

    3

    4

    5

    6

    7

    1

    2

    3

      

    8 9 10 11
    @keyframes fillup { to { stroke-dasharray: 158 158; } } circle { fill: yellowgreen; stroke: #655; stroke-width: 50; stroke-dasharray: 0 158; animation: fillup 5s linear infinite; }
    As an additional improvement, we can specify a specific radius on the circle so that its circumference is infinitely close to 100, so that we can Specify the length of the stroke-dasharray as a percentage without calculation. Since the circumference is 2πr, our radius is 100 ÷ 2π ≈ 15.915494309, which is approximately equal to 16. We can also use the viewBox attribute to specify the size of the SVG, which allows it to automatically adjust to the size of the container without using the width and height attributes. After the above adjustments, the HTML tags of the pie chart in Figure 13 are as follows:
    1 2 3

    CSS如下:

     

     

     

     

     

    CSS

     

    1

    2

    3

    4

    5

    6

    7

    8

    9

    10

    11

    12

    13

    svg {

      width: 100px; height: 100px;

      transform: rotate(-90deg);

      background: yellowgreen;

      border-radius: 50%;

    }

     

    circle {

      fill: yellowgreen;

      stroke: #655;

      stroke-width: 32;

      stroke-dasharray: 38 100; /* for 38% */

    }

    1

    2

    3

    4

    5

    1

    2

    20%

    60%

    6 7 8 9 10 11 12 13
    svg {   width: 100px; height: 100px;   transform: rotate(-90deg);   background: yellowgreen;   border-radius: 50%; }   circle {   fill: yellowgreen;   stroke: #655;   stroke-width: 32;   stroke-dasharray: 38 100; /* for 38% */ }
    注意现在百分比已经可以很方便地改变了。当然,即使已经简化了标签,我们还是不想在绘制每个饼图的时候都重复一遍所有这些SVG标签。这是时候拿出JavaScript来帮我们一把了。我们写一个简单的脚本,让我们的HTML标签直接简单地这样写:    
    1 2
    20%
    60%

    Then add an inline SVG inside each .pie element, including all required elements and attributes. It also adds a element, for added accessibility, so that screen reader users can also know what percentage the current pie chart represents. The final script is as follows: </p> <p class="sycode"> </p> <p class="sycode"> </p> <p class="sycode"> </p> <p class="sycode"> </p> <p class="sycode"> </p> <p class="sycode"> </p> <p class="sycode"> </p> <p class="sycode"> </p> JavaScript <p class="sycode"> </p> <p class="sycode"> </p> <table> <tr> <td> <table> <tr> <td> <p class="sycode"> </p> <p class="sycode"> 1 </p> <p class="sycode"> 2 </p> <p class="sycode"> 3 </p> <p class="sycode"> 4 </p> <p class="sycode"> 5 </p> <p class="sycode"> 6 </p> <p class="sycode"> 7 </p> <p class="sycode"> 8 </p> <p class="sycode"> 9 </p> <p class="sycode"> 10 </p> <p class="sycode"> 11 </p> <p class="sycode"> 12 </p> <p class="sycode"> 13 </p> <p class="sycode"> 14 </p> <p class="sycode"> 15 </p> <p class="sycode"> 16 </p> <p class="sycode"> 17 </p> </td> <td> <p class="sycode"> </p> <p class="sycode"> $$('.pie').forEach(function(pie) { </p> <p class="sycode">   var p = parseFloat(pie.textContent); </p> <p class="sycode">   var NS = "http://www.w3.org/2000/svg"; </p> <p class="sycode">   var svg = document.createElementNS(NS, "svg"); </p> <p class="sycode">   var circle = document.createElementNS(NS, "circle"); </p> <p class="sycode">   var title = document.createElementNS(NS, "title"); </p> <p class="sycode">   circle.setAttribute("r", 16); </p> <p class="sycode">   circle.setAttribute("cx", 16); </p> <p class="sycode">   circle.setAttribute("cy", 16); </p> <p class="sycode">   circle.setAttribute("stroke-dasharray", p " 100"); </p> <p class="sycode">   svg.setAttribute("viewBox", "0 0 32 32"); </p> <p class="sycode">   title.textContent = pie.textContent; </p> <p class="sycode">   pie.textContent = ''; </p> <p class="sycode">   svg.appendChild(title); </p> <p class="sycode">   svg.appendChild(circle); </p> <p class="sycode">   pie.appendChild(svg); </p> <p class="sycode"> }); </p> </td> </tr> </table> 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 </td> <td> $$('.pie').forEach(function(pie) { var p = parseFloat(pie.textContent); var NS = "http://www.w3.org/2000/svg"; var svg = document.createElementNS(NS, "svg"); var circle = document.createElementNS( NS, "circle"); var title = document.createElementNS(NS, "title"); circle.setAttribute("r", 16); circle.setAttribute("cx", 16); circle.setAttribute("cy", 16); circle.setAttribute("stroke-dasharray", p " 100"); svg.setAttribute("viewBox", "0 0 32 32"); title.textContent = pie.textContent; pie.textContent = ''; svg.appendChild(title); svg.appendChild(circle); pie.appendChild(svg); }); </td> </tr> </table> <p> </p> <p>That’s it! You may think that the CSS method is better because its code is simpler and more reliable. However, the SVG method still has certain advantages over the pure CSS solution: </p> <li> You can <strong> add a third color very easily </strong>: just add another stroked circle and then use stroke -dashoffset sets its stroke properties. Then, add its stroke length to the stroke length of the circle below. If it is the previous CSS solution, how do you add a third color to the pie chart? </li> <li>We don’t need to consider the issue of printing, because the SVG element, just like the <img> element, is defaulted to be part of the content, and there is no problem with printing. The first option depends on the background, so it won't be printed. </li> <li>We can use inline styles to change colors, which means we can change colors directly through scripts (for example, changing colors based on user input). The first solution relies on pseudo-elements, which has no way to add inline styles other than through inheritance, which is inconvenient. </li> <p> It is said that programmers’ salaries are high, but few understand the pain of working overtime. Do you think every time that the salary is less when calculated based on time, so you want to scream in your heart? , either a salary increase, a salary increase, or a salary increase, why? ? Because we are not allowed to work overtime, this is impossible! ! ! </p> <p> Want to subvert your work model? Want to reduce your overtime hours? Join us and explore with us the freedom model that belongs to our programmers! </p> <p> A native APP for programmers, with the purpose of sharing knowledge and skills, and an online interactive platform in the form of rewards. </p> <p> We have a top technical team of nearly 20 people, as well as an excellent product and operations team. The team leaders all have more than 10 years of experience in the industry. </p> <p> Now we are recruiting original participating heroes. You will work with us to change the way programmers work and change the world of programmers! There will also be generous rewards. As our original participant, you will experience this programmer artifact with us. You can make professional suggestions, and we will humbly adopt them. Everyone will be a hero, and you will be the hero we need! At the same time, you can also invite your friends to participate in this hero recruitment interaction. </p> <p> We won’t waste too much of your time, we just need your professional opinion. As long as you spare 1 hour from a month, you can save two hours every day in the future, everything is for ourselves ! </p> <p> Come? Still not coming? </p> <p> Contactor password: 1955246408 (QQ) </p> <p class="sycode"></p> <p class="sycode"></p> <p class="sycode"> </p> <p class="sycode"></p> <p class="sycode"></p> <p class="sycode"> </p> <p class="sycode"></p> <p class="sycode"></p> </table> </table> </table> </table> </div> </div> <div style="height: 25px;"> <div class="wzconBq" style="display: inline-flex;"> <span>Related labels:</span> <div class="wzcbqd"> <a onclick="hits_log(2,'www',this);" href-data="https://www.php.cn/search?word=用css和svg制作饼图" target="_blank">用CSS和SVG制作饼图</a> </div> </div> <div style="display: inline-flex;float: right; color:#333333;">source:php.cn</div> </div> <div class="wzconOtherwz"> <a href="https://www.php.cn/faq/272670.html" title="css image responsive vertical and horizontal centering_html/css_WEB-ITnose"> <span>Previous article:css image responsive vertical and horizontal centering_html/css_WEB-ITnose</span> </a> <a href="https://www.php.cn/faq/272672.html" title="Effect_html/css_WEB-ITnose"> <span>Next article:Effect_html/css_WEB-ITnose</span> </a> </div> <div class="wzconShengming"> <div class="bzsmdiv">Statement of this Website</div> <div>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</div> </div> <ins class="adsbygoogle" style="display:block" data-ad-format="autorelaxed" data-ad-client="ca-pub-5902227090019525" data-ad-slot="2507867629"></ins> <script> (adsbygoogle = window.adsbygoogle || []).push({}); </script> <div class="wzconZzwz"> <div class="wzconZzwztitle">Latest Articles by Author</div> <ul> <li> <div class="wzczzwzli"> <span class="layui-badge-dots"></span> <a target="_blank" href="https://www.php.cn/faq/1796639331.html">What is a NullPointerException, and how do I fix it?</a> </div> <div>2024-10-22 09:46:29</div> </li> <li> <div class="wzczzwzli"> <span class="layui-badge-dots"></span> <a target="_blank" href="https://www.php.cn/faq/1796629482.html">From Novice to Coder: Your Journey Begins with C Fundamentals</a> </div> <div>2024-10-13 13:53:41</div> </li> <li> <div class="wzczzwzli"> <span class="layui-badge-dots"></span> <a target="_blank" href="https://www.php.cn/faq/1796628545.html">Unlocking Web Development with PHP: A Beginner's Guide</a> </div> <div>2024-10-12 12:15:51</div> </li> <li> <div class="wzczzwzli"> <span class="layui-badge-dots"></span> <a target="_blank" href="https://www.php.cn/faq/1796627928.html">Demystifying C: A Clear and Simple Path for New Programmers</a> </div> <div>2024-10-11 22:47:31</div> </li> <li> <div class="wzczzwzli"> <span class="layui-badge-dots"></span> <a target="_blank" href="https://www.php.cn/faq/1796627806.html">Unlock Your Coding Potential: C Programming for Absolute Beginners</a> </div> <div>2024-10-11 19:36:51</div> </li> <li> <div class="wzczzwzli"> <span class="layui-badge-dots"></span> <a target="_blank" href="https://www.php.cn/faq/1796627670.html">Unleash Your Inner Programmer: C for Absolute Beginners</a> </div> <div>2024-10-11 15:50:41</div> </li> <li> <div class="wzczzwzli"> <span class="layui-badge-dots"></span> <a target="_blank" href="https://www.php.cn/faq/1796627643.html">Automate Your Life with C: Scripts and Tools for Beginners</a> </div> <div>2024-10-11 15:07:41</div> </li> <li> <div class="wzczzwzli"> <span class="layui-badge-dots"></span> <a target="_blank" href="https://www.php.cn/faq/1796627620.html">PHP Made Easy: Your First Steps in Web Development</a> </div> <div>2024-10-11 14:21:21</div> </li> <li> <div class="wzczzwzli"> <span class="layui-badge-dots"></span> <a target="_blank" href="https://www.php.cn/faq/1796627574.html">Build Anything with Python: A Beginner's Guide to Unleashing Your Creativity</a> </div> <div>2024-10-11 12:59:11</div> </li> <li> <div class="wzczzwzli"> <span class="layui-badge-dots"></span> <a target="_blank" href="https://www.php.cn/faq/1796627539.html">The Key to Coding: Unlocking the Power of Python for Beginners</a> </div> <div>2024-10-11 12:17:31</div> </li> </ul> </div> <div class="wzconZzwz"> <div class="wzconZzwztitle">Latest Issues</div> <div class="wdsyContent"> <div class="wdsyConDiv flexRow wdsyConDiv1"> <div class="wdcdContent flexColumn"> <a href="https://www.php.cn/wenda/176325.html" target="_blank" title="I'm having trouble with a CSS grid where the height isn't what I expected, what mistakes might I be making?" class="wdcdcTitle">I'm having trouble with a CSS grid where the height isn't what I expected, what mistakes might I be making?</a> <a href="https://www.php.cn/wenda/176325.html" class="wdcdcCons">I'm currently learning CSS grids and was asked to make this card by breaking it into a gri...</a> <div class="wdcdcInfo flexRow"> <div class="wdcdcileft"> <span class="wdcdciSpan"> From 2024-04-06 12:52:14</span> </div> <div class="wdcdciright flexRow"> <div class="wdcdcirdz flexRow ira"> <b class="wdcdcirdzi"></b>0 </div> <div class="wdcdcirpl flexRow ira"><b class="wdcdcirpli"></b>1</div> <div class="wdcdcirwatch flexRow ira"><b class="wdcdcirwatchi"></b>339</div> </div> </div> </div> </div> <div class="wdsyConLine wdsyConLine2"></div> <div class="wdsyConDiv flexRow wdsyConDiv1"> <div class="wdcdContent flexColumn"> <a href="https://www.php.cn/wenda/176282.html" target="_blank" title="Can PDF files run HTML5 and Javascript?" class="wdcdcTitle">Can PDF files run HTML5 and Javascript?</a> <a href="https://www.php.cn/wenda/176282.html" class="wdcdcCons">I have a stupid idea to try and make a program that won't be blocked on any computer since...</a> <div class="wdcdcInfo flexRow"> <div class="wdcdcileft"> <span class="wdcdciSpan"> From 2024-04-05 12:57:00</span> </div> <div class="wdcdciright flexRow"> <div class="wdcdcirdz flexRow ira"> <b class="wdcdcirdzi"></b>0 </div> <div class="wdcdcirpl flexRow ira"><b class="wdcdcirpli"></b>1</div> <div class="wdcdcirwatch flexRow ira"><b class="wdcdcirwatchi"></b>456</div> </div> </div> </div> </div> <div class="wdsyConLine wdsyConLine2"></div> <div class="wdsyConDiv flexRow wdsyConDiv1"> <div class="wdcdContent flexColumn"> <a href="https://www.php.cn/wenda/176271.html" target="_blank" title="How to remove the space below each line on the Tic-Tac-Toe board in Next.js using CSS?" class="wdcdcTitle">How to remove the space below each line on the Tic-Tac-Toe board in Next.js using CSS?</a> <a href="https://www.php.cn/wenda/176271.html" class="wdcdcCons">Why is there a space below each line? (CSS) I'm trying to make a Next.js tic-tac-toe app t...</a> <div class="wdcdcInfo flexRow"> <div class="wdcdcileft"> <span class="wdcdciSpan"> From 2024-04-05 11:39:02</span> </div> <div class="wdcdciright flexRow"> <div class="wdcdcirdz flexRow ira"> <b class="wdcdcirdzi"></b>0 </div> <div class="wdcdcirpl flexRow ira"><b class="wdcdcirpli"></b>1</div> <div class="wdcdcirwatch flexRow ira"><b class="wdcdcirwatchi"></b>1431</div> </div> </div> </div> </div> <div class="wdsyConLine wdsyConLine2"></div> <div class="wdsyConDiv flexRow wdsyConDiv1"> <div class="wdcdContent flexColumn"> <a href="https://www.php.cn/wenda/176153.html" target="_blank" title="JavaScript is not running as expected" class="wdcdcTitle">JavaScript is not running as expected</a> <a href="https://www.php.cn/wenda/176153.html" class="wdcdcCons">I'm trying to make htmlcssjs responsive but it doesn't work as expected, when it is minimi...</a> <div class="wdcdcInfo flexRow"> <div class="wdcdcileft"> <span class="wdcdciSpan"> From 2024-04-04 13:05:32</span> </div> <div class="wdcdciright flexRow"> <div class="wdcdcirdz flexRow ira"> <b class="wdcdcirdzi"></b>0 </div> <div class="wdcdcirpl flexRow ira"><b class="wdcdcirpli"></b>1</div> <div class="wdcdcirwatch flexRow ira"><b class="wdcdcirwatchi"></b>306</div> </div> </div> </div> </div> <div class="wdsyConLine wdsyConLine2"></div> <div class="wdsyConDiv flexRow wdsyConDiv1"> <div class="wdcdContent flexColumn"> <a href="https://www.php.cn/wenda/175967.html" target="_blank" title="Create diverse card layouts using a single grid or Flex: a practical guide" class="wdcdcTitle">Create diverse card layouts using a single grid or Flex: a practical guide</a> <a href="https://www.php.cn/wenda/175967.html" class="wdcdcCons">I'm trying to make a responsive card layout like the one pictured. What I'm currently doin...</a> <div class="wdcdcInfo flexRow"> <div class="wdcdcileft"> <span class="wdcdciSpan"> From 2024-04-02 21:07:36</span> </div> <div class="wdcdciright flexRow"> <div class="wdcdcirdz flexRow ira"> <b class="wdcdcirdzi"></b>0 </div> <div class="wdcdcirpl flexRow ira"><b class="wdcdcirpli"></b>2</div> <div class="wdcdcirwatch flexRow ira"><b class="wdcdcirwatchi"></b>377</div> </div> </div> </div> </div> <div class="wdsyConLine wdsyConLine2"></div> </div> </div> <div class="wzconZt" > <div class="wzczt-title"> <div>Related Topics</div> <a href="https://www.php.cn/faq/zt" target="_blank">More> </a> </div> <div class="wzcttlist"> <ul> <li class="ul-li"> <a target="_blank" href="https://www.php.cn/faq/zzsycookiesmy"><img src="https://img.php.cn/upload/subject/202407/22/2024072213252570541.jpg?x-oss-process=image/resize,m_fill,h_145,w_220" alt="What does it mean to block all cookies?" /> </a> <a target="_blank" href="https://www.php.cn/faq/zzsycookiesmy" class="title-a-spanl" title="What does it mean to block all cookies?"><span>What does it mean to block all cookies?</span> </a> </li> <li class="ul-li"> <a target="_blank" href="https://www.php.cn/faq/rbbhqzs"><img src="https://img.php.cn/upload/subject/202407/22/2024072213240836070.jpg?x-oss-process=image/resize,m_fill,h_145,w_220" alt="Ripple currency market trend" /> </a> <a target="_blank" href="https://www.php.cn/faq/rbbhqzs" class="title-a-spanl" title="Ripple currency market trend"><span>Ripple currency market trend</span> </a> </li> <li class="ul-li"> <a target="_blank" href="https://www.php.cn/faq/cyddnsynx"><img src="https://img.php.cn/upload/subject/202407/22/2024072213495124882.jpg?x-oss-process=image/resize,m_fill,h_145,w_220" alt="What are the commonly used DNSs?" /> </a> <a target="_blank" href="https://www.php.cn/faq/cyddnsynx" class="title-a-spanl" title="What are the commonly used DNSs?"><span>What are the commonly used DNSs?</span> </a> </li> <li class="ul-li"> <a target="_blank" href="https://www.php.cn/faq/wjkzm"><img src="https://img.php.cn/upload/subject/202407/22/2024072214193651166.jpg?x-oss-process=image/resize,m_fill,h_145,w_220" alt="What does a file extension usually mean?" /> </a> <a target="_blank" href="https://www.php.cn/faq/wjkzm" class="title-a-spanl" title="What does a file extension usually mean?"><span>What does a file extension usually mean?</span> </a> </li> <li class="ul-li"> <a target="_blank" href="https://www.php.cn/faq/ksgjkjj"><img src="https://img.php.cn/upload/subject/202407/22/2024072212083235967.jpg?x-oss-process=image/resize,m_fill,h_145,w_220" alt="Quick shutdown shortcut key" /> </a> <a target="_blank" href="https://www.php.cn/faq/ksgjkjj" class="title-a-spanl" title="Quick shutdown shortcut key"><span>Quick shutdown shortcut key</span> </a> </li> <li class="ul-li"> <a target="_blank" href="https://www.php.cn/faq/articlebqyldy"><img src="https://img.php.cn/upload/subject/202407/22/2024072213322159054.jpg?x-oss-process=image/resize,m_fill,h_145,w_220" alt="What is the article tag used to define?" /> </a> <a target="_blank" href="https://www.php.cn/faq/articlebqyldy" class="title-a-spanl" title="What is the article tag used to define?"><span>What is the article tag used to define?</span> </a> </li> <li class="ul-li"> <a target="_blank" href="https://www.php.cn/faq/gitcommit"><img src="https://img.php.cn/upload/subject/202407/22/2024072214285424929.jpg?x-oss-process=image/resize,m_fill,h_145,w_220" alt="How to undo after gitcommit" /> </a> <a target="_blank" href="https://www.php.cn/faq/gitcommit" class="title-a-spanl" title="How to undo after gitcommit"><span>How to undo after gitcommit</span> </a> </li> <li class="ul-li"> <a target="_blank" href="https://www.php.cn/faq/goyyzdysfynx"><img src="https://img.php.cn/upload/subject/202407/22/2024072213284321788.jpg?x-oss-process=image/resize,m_fill,h_145,w_220" alt="What are the operators in Go language?" /> </a> <a target="_blank" href="https://www.php.cn/faq/goyyzdysfynx" class="title-a-spanl" title="What are the operators in Go language?"><span>What are the operators in Go language?</span> </a> </li> </ul> </div> </div> </div> </div> <div class="phpwzright"> <ins class="adsbygoogle" style="display:block" data-ad-client="ca-pub-5902227090019525" data-ad-slot="3653428331" data-ad-format="auto" data-full-width-responsive="true"></ins> <script> (adsbygoogle = window.adsbygoogle || []).push({}); </script> <div class="wzrOne"> <div class="wzroTitle">Popular Recommendations</div> <div class="wzroList"> <ul> <li> <div class="wzczzwzli"> <span class="layui-badge-dots wzrolr"></span> <a style="height: auto;" title="What does url mean?" href="https://www.php.cn/faq/418772.html">What does url mean?</a> </div> </li> <li> <div class="wzczzwzli"> <span class="layui-badge-dots wzrolr"></span> <a style="height: auto;" title="What does DOM mean?" href="https://www.php.cn/faq/414303.html">What does DOM mean?</a> </div> </li> <li> <div class="wzczzwzli"> <span class="layui-badge-dots wzrolr"></span> <a style="height: auto;" title="How to change image size" href="https://www.php.cn/faq/414252.html">How to change image size</a> </div> </li> <li> <div class="wzczzwzli"> <span class="layui-badge-dots wzrolr"></span> <a style="height: auto;" title="How to make font bold in HTML" href="https://www.php.cn/faq/414520.html">How to make font bold in HTML</a> </div> </li> <li> <div class="wzczzwzli"> <span class="layui-badge-dots wzrolr"></span> <a style="height: auto;" title="How to set the size of html images" href="https://www.php.cn/faq/475145.html">How to set the size of html images</a> </div> </li> </ul> </div> </div> <script src="https://sw.php.cn/hezuo/cac1399ab368127f9b113b14eb3316d0.js" type="text/javascript"></script> <div class="wzrThree"> <div class="wzrthree-title"> <div>Popular Tutorials</div> <a target="_blank" href="https://www.php.cn/course.html">More> </a> </div> <div class="wzrthreelist swiper2"> <div class="wzrthreeTab swiper-wrapper"> <div class="check tabdiv swiper-slide" data-id="one">Related Tutorials <div></div></div> <div class="tabdiv swiper-slide" data-id="two">Popular Recommendations<div></div></div> <div class="tabdiv swiper-slide" data-id="three">Latest courses<div></div></div> </div> <ul class="one"> <li> <a target="_blank" href="https://www.php.cn/course/812.html" title="The latest ThinkPHP 5.1 world premiere video tutorial (60 days to become a PHP expert online training course)" class="wzrthreelaimg"> <img src="https://img.php.cn/upload/course/000/000/041/620debc3eab3f377.jpg" alt="The latest ThinkPHP 5.1 world premiere video tutorial (60 days to become a PHP expert online training course)"/> </a> <div class="wzrthree-right"> <a target="_blank" title="The latest ThinkPHP 5.1 world premiere video tutorial (60 days to become a PHP expert online training course)" href="https://www.php.cn/course/812.html">The latest ThinkPHP 5.1 world premiere video tutorial (60 days to become a PHP expert online training course)</a> <div class="wzrthreerb"> <div>1425178 <b class="kclbcollectb"></b></div> <div class="courseICollection" data-id="812"> <b class="nofollow small-nocollect"></b> </div> </div> </div> </li> <li> <a target="_blank" href="https://www.php.cn/course/74.html" title="PHP introductory tutorial one: Learn PHP in one week" class="wzrthreelaimg"> <img src="https://img.php.cn/upload/course/000/000/068/6253d1e28ef5c345.png" alt="PHP introductory tutorial one: Learn PHP in one week"/> </a> <div class="wzrthree-right"> <a target="_blank" title="PHP introductory tutorial one: Learn PHP in one week" href="https://www.php.cn/course/74.html">PHP introductory tutorial one: Learn PHP in one week</a> <div class="wzrthreerb"> <div>4271813 <b class="kclbcollectb"></b></div> <div class="courseICollection" data-id="74"> <b class="nofollow small-nocollect"></b> </div> </div> </div> </li> <li> <a target="_blank" href="https://www.php.cn/course/286.html" title="JAVA Beginner's Video Tutorial" class="wzrthreelaimg"> <img src="https://img.php.cn/upload/course/000/000/068/62590a2bacfd9379.png" alt="JAVA Beginner's Video Tutorial"/> </a> <div class="wzrthree-right"> <a target="_blank" title="JAVA Beginner's Video Tutorial" href="https://www.php.cn/course/286.html">JAVA Beginner's Video Tutorial</a> <div class="wzrthreerb"> <div>2553992 <b class="kclbcollectb"></b></div> <div class="courseICollection" data-id="286"> <b class="nofollow small-nocollect"></b> </div> </div> </div> </li> <li> <a target="_blank" href="https://www.php.cn/course/504.html" title="Little Turtle's zero-based introduction to learning Python video tutorial" class="wzrthreelaimg"> <img src="https://img.php.cn/upload/course/000/000/068/62590a67ce3a6655.png" alt="Little Turtle's zero-based introduction to learning Python video tutorial"/> </a> <div class="wzrthree-right"> <a target="_blank" title="Little Turtle's zero-based introduction to learning Python video tutorial" href="https://www.php.cn/course/504.html">Little Turtle's zero-based introduction to learning Python video tutorial</a> <div class="wzrthreerb"> <div>508609 <b class="kclbcollectb"></b></div> <div class="courseICollection" data-id="504"> <b class="nofollow small-nocollect"></b> </div> </div> </div> </li> <li> <a target="_blank" href="https://www.php.cn/course/2.html" title="PHP zero-based introductory tutorial" class="wzrthreelaimg"> <img src="https://img.php.cn/upload/course/000/000/068/6253de27bc161468.png" alt="PHP zero-based introductory tutorial"/> </a> <div class="wzrthree-right"> <a target="_blank" title="PHP zero-based introductory tutorial" href="https://www.php.cn/course/2.html">PHP zero-based introductory tutorial</a> <div class="wzrthreerb"> <div>864348 <b class="kclbcollectb"></b></div> <div class="courseICollection" data-id="2"> <b class="nofollow small-nocollect"></b> </div> </div> </div> </li> </ul> <ul class="two" style="display: none;"> <li> <a target="_blank" href="https://www.php.cn/course/812.html" title="The latest ThinkPHP 5.1 world premiere video tutorial (60 days to become a PHP expert online training course)" class="wzrthreelaimg"> <img src="https://img.php.cn/upload/course/000/000/041/620debc3eab3f377.jpg" alt="The latest ThinkPHP 5.1 world premiere video tutorial (60 days to become a PHP expert online training course)"/> </a> <div class="wzrthree-right"> <a target="_blank" title="The latest ThinkPHP 5.1 world premiere video tutorial (60 days to become a PHP expert online training course)" href="https://www.php.cn/course/812.html">The latest ThinkPHP 5.1 world premiere video tutorial (60 days to become a PHP expert online training course)</a> <div class="wzrthreerb"> <div >1425178 times of learning</div> <div class="courseICollection" data-id="812"> <b class="nofollow small-nocollect"></b> </div> </div> </div> </li> <li> <a target="_blank" href="https://www.php.cn/course/286.html" title="JAVA Beginner's Video Tutorial" class="wzrthreelaimg"> <img src="https://img.php.cn/upload/course/000/000/068/62590a2bacfd9379.png" alt="JAVA Beginner's Video Tutorial"/> </a> <div class="wzrthree-right"> <a target="_blank" title="JAVA Beginner's Video Tutorial" href="https://www.php.cn/course/286.html">JAVA Beginner's Video Tutorial</a> <div class="wzrthreerb"> <div >2553992 times of learning</div> <div class="courseICollection" data-id="286"> <b class="nofollow small-nocollect"></b> </div> </div> </div> </li> <li> <a target="_blank" href="https://www.php.cn/course/504.html" title="Little Turtle's zero-based introduction to learning Python video tutorial" class="wzrthreelaimg"> <img src="https://img.php.cn/upload/course/000/000/068/62590a67ce3a6655.png" alt="Little Turtle's zero-based introduction to learning Python video tutorial"/> </a> <div class="wzrthree-right"> <a target="_blank" title="Little Turtle's zero-based introduction to learning Python video tutorial" href="https://www.php.cn/course/504.html">Little Turtle's zero-based introduction to learning Python video tutorial</a> <div class="wzrthreerb"> <div >508609 times of learning</div> <div class="courseICollection" data-id="504"> <b class="nofollow small-nocollect"></b> </div> </div> </div> </li> <li> <a target="_blank" href="https://www.php.cn/course/901.html" title="Quick introduction to web front-end development" class="wzrthreelaimg"> <img src="https://img.php.cn/upload/course/000/000/067/64be28a53a4f6310.png" alt="Quick introduction to web front-end development"/> </a> <div class="wzrthree-right"> <a target="_blank" title="Quick introduction to web front-end development" href="https://www.php.cn/course/901.html">Quick introduction to web front-end development</a> <div class="wzrthreerb"> <div >216058 times of learning</div> <div class="courseICollection" data-id="901"> <b class="nofollow small-nocollect"></b> </div> </div> </div> </li> <li> <a target="_blank" href="https://www.php.cn/course/234.html" title="Master PS video tutorials from scratch" class="wzrthreelaimg"> <img src="https://img.php.cn/upload/course/000/000/068/62611f57ed0d4840.jpg" alt="Master PS video tutorials from scratch"/> </a> <div class="wzrthree-right"> <a target="_blank" title="Master PS video tutorials from scratch" href="https://www.php.cn/course/234.html">Master PS video tutorials from scratch</a> <div class="wzrthreerb"> <div >894124 times of learning</div> <div class="courseICollection" data-id="234"> <b class="nofollow small-nocollect"></b> </div> </div> </div> </li> </ul> <ul class="three" style="display: none;"> <li> <a target="_blank" href="https://www.php.cn/course/1648.html" title="[Web front-end] Node.js quick start" class="wzrthreelaimg"> <img src="https://img.php.cn/upload/course/000/000/067/662b5d34ba7c0227.png" alt="[Web front-end] Node.js quick start"/> </a> <div class="wzrthree-right"> <a target="_blank" title="[Web front-end] Node.js quick start" href="https://www.php.cn/course/1648.html">[Web front-end] Node.js quick start</a> <div class="wzrthreerb"> <div >7800 times of learning</div> <div class="courseICollection" data-id="1648"> <b class="nofollow small-nocollect"></b> </div> </div> </div> </li> <li> <a target="_blank" href="https://www.php.cn/course/1647.html" title="Complete collection of foreign web development full-stack courses" class="wzrthreelaimg"> <img src="https://img.php.cn/upload/course/000/000/067/6628cc96e310c937.png" alt="Complete collection of foreign web development full-stack courses"/> </a> <div class="wzrthree-right"> <a target="_blank" title="Complete collection of foreign web development full-stack courses" href="https://www.php.cn/course/1647.html">Complete collection of foreign web development full-stack courses</a> <div class="wzrthreerb"> <div >6240 times of learning</div> <div class="courseICollection" data-id="1647"> <b class="nofollow small-nocollect"></b> </div> </div> </div> </li> <li> <a target="_blank" href="https://www.php.cn/course/1646.html" title="Go language practical GraphQL" class="wzrthreelaimg"> <img src="https://img.php.cn/upload/course/000/000/067/662221173504a436.png" alt="Go language practical GraphQL"/> </a> <div class="wzrthree-right"> <a target="_blank" title="Go language practical GraphQL" href="https://www.php.cn/course/1646.html">Go language practical GraphQL</a> <div class="wzrthreerb"> <div >5132 times of learning</div> <div class="courseICollection" data-id="1646"> <b class="nofollow small-nocollect"></b> </div> </div> </div> </li> <li> <a target="_blank" href="https://www.php.cn/course/1645.html" title="550W fan master learns JavaScript from scratch step by step" class="wzrthreelaimg"> <img src="https://img.php.cn/upload/course/000/000/067/662077e163124646.png" alt="550W fan master learns JavaScript from scratch step by step"/> </a> <div class="wzrthree-right"> <a target="_blank" title="550W fan master learns JavaScript from scratch step by step" href="https://www.php.cn/course/1645.html">550W fan master learns JavaScript from scratch step by step</a> <div class="wzrthreerb"> <div >714 times of learning</div> <div class="courseICollection" data-id="1645"> <b class="nofollow small-nocollect"></b> </div> </div> </div> </li> <li> <a target="_blank" href="https://www.php.cn/course/1644.html" title="Python master Mosh, a beginner with zero basic knowledge can get started in 6 hours" class="wzrthreelaimg"> <img src="https://img.php.cn/upload/course/000/000/067/6616418ca80b8916.png" alt="Python master Mosh, a beginner with zero basic knowledge can get started in 6 hours"/> </a> <div class="wzrthree-right"> <a target="_blank" title="Python master Mosh, a beginner with zero basic knowledge can get started in 6 hours" href="https://www.php.cn/course/1644.html">Python master Mosh, a beginner with zero basic knowledge can get started in 6 hours</a> <div class="wzrthreerb"> <div >26001 times of learning</div> <div class="courseICollection" data-id="1644"> <b class="nofollow small-nocollect"></b> </div> </div> </div> </li> </ul> </div> <script> var mySwiper = new Swiper('.swiper2', { autoplay: false,//可选选项,自动滑动 slidesPerView : 'auto', }) $('.wzrthreeTab>div').click(function(e){ $('.wzrthreeTab>div').removeClass('check') $(this).addClass('check') $('.wzrthreelist>ul').css('display','none') $('.'+e.currentTarget.dataset.id).show() }) </script> </div> <div class="wzrFour"> <div class="wzrfour-title"> <div>Latest Downloads</div> <a href="https://www.php.cn/xiazai">More> </a> </div> <script> $(document).ready(function(){ var sjyx_banSwiper = new Swiper(".sjyx_banSwiperwz",{ speed:1000, autoplay:{ delay:3500, disableOnInteraction: false, }, pagination:{ el:'.sjyx_banSwiperwz .swiper-pagination', clickable :false, }, loop:true }) }) </script> <div class="wzrfourList swiper3"> <div class="wzrfourlTab swiper-wrapper"> <div class="check swiper-slide" data-id="onef">Web Effects <div></div></div> <div class="swiper-slide" data-id="twof">Website Source Code<div></div></div> <div class="swiper-slide" data-id="threef">Website Materials<div></div></div> <div class="swiper-slide" data-id="fourf">Front End Template<div></div></div> </div> <ul class="onef"> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a target="_blank" title="jQuery enterprise message form contact code" href="https://www.php.cn/toolset/js-special-effects/8071">[form button] jQuery enterprise message form contact code</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a target="_blank" title="HTML5 MP3 music box playback effects" href="https://www.php.cn/toolset/js-special-effects/8070">[Player special effects] HTML5 MP3 music box playback effects</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a target="_blank" title="HTML5 cool particle animation navigation menu special effects" href="https://www.php.cn/toolset/js-special-effects/8069">[Menu navigation] HTML5 cool particle animation navigation menu special effects</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a target="_blank" title="jQuery visual form drag and drop editing code" href="https://www.php.cn/toolset/js-special-effects/8068">[form button] jQuery visual form drag and drop editing code</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a target="_blank" title="VUE.JS imitation Kugou music player code" href="https://www.php.cn/toolset/js-special-effects/8067">[Player special effects] VUE.JS imitation Kugou music player code</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a target="_blank" title="Classic html5 pushing box game" href="https://www.php.cn/toolset/js-special-effects/8066">[html5 special effects] Classic html5 pushing box game</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a target="_blank" title="jQuery scrolling to add or reduce image effects" href="https://www.php.cn/toolset/js-special-effects/8065">[Picture special effects] jQuery scrolling to add or reduce image effects</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a target="_blank" title="CSS3 personal album cover hover zoom effect" href="https://www.php.cn/toolset/js-special-effects/8064">[Photo album effects] CSS3 personal album cover hover zoom effect</a> </div> </li> </ul> <ul class="twof" style="display:none"> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8328" title="Home Decor Cleaning and Repair Service Company Website Template" target="_blank">[Front-end template] Home Decor Cleaning and Repair Service Company Website Template</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8327" title="Fresh color personal resume guide page template" target="_blank">[Front-end template] Fresh color personal resume guide page template</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8326" title="Designer Creative Job Resume Web Template" target="_blank">[Front-end template] Designer Creative Job Resume Web Template</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8325" title="Modern engineering construction company website template" target="_blank">[Front-end template] Modern engineering construction company website template</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8324" title="Responsive HTML5 template for educational service institutions" target="_blank">[Front-end template] Responsive HTML5 template for educational service institutions</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8323" title="Online e-book store mall website template" target="_blank">[Front-end template] Online e-book store mall website template</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8322" title="IT technology solves Internet company website template" target="_blank">[Front-end template] IT technology solves Internet company website template</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8321" title="Purple style foreign exchange trading service website template" target="_blank">[Front-end template] Purple style foreign exchange trading service website template</a> </div> </li> </ul> <ul class="threef" style="display:none"> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-materials/3078" target="_blank" title="Cute summer elements vector material (EPS PNG)">[PNG material] Cute summer elements vector material (EPS PNG)</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-materials/3077" target="_blank" title="Four red 2023 graduation badges vector material (AI EPS PNG)">[PNG material] Four red 2023 graduation badges vector material (AI EPS PNG)</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-materials/3076" target="_blank" title="Singing bird and cart filled with flowers design spring banner vector material (AI EPS)">[banner picture] Singing bird and cart filled with flowers design spring banner vector material (AI EPS)</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-materials/3075" target="_blank" title="Golden graduation cap vector material (EPS PNG)">[PNG material] Golden graduation cap vector material (EPS PNG)</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-materials/3074" target="_blank" title="Black and white style mountain icon vector material (EPS PNG)">[PNG material] Black and white style mountain icon vector material (EPS PNG)</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-materials/3073" target="_blank" title="Superhero silhouette vector material (EPS PNG) with different color cloaks and different poses">[PNG material] Superhero silhouette vector material (EPS PNG) with different color cloaks and different poses</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-materials/3072" target="_blank" title="Flat style Arbor Day banner vector material (AI+EPS)">[banner picture] Flat style Arbor Day banner vector material (AI+EPS)</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-materials/3071" target="_blank" title="Nine comic-style exploding chat bubbles vector material (EPS+PNG)">[PNG material] Nine comic-style exploding chat bubbles vector material (EPS+PNG)</a> </div> </li> </ul> <ul class="fourf" style="display:none"> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8328" target="_blank" title="Home Decor Cleaning and Repair Service Company Website Template">[Front-end template] Home Decor Cleaning and Repair Service Company Website Template</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8327" target="_blank" title="Fresh color personal resume guide page template">[Front-end template] Fresh color personal resume guide page template</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8326" target="_blank" title="Designer Creative Job Resume Web Template">[Front-end template] Designer Creative Job Resume Web Template</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8325" target="_blank" title="Modern engineering construction company website template">[Front-end template] Modern engineering construction company website template</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8324" target="_blank" title="Responsive HTML5 template for educational service institutions">[Front-end template] Responsive HTML5 template for educational service institutions</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8323" target="_blank" title="Online e-book store mall website template">[Front-end template] Online e-book store mall website template</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8322" target="_blank" title="IT technology solves Internet company website template">[Front-end template] IT technology solves Internet company website template</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8321" target="_blank" title="Purple style foreign exchange trading service website template">[Front-end template] Purple style foreign exchange trading service website template</a> </div> </li> </ul> </div> <script> var mySwiper = new Swiper('.swiper3', { autoplay: false,//可选选项,自动滑动 slidesPerView : 'auto', }) $('.wzrfourlTab>div').click(function(e){ $('.wzrfourlTab>div').removeClass('check') $(this).addClass('check') $('.wzrfourList>ul').css('display','none') $('.'+e.currentTarget.dataset.id).show() }) </script> </div> </div> </div> <footer> <div class="footer"> <div class="footertop"> <img src="/static/imghw/logo.png" alt=""> <p>Public welfare online PHP training,Help PHP learners grow quickly!</p> </div> <div class="footermid"> <a href="https://www.php.cn/about/us.html">About us</a> <a href="https://www.php.cn/about/disclaimer.html">Disclaimer</a> <a href="https://www.php.cn/update/article_0_1.html">Sitemap</a> </div> <div class="footerbottom"> <p> © php.cn All rights reserved </p> </div> </div> </footer> <input type="hidden" id="verifycode" value="/captcha.html"> <script>layui.use(['element', 'carousel'], function () {var element = layui.element;$ = layui.jquery;var carousel = layui.carousel;carousel.render({elem: '#test1', width: '100%', height: '330px', arrow: 'always'});$.getScript('/static/js/jquery.lazyload.min.js', function () {$("img").lazyload({placeholder: "/static/images/load.jpg", effect: "fadeIn", threshold: 200, skip_invisible: false});});});</script> <script src="/static/js/common_new.js"></script> <script type="text/javascript" src="/static/js/jquery.cookie.js?1735513585"></script> <script src="https://vdse.bdstatic.com//search-video.v1.min.js"></script> <link rel='stylesheet' id='_main-css' href='/static/css/viewer.min.css?2' type='text/css' media='all'/> <script type='text/javascript' src='/static/js/viewer.min.js?1'></script> <script type='text/javascript' src='/static/js/jquery-viewer.min.js'></script> <script type="text/javascript" src="/static/js/global.min.js?5.5.53"></script> <!-- Matomo --> <script> var _paq = window._paq = window._paq || []; /* tracker methods like "setCustomDimension" should be called before "trackPageView" */ _paq.push(['trackPageView']); _paq.push(['enableLinkTracking']); (function() { var u="https://tongji.php.cn/"; _paq.push(['setTrackerUrl', u+'matomo.php']); _paq.push(['setSiteId', '9']); var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0]; g.async=true; g.src=u+'matomo.js'; s.parentNode.insertBefore(g,s); })(); </script> <!-- End Matomo Code --> </body> </html>