(function (root, undefined) {

	var r_externalUrl = /^(ftp|http(s?)):\/\//i;

	Ext.apply(Ext.form.field.VTypes, {
		//  vtype validation function
		externalUrl: function(val, field) {
			return r_externalUrl.test(val);
		},

		// vtype Text property: The error text to display when the validation function returns false
		externalUrlText: ip2.i18n({
			da: "Ikke en ekstern addresse, eller du mangler http(s) eller ftp",
			en: "Not an external address or you are missing http(s) or ftp"
		}),

		// vtype Mask property: The keystroke filter mask
		externalUrlMask: /.*/i
	});
})(this);
