Q:

How do I convert this simple scriptlet to JSTL?

I have the following scriptlet that I'm trying to convert to JSTL
<%
String req = request.getParameter("loginfailed");    
if(req != null)
{
    if(req.equals("true"))
    {%>     
    <h4 id="loginerrormessage">Invalid email address or password.</h4>          
    <%}
}
%>

This scriptlet works just fine, but I'm trying to convert it to JSTL now which I am new to.  This is my best attempt at recreating the logic using JSTL.
<c:set var="req" value="${request.getParameter(\"loginfailed\")}"/>
<c:if test="${ req!=null }">
    <c:if test="${ req.equals(\"true\") }">
        <h4 id="loginerrormessage">Invalid email address or password.</h4>
    </c:if>
</c:if>

When I replace the scriptlet with the JSTL I have written above, nothing crashes but I no longer see the "Invalid email address or password." when I would have seen it using the scriptlet.  I'm not sure what I'm doing wrong here.  
Is it a scope issue?  I figured the default page scope was fine for the c:set. Could it have anything to do with the fact that I'm using escape quotes in the JSTL?

A:

just use
    <c:if test="${ param.loginfailed eq 'true' }">
        <h4 id="loginerrormessage">Invalid email address or password.</h4>
    </c:if>

here param is implicit JSP object which gives you access to request parameters.

