eclipse - How to include properly a css file in jsp -


i tried :

<link type="text/css" rel="stylesheet" href="${pagecontext.request.contextpath}/css/style.css" /> 

http://i.imgur.com/orwdjgk.png

but css won't apply. :(

am missing obvious ?

edit :

here jsp :

<%@ page pageencoding="utf-8"%> <!doctype html> <html >   <head>     <meta charset="utf-8">     <title>log-in</title>     <link type="text/css" rel="stylesheet" href="${pagecontext.request.contextpath}/css/style.css" />   </head>    <body>      <div class="login-card">     <h1>log-in</h1><br>   <form>     <input type="text" name="user" placeholder="username">     <input type="password" name="pass" placeholder="password">     <input type="submit" name="login" class="login login-submit" value="login">   </form>    <div class="login-help">     <a href="#">register</a> • <a href="#">forgot password</a>   </div> </div>    </body> </html> 

try this:- <jsp:include page="style.css"/>

using include directive should trick.


Comments

Popular posts from this blog

sublimetext3 - what keyboard shortcut is to comment/uncomment for this script tag in sublime -

java - No use of nillable="0" in SOAP Webservice -

ubuntu - Laravel 5.2 quickstart guide gives Not Found Error -