模板配置

 

 

import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;

@Controller
public class ViewController {
    @RequestMapping("/page")
    public String getPage(Model model){
        model.addAttribute ("name","哈哈哈");
        return "index";
    }
}

 

hhhhhhhhhh ${name}
相關文章
相關標籤/搜索