package beans;

import gonggao.GG;

import java.io.IOException;
import java.util.ArrayList;

import javax.servlet.jsp.JspWriter;
import javax.servlet.jsp.tagext.SimpleTagSupport;

import database.DBConn;

public class TagGG extends SimpleTagSupport {
	public void doTag()
	{
		JspWriter out = getJspContext().getOut();
		try {
			ArrayList a = new DBConn().selectGG();
			for(int i = 0; i<1; i++)
			{
				GG gg = (GG)a.get(i);
				out.print("<img src='images/dtxwan.gif'/>"+"&nbsp;&nbsp;&nbsp;<a href='showgg.do?id="+gg.getId()+"' target='_blank'>"+gg.getContent()+"</a>");
				
			}
			
				
			
			
		} catch (IOException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
	}

}
