payment2

// <![CDATA[
function sumujkase(){
var suma=0;

var PPL=document.Payment.particip_payment;
var VPPL=parseInt(PPL.options[PPL.selectedIndex].value);
suma+= VPPL;

var APPL=document.Payment.accomp_payment;
var VAPPL=parseInt(APPL.options[APPL.selectedIndex].value);
suma+= VAPPL;

var PuPL=document.Payment.publisher_payment;
var VPuPL=parseInt(PuPL.options[PuPL.selectedIndex].value);
suma+= VPuPL;

return suma*100;
}
function vimie(src){
var regex = /^[A-ZĄĆĘŁŃÓŚŹŻa-ząćęłńóśźż\s]{1}[a-ząćęłńóśźż\s]{2,}$/;
return regex.test(src);
}

function vnazwisko(src){
var regex = /^[A-ZĄĆĘŁŃÓŚŹŻa-ząćęłńóśźż\s]{1}[a-ząćęłńóśźż\s]{2,}$/;
return regex.test(src);
}

function foreCard(name, surname, ordernumber, amount, hash){
var myWindow = window.open("","Window");

var form = myWindow.document.body.innerHTML='

We are sorry, but Your browser does not support JavaScript.
';
myWindow.document.getElementById(’payment_form').submit();
}
Date.prototype.getDOY = function() {
var onejan = new Date(this.getFullYear(),0,1);
return Math.ceil((this – onejan) / 86400000);
}
function loadNumber(){

var str = „”;

var currentTime = new Date()
var hours = currentTime.getHours()
var minutes = currentTime.getMinutes()
var seconds = currentTime.getSeconds()
var miliseconds = currentTime.getMilliseconds()

if (minutes < 10) {
minutes = "0" + minutes
}
if (seconds < 10) {
seconds = "0" + seconds
}
var str= String(currentTime.getDOY());
var res=str.substr(0,3);
var milisstr = String(miliseconds).substr(0,1);
str = res+hours+minutes+seconds;
return str;
}
function waliduj (){
var flaga=new Array(2);

if (vimie(document.getElementById('first_name_payment').value) ) {
document.getElementById('nameerr').innerHTML='';
flaga[0]=0;
} else {
document.getElementById('nameerr').innerHTML='error';
flaga[0]=1;}

if (vnazwisko(document.getElementById(’family_name_payment').value) ) {
document.getElementById(’nazwerr').innerHTML=”;
flaga[1]=0;
} else {
document.getElementById(’nazwerr').innerHTML='error';
flaga[1]=1; }

return j= flaga[1]+flaga[0];

}
function wyslij() {

document.getElementById(’NAME').value=document.getElementById(’first_name_payment').value;
document.getElementById(’SURNAME').value=document.getElementById(’family_name_payment').value;
document.getElementById(’ORDERNUMBER').value=loadNumber();

var MERCHANTID = document.getElementById(’MERCHANTID').value;
var ORDERNUMBER = document.getElementById(’ORDERNUMBER').value;
var CURRENCY = document.getElementById(’CURRENCY').value;
var ORDERDESCRIPTION = document.getElementById(’ORDERDESCRIPTION').value;
var NAME = document.getElementById(’NAME').value;
var SURNAME = document.getElementById(’SURNAME').value;
var AUTODEPOSIT = parseInt(document.getElementById(’AUTODEPOSIT').value);
var PAYMENTTYPE = document.getElementById(’PAYMENTTYPE').value;
var LINKFAIL = document.getElementById(’LINKFAIL').value;
var LINKOK = document.getElementById(’LINKOK').value;
var EXPIRYTIME = document.getElementById(’EXPIRYTIME').value;
var pwd = „Cairt2Onk”
var AMOUNT = parseInt(sumujkase());
document.getElementById(’AMOUNT').value=AMOUNT;
var toHash = MERCHANTID+ORDERNUMBER+AMOUNT+CURRENCY+ORDERDESCRIPTION+NAME+SURNAME+AUTODEPOSIT+PAYMENTTYPE+LINKFAIL+LINKOK+EXPIRYTIME+pwd;

var hash = CryptoJS.MD5(toHash);
document.getElementById(’HASH').value=hash;

var w=waliduj();
if (w

Credit card payment

Admission: 120 euros
Student, doctoral student: 72 euros