I have a project which has some docs and i am trying to display docs on JSP Page, for displaying docs i am using this code
for(int i =0;i<filesdisplay;i++)
{
out.write(<a href="/docs/projectname/eventtype/filenames[i]"> filenames[i] </a>
;
}
I get 2 errors
1.illegal start of expression
2. ')' expected
But if try to write the out statement like this below
out.write("<a href='/docs/projectname/eventtype/filenames[i]'> filenames[i] </a>");
i get output as filenames[i], instead of a filename eg a.doc, b.ppt.