guest ::
login
SSTP5
Search
Submit jednotlivé TEIP5
Submit hromadně nahrané TEIP5
Personalize
Your alerts
Your baskets
Your searches
Help
Administration
Konfigurace WebSubmit
Home
>
Admin Area
> Edit WebSubmit Checking Function
Edit WebSubmit Checking Function
Main Menu
0.
Show all
1.
Available Document Types
2.
Add New Document Type
3.
Remove Document Type
4.
Available Actions
5.
Available Checks
6.
Available Elements
7.
Available Functions
8.
Organise Main Page
9.
Guide
Enter Action Details:
Check Name:
DatCheckNew
Check Description:
function DatCheckNew(txt) { var res=1; if (txt.length != 10){res=0;} if (txt.indexOf("/") != 2){res=0;} if (txt.lastIndexOf("/") != 5){res=0;} tmp=parseInt(txt.substring(0,2),10); if ((tmp > 31)||(tmp < 1)||(isNaN(tmp))){res=0;} tmp=parseInt(txt.substring(3,5),10); if ((tmp > 12)||(tmp < 1)||(isNaN(tmp))){res=0;} tmp=parseInt(txt.substring(6,10),10); if ((tmp < 1)||(isNaN(tmp))){res=0;} if (txt.length == 0){res=1;} if (res == 0){ alert("Please enter a correct Date \012Format: dd/mm/yyyy"); return 0; } return 1; }