Excuse me, the structure and style of the web page remain unchanged, and the content of the web page changes according to the different goods. How to achieve it with JS?

is like a shopping page in a shopping website, the structure and style of the shopping page are fixed, but the content of this page is determined according to the items before clicking on this page, because it is impossible for every product page to be rewritten, so the utilization rate is too low, may I ask how to achieve it with JS? Can you give me an idea? Thank you!

the following figure shows the shopping pages for two different goods, which are different, but the structure and style of the shopping page are roughly the same.

Mar.14,2021

this kind of page is sure that different products look the same, so when the last page jumps to this page, pass an id of the product. This page obtains the product details according to the id passed in, and displays


this must be when you request the API to obtain the product details, and there will be a field on the interface that tells you what style the current product will be displayed in. Can't you just quote the corresponding css?

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1ead015-46e61.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1ead015-46e61.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?