Express renders the same template for different routes

router.get("/",function (req,res,next) {
    res.render("index");
})

router.get("/a",function (req,res,next) {
    // axios 
})

the first route is a path request to render index.html in index.html, and request / a to node after html gets some value. Request the server to get the data in / a, so how to render the data to index.html.

May.19,2022

template engine ejs

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-1b3b927-2c2ba.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-1b3b927-2c2ba.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?