UK Postcode Validation

Regular expression for JavaScript var regPostcode = /^([a-zA-Z]){1}([0-9][0-9]|[0-9]|[a-zA-Z][0-9][a-zA-Z]|[a-zA-Z][0-9][0-9]|[a-zA-Z][0-9]){1}([ ])([0-9][a-zA-z][a-zA-z]){1}$/; var result = regPostcode.test(SearchTerm); if (!result) { alert(“Please enter valid postcode”); return false; } Regular expression for C# string regPostcode = “([a-zA-Z]){1}([0-9][0-9]|[0-9]|[a-zA-Z][0-9][a-zA-Z]|[a-zA-Z][0-9][0-9]|[a-zA-Z][0-9]){1}([ ])([0-9][a-zA-z][a-zA-z]){1}”; System.Text.RegularExpressions.Regex regx = new…

Read More

Telerik RadList Box Checkbox Items check all or uncheck all

Aspx page: I bound the lstLocations dynamically. So it look like as below. <telerik:RadListBox ID=”lstLocations” runat=”server” CheckBoxes=”true” Width=”520px” Height=”130px”> </telerik:RadListBox> // Select All checkbox buttons <asp:CheckBox CssClass=”CBFull” ID=”chkSelectAll” runat=”server” Text=”Select All” onclick=”javascript:return ToggleAllLocations(this);” /> // Add…

Read More

How to read RSS feed using Jquery

Click here download latest plugin Getting Started First include the jQuery and zRSSFeed libraries. <script src=”http://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js” type=”text/javascript”></script> <script src=”jquery.zrssfeed.min.js” type=”text/javascript”></script> Add a DIV tag where you wish the feed to display and give it an ID.…

Read More