function sendProduct() {

	var msisdn_pattern = /^48\d{9}$/;
	var msisdn = document.getElementById('msisdn').value;
	if (msisdn_pattern.test(msisdn)) {
		var product = document.getElementById('send_product').value;

		var url = "http://"+window.location.host+"/rozrywka_i_informacje/?np_id=sendProductAction.action&msisdn="
				+ msisdn + "&product=" + product;

		new Ajax.Request(url, {
			method : 'get',
			onSuccess : function(transport) {
			alertInfo('Wiadomo&#x015B;&#x0107; zosta&#x0142;a wys&#x0142;ana!');
			}
		});

	} else {
		alertInfo('Podano niepoprawny numer telefonu!');
	}
}

function sendType() {

	var msisdn_pattern = /^48\d{9}$/;
	var msisdn = document.getElementById('msisdn').value;
	if (msisdn_pattern.test(msisdn)) {
		var type = document.getElementById('url_type').value;
		var url = "http://www.bcms.plus.pl/sendProductAction.action?msisdn="
				+ msisdn + "&type=" + type;

		
		new Ajax.Request(url, {
			method : 'get',
			onSuccess : function(transport) {
				alertInfo('Wiadomo&#x015B;&#x0107; zosta&#x0142;a wys&#x0142;ana!');
			}
		
		});

	} else {
		alertInfo('Podano niepoprawny numer telefonu!');
	}
}

function alertInfo(msg) {
	Modalbox.show('<div class=\'alert-info\'><p>' + msg + '</p> <input type=\'button\' value=\'OK\' onclick=\'Modalbox.hide()\' /></div>', {title: "Plus.pl", width: 300}); return false;
}