FTL テンプレート (FreeMaker ツール) で画像を表示できません。画像は Web コンテンツから読み込んでいますが、アプリ リソースから読み込めません。私のアプリでは、Vaadin、Spring Framework、および FreeMaker を使用しています。この問題を解決するにはどうすればよいですか? 返信ありがとうございます。
login.ftl: http://pastebin.com/N1VX30Zr 1
サーブレット-context.xml: http://pastebin.com/1SFSwmJT 1
web.xml: http://pastebin.com/NtZD5zSY 1
LoginController.java:
package pl.controlprocess.flota.web;
import com.vaadin.server.ThemeResource;
import java.io.Serializable;
import javax.servlet.http.HttpServletRequest;
import org.springframework.stereotype.Controller;
import org.springframework.ui.ModelMap;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
@Controller
@RequestMapping("/")
public class LoginController implements Serializable {
private static final long serialVersionUID = 1L;
@RequestMapping(value = "/", method = RequestMethod.GET)
public String login(HttpServletRequest request, @RequestParam(value = "error", defaultValue = "false", required = false)Boolean isError, ModelMap model)
{
if (isError)
{
model.put("isError", isError);
}
model.put("app_ctx", request.getContextPath());
return "login";
}