how read from an array, put link on it

how to read from an array, and then display each element on the website, put link to display another array's element below, finally use cookie to track the website. soorry, new to java, thanks a lot
[206 byte] By [mutulonga] at [2007-11-27 4:34:26]
# 1
Any help would be appreciated
mutulonga at 2007-7-12 9:44:22 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 2
A more clear and specific problem description would help.
BalusCa at 2007-7-12 9:44:22 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 3

Thanks for reply,

what i put above is like how to put link on

city 1

city 2

city 3

...,

what I did is like:

for(int i = 0; i < citys.size(); i+=5)

{

out.println("<a href =\"/lodu/EventServlet?city=" + citys.get(i) + "\">" + citys.get(i) + "</a>

");

out.flush();

//out.println(request.getParameter("city") + "

");

}

when i use request.getParameter("city") to get city, then i did sth like

/*if (request.getParameter("city").equals("City1"))

{

for(int j = 0; j < category.size(); j++)

out.println("<a href =\"/lodu/EventServlet?categorys=" + category.get(j) + "\">" + category.get(j) + "</a>

");

out.println(request.getParameter("categorys") + "

");

}

Its not working now, can anyone tell what i did wrong?

Also how to use cookie to track users clicks?

mutulonga at 2007-7-12 9:44:22 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...