Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [mvc-dev] Static Content with MVC

Hi Victor,

Try this in your main.xhtml file:

<link rel="stylesheet" type="text/css" href="${mvc.contextPath}/assets/css/main.css" />

Ivar

On Fri, Jul 3, 2020 at 3:52 AM Victor Perticarrari <victor.perticarrari@xxxxxxxxx> wrote:

I'm trying to create an example using MVC 1.0.


It is working for all views, but not for static content. I have a simple Hello World with the error here: https://github.com/vepo/java-mvc-hello-world


If I execute it, I get 404 on /assets/css/main.css


Is something missing?


Thanks,

--
Victor Osório
_______________________________________________
mvc-dev mailing list
mvc-dev@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/mvc-dev


--

Ivar Grimstad

Jakarta EE Developer Advocate | Eclipse Foundation, Inc.

Community. Code. Collaboration. 

Join us at our virtual event:
EclipseCon 2020 - October 20-22


Back to the top