ASP.NET - Autodetection of credit card using Js or text change event

Asked By Vimal Sharma
03-Feb-12 01:54 AM
I have a credit card page in which i am automtically detect card. Now i have two methods one by using javascipt and use the keyup event which checks each word and give the result when condition fulfills and one is by text change event which check the whole regexp at time of text change . So which one is better . Ideas are welcome
  Anantha replied to Vimal Sharma
03-Feb-12 02:03 AM
While js gives flexibility, some users and admins will disable js, javascript etc. So it is better to use other means. Unless it is for an internal site where you can get the DBA to allow your script to run.

JS - PROS.
Flexibility and cab customised
JS - CONS
Can be disabled.

REGEXP - PROS.
Cant be disabled.
REGEXP - CONS
Regexp is slightly more difficult to use since the arguments and combinations are not exactly the same as DIR etc but the codes are. 

OK


  Vimal Sharma replied to Anantha
03-Feb-12 02:29 AM
but for regexp event i used text changes event will it be good
Create New Account
help
search-Full / / New Property if (RadioButtonList1.SelectedIndex = = 1 && DropDownList3_category.SelectedItem.Text = = "All" && DropDownList1_categorytype.SelectedItem.Text = = "All" && DropDownList_state.SelectedItem.Text = = "All" && DropDownList_city.SelectedItem.Text = = "All" && CheckBoxList1.SelectedIndex = = -1) { cmd = new SqlCommand ( "select a.img, a.prop_name, b.state_name, c ownership_id = d.prop_ownership and prop_type = 'New Property'" , con); } else if (RadioButtonList1.SelectedIndex = = 1 && DropDownList3_category.SelectedItem.Text = = "All" && DropDownList1_categorytype.SelectedItem.Text = = "All" && DropDownList_state.SelectedItem.Text = = "All" && DropDownList_city.SelectedItem.Text = = "All" && CheckBoxList1.Items[0].Selected = = true && CheckBoxList1.Items[1].Selected = = false && CheckBoxList1.Items[2].Selected
Net hi friends Any one send frequently asked Important questions in C# .Net, ADO .Net, Asp .Net and Sql Server. . . . . . . . tx in Advance. . . . . . Hi, Find this. . (B)What is an IL? (B A) What is scavenging? (B) What are different types of caching using cache object of ASP.NET? (B) How can you cache different version of same page using ASP.NET cache object? (A) How will implement Page Fragment Caching? (B) Can you compare ASP.NET sessions with classic ASP? (B) Which are the various modes of storing ASP.NET session
in Sql server as var_name int How do you separate business logic while creating an ASP.NET application? There are two level of asp.net debugging 1. Page level debugging For this we have to edit the page level debugging The control itself will take care of the date display How can you deploy an asp.net application ? You can deploy an ASP.NET Web application using any one of the following three deployment options. a) Deployment using VS
Migration from ASP to ASP.net How to convert ASP site to ASP.NET site using C# http: / / www.asp.net / downloads / archived-v11 / migration-assistants / asp-to-aspnet hi, ASP.NET framework is very much different from unstrucured ASP and there is no correct way to
Tracing in ASP.NET? hi all, what is tracing? how to achieve tracing in asp.net? different ways of doing tracing? thanks and regards Aman Khan hi. . Tracing in ASP.NET 2.0 Tracing is a way to monitor the execution of your ASP.NET application. You can record exception details and program flow in a way that doesn't