PDA

View Full Version : how to write xml code to get database connection



janunme
06-09-2007, 08:45 AM
hi to all,

can any one help me

i am writing my xml code in web.xml file as follows but it is not getting connectd



<servlet>
<servlet-name>Conn.jsp</servlet-name>
<jsp-file>Conn.jsp</jsp-file>
<init-param>
<param-name>unmae</param-name>
<param-value>root</param-value>
</init-param>

<init-param>
<param-name>pwd</param-name>
<param-value>root</param-value>
</init-param>

<init-param>
<param-name>drvcls</param-name>
<param-value>com.mysql.jdbc.Driver</param-value>
</init-param>

<init-param>
<param-name>url</param-name>
<param-value>jdbc:mysql://localhost/tandt</param-value>
</init-param>
</servlet>

<servlet-mapping>
<servlet-name>Conn.jsp</servlet-name>
<url-pattern>/Conn.jsp</url-pattern>
</servlet-mapping>



where i am doing mistake i am waiting for reply