Maybe the compiler is interpreting the text as the code tags do: “empid” is after the second quote and therefore isn't part of the String literal. What happens if you escape the quotes around “empid”? Otherwise, don't know. Somebody else will know.
You're trying to use " for two different things - it's marking the boundaries of the href attribute value, and it's part of that value, as part of the Java code string literal "empId". Aside from escaping those as Campbell suggested, try changing the outer quotes to be single quotes:
HTML lets you choose between " and ' for precisely this reason - to avoid a clash with other uses of the characters.
Bear Bibeault wrote:Why are you using scriptlets versus the JSTL/EL?
Scriptlets are sooo last millenium!
Some people, when well-known sources tell them that fire will burn them, don't put their hands in the fire.
Some people, being skeptical, will put their hands in the fire, get burned, and learn not to put their hands in the fire.
And some people, believing that they know better than well-known sources, will claim it's a lie, put their hands in the fire, and continue to scream it's a lie even as their hands burn down to charred stumps.