进入官网下载4.0

将lib目录拷贝到项目中:

新建2个文件一个
smarty.php:
- <?php
- include_once("smarty/Smarty.class.php");
- $smarty = new Smarty();
- $hello = "Hello World";
- $smarty->assign("hello", $hello);
- $smarty->display("smarty.html");
- ?>
smart.html:
- <!DOCTYPE html>
- <html lang="en">
- <head>
- <meta charset="UTF-8">
- <title>Title</title>
- </head>
- <body>
- {$hello}
- </body>
- </html>

![[手游] 三网H5小游戏【少年仙路】WIN系服务端+Linux手工服务端+详细搭建教程](https://cdn.jxasp.com:9143/image/20260615/136BC33AA47EB0D84E878835A8B38FDB.png)

















