var debug_return=0;       function GetCodeDir()  {   return "booking/"; }      qwer.prototype.GetBookingList=qwer_GetBookingList; qwer.prototype.SendBookingRequest=qwer_SendBookingRequest;             qwer.prototype.serv_off=qwer_serv_off;         function qwer_GetBookingList()  {      this.request='action_request=get_booking_list';  send_request(this); }    function qwer_SendBookingRequest(firstname, lastname, address1, address2, address3, city,  county,  country, postcode,phone1, phone2, email, comments,  start, end)  {    ar=new Array();   ar.push('action_request');   ar.push('add_booking_request');   ar.push('firstname');   ar.push(firstname);   ar.push('lastname');    ar.push(lastname);    ar.push('address1');    ar.push(address1);    ar.push('address2');    ar.push(address2);    ar.push('address3');    ar.push(address3);    ar.push('city');    ar.push(city);    ar.push('county');    ar.push(county);    ar.push('country');    ar.push(country);    ar.push('postcode');    ar.push(postcode);    ar.push('phone1');    ar.push(phone1);    ar.push('phone2');    ar.push(phone2);    ar.push('email');    ar.push(email);    ar.push('comments');    ar.push(comments);    ar.push('start');    ar.push(start);    ar.push('end');    ar.push(end);    this.rar(ar);   send_request(this); }              function qwer_serv_off(str)  {    if (debug_return)   alert(str);      this.ParseResponse(str);    for (var i=0;i < this.rty.length;i++)   {            switch (this.rty[i].action)          {     case 'current_date':      set_this_day(this.rty[i].day, this.rty[i].month, this.rty[i].year);     initialise_calendars();       break;    case 'booking':         var date_strS=new Array();        date_strE=new Array();        var dateStr=new String(this.rty[i].s);        date_strS=dateStr.split("-");        dateStr=new String(this.rty[i].e);        date_strE=dateStr.split("-");        mkjh[mkjh.length]=new BookingObject(this.rty[i].customer_id, this.rty[i].booking_id, date_strS[2], date_strS[1], date_strS[0], date_strE[2], date_strE[1], date_strE[0]);        break;             case 'customer':      var _cust=new customer_DBObject();     _cust.customer_id=this.rty[i].customer_id;     _cust.firstname=this.rty[i].firstname;     _cust.lastname=this.rty[i].lastname;     _cust.address1=this.rty[i].address1;     _cust.address2=this.rty[i].address2;     _cust.address3=this.rty[i].address3;     _cust.city=this.rty[i].city;     _cust.postcode=this.rty[i].postcode;     _cust.county=this.rty[i].county;     _cust.country=this.rty[i].country;     _cust.phone1=this.rty[i].phone1;     _cust.phone2=this.rty[i].phone2;     _cust.email=this.rty[i].email;     _cust.comments=this.rty[i].comments;     _cust.booking_id=this.rty[i].booking_id;     this.car.push(_cust);          break;               case 'confirmed_list_complete':       x_b();      UpdateCalendars();     this.tic();                   break;              case 'booking_list_complete':      x_b();      UpdateCalendars();     break;      case 'request_ack':      DisplayRequestAck(this.rty[i].message_string);     break;      case 'cust_ready':      var i;     for (i=0;i < Customers.length;i++)      {       this.car.push(Customers[i]);     }      Customers=null;     this.tic();     break;      case 'confirmed_cust':         break;      case 'display_message':       alert(this.rty[i].message_string);    break;      case 'null':     break;           }   }  }    