Get the App
SLTechnology News&Howtos  ›  Development  › 

How to use js to print a simple form

Shulou Source: shulou.com Published: 2022-06-02 06:47:08 10月02日 Update

This article shows you how to use js to achieve a simple print form, the content is concise and easy to understand, can definitely brighten your eyes, through the detailed introduction of this article, I hope you can get something.

For everyone to share the js to achieve the specific code to print the form, for your reference, the specific content is as follows

The effect is as follows:

The code is as follows:

Print a form

Var data= [

{id:1001,icon: "img/1.png", name: "Catering 0", num:1,price:10}

{id:1002,icon: "img/2.png", name: "Catering 1", num:1,price:20}

{id:1003,icon: "img/3.png", name: "Catering 2", num:1,price:30}

{id:1004,icon: "img/4.png", name: "Catering 3", num:1,price:40}

{id:1005,icon: "img/5.png", name: "Catering 4", num:1,price:50}

{id:1006,icon: "img/6.png", name: "Catering 5", num:1,price:60}

{id:1007,icon: "img/7.png", name: "Catering 6", num:1,price:70}

{id:1008,icon: "img/8.png", name: "Catering 7", num:1,price:80}

{id:1009,icon: "img/9.png", name: "Catering 8", num:1,price:90}

{id:1010,icon: "img/10.png", name: "Catering 9", num:1,price:100}]

Var table= ""

/ / the format in which the first bit of the string is # color

For (var iTuno Bandi)

Tags: Catering forms content code skills knowledge concise concise characters strings that is effects articles more formats articles industries information channels channels Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno macOS Shulou Technology Shulou Tech Info vpn Xiaomi