ash sangy

Greenhorn
+ Follow
since Jul 09, 2011
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
In last 30 days
0
Forums and Threads

Recent posts by ash sangy

plase help is there any problem with my validation.xnl file ,i have using struts1.3.8


Srruts-config.xnl


<?xml version="1.0" encoding="UTF-8" ?>

<!DOCTYPE struts-config PUBLIC
"-//Apache Software Foundation//DTD Struts Configuration 1.3//EN"
"http://jakarta.apache.org/struts/dtds/struts-config_1_3.dtd">


<struts-config>
<form-beans>
<form-bean name="loginform" type="com.myapp.struts.LoginForm"/>
<form-bean name="regform" type="com.myapp.struts.RegistrationForm"/>
</form-beans>

<global-exceptions>

</global-exceptions>

<global-forwards>
<forward name="welcome" path="/Welcome.do"/>
</global-forwards>

<action-mappings>
<action name="loginform" path="/login" type="com.myapp.struts.LoginAction" validate="true" input="/login.jsp">
<forward name="home" path="/home.jsp"/>
</action>
<action name="regform" path="/reg" type="com.myapp.struts.RegistrationAction" validate="true" input="/home.jsp">
<forward name="success" path="/success.jsp"/>
<forward name="failure" path="/failure.jsp"/>
</action>

</action-mappings>


<message-resources parameter="com/myapp/struts/ApplicationResource"/>

<!-- ========================= Tiles plugin ===============================-->
<!--
This plugin initialize Tiles definition factory. This later can takes some
parameters explained here after. The plugin first read parameters from
web.xml, thenoverload them with parameters defined here. All parameters
are optional.
The plugin should be declared in each struts-config file.
- definitions-config: (optional)
Specify configuration file names. There can be several comma
separated file names (default: ?? )
- moduleAware: (optional - struts1.1)
Specify if the Tiles definition factory is module aware. If true
(default), there will be one factory for each Struts module.
If false, there will be one common factory for all module. In this
later case, it is still needed to declare one plugin per module.
The factory will be initialized with parameters found in the first
initialized plugin (generally the one associated with the default
module).
true : One factory per module. (default)
false : one single shared factory for all modules
- definitions-parser-validate: (optional)
Specify if xml parser should validate the Tiles configuration file.
true : validate. DTD should be specified in file header (default)
false : no validation

Paths found in Tiles definitions are relative to the main context.
-->

<!-- ========================= Validator plugin ================================= -->
<plug-in className="org.apache.struts.validator.ValidatorPlugIn">
<set-property property="pathnames" value="/WEB-INF/validator-rules.xml,/WEB-INF/validation.xml"/>
</plug-in>

</struts-config>

Validation.xml:


<?xml version="1.0" encoding="UTF-8" ?>

<!DOCTYPE form-validation PUBLIC
"-//Apache Software Foundation//DTD Commons Validator Rules Configuration 1.1.3//EN"
"http://jakarta.apache.org/commons/dtds/validator_1_1_3.dtd">

<form-validation>



<formset>

<!-- An example form -->
<form name="regform">
<field property="fname" depends="required">
<arg0 key="fname" resource="true"/>
</field>
<field property="lname" depends="required">
<arg0 key="lname" resource="true"/>

</field>
<field property="father" depends="required">
<arg0 key="father" resource="true"/>

</field>
<field property="g1" depends="required">
<arg0 key="gender" resource="true"/>

</field>
<field property="address" depends="required">
<arg0 key="address" resource="true" />

</field>
<field property="dob" depends="required,date">
<arg0 key="dob" resource="false" />
<var>
<var-name>datepatternstrict</var-name>
<var-value>dd-mm-yyyy</var-value>
</var>
</field>
<field property="phone" depends="required,mask">
<arg0 key="phone" resource="false"/>

<var>
<var-name>mask</var-name>
<var-value>^\d{2}-\d{10}*$</var-value>
</var>
</field>
<field property="pin" depends="required,mask">
<arg0 key="pin" resource="false"/>

<var>
<var-name>mask</var-name>
<var-value>^[0-9]$</var-value>
</var>
</field>
</form>

</formset>

<!-- An example formset for another locale
<formset language="fr">

<constant>
<constant-name>postalCode</constant-name>
<constant-value>^[0-9a-zA-Z]*$</constant-value>
</constant>

An example form
<form name="logonForm">
<field
property="username"
depends="required">
<arg key="logonForm.username"/>
</field>
<field
property="password"
depends="required,mask">
<arg key="logonForm.password"/>
<var>
<var-name>mask</var-name>
<var-value>^[0-9a-zA-Z]*$</var-value>
</var>
</field>
</form>

</formset>-->

</form-validation>


13 years ago
Hi All,

This is Ashok i need to develop an SMS application using struts (like way2sms) please any body help me
13 years ago
hi all,

i am trying to put exp in java so please help me how to configure log4j and CVS and ant, mavan in realtime project please help me
hi

i have a doubt in core java multithreading i have to invoke waited threads (assume 10 threads are waiting state) how can we cal only one particular waiting thread using notify()?
i need to develop an servlet application which consist a dynamically generated table in this table i have to give a hyperlink, when we click on that hyperlink that data must be in modifiable format ,how it is possible please help me
13 years ago