Moderators: gerski, enjay, williamconley, Op3r, Staydog, gardo, mflorell, MJCoate, mcargile, Kumba, Michael_N
<script type="text/javascript">
var qsParm = new Array();
function qs() {
var query = window.location.search.substring(1);
var parms = query.split('&');
for (var i=0; i<parms.length; i++) {
var pos = parms[i].indexOf('=');
if (pos > 0) {
var key = parms[i].substring(0,pos);
var val = parms[i].substring(pos+1);
qsParm[key] = val;
}
}
}
qsParm['uid'] = null;
qsParm['name'] = null;
qsParm['customer'] = null;
qsParm['new'] = null;
qs();
function ShowDataSetup(uid){
var datawin=dhtmlwindow.open("datawin", "iframe", "data.php?name="+qsParm['customer']+"&uid="+uid, "Data", "width=825px,height=315px,resize=1,scrolling=1,center=1", "recal")
}
function ShowCallerIDSetup(name,uid){
var calleridwin=dhtmlwindow.open("calleridwin", "iframe", "callerid.php?name="+name+"&uid="+uid, "Caller ID's", "width=525px,height=250px,resize=1,scrolling=1,center=1", "recal")
}
function ShowAudioSetup(){
var audiowin=dhtmlwindow.open("audiowin", "iframe", "audios.php?name="+qsParm['customer']+"&new="+qsParm['new']+"&uid="+qsParm['uid']+"&customer="+qsParm['customer'], "Audio Files", "width=525px,height=350px,resize=1,scrolling=1,center=1", "recal")
}
function ShowStateConfig(schedule){
var statewin=dhtmlwindow.open("statewin", "iframe", "timezoneconfig.php?schedule="+qsParm['schedule'], "Time Zone / State Configuration", "width=700x,height=450px,resize=1,scrolling=1,center=1", "recal")
}
function keychange(thekey,thevalue) {
//0,this.options[this.selectedIndex].value
if (thevalue == 0) {
document.getElementById("sKey"+thekey).style.display = "none";
document.getElementById("tKey"+thekey).style.display = "none";
}
if (thevalue == 1) {
document.getElementById("sKey"+thekey).style.display = "";
document.getElementById("tKey"+thekey).style.display = "none";
}
if (thevalue == 2) {
document.getElementById("sKey"+thekey).style.display = "";
document.getElementById("tKey"+thekey).style.display = "none";
}
if (thevalue == 3) {
document.getElementById("sKey"+thekey).style.display = "none";
document.getElementById("tKey"+thekey).style.display = "";
}
if (thevalue == 4) {
document.getElementById("sKey"+thekey).style.display = "none";
document.getElementById("tKey"+thekey).style.display = "none";
}
if (thevalue == 5) {
document.getElementById("sKey"+thekey).style.display = "none";
document.getElementById("tKey"+thekey).style.display = "";
}
if (thevalue == 6) {
document.getElementById("sKey"+thekey).style.display = "";
document.getElementById("tKey"+thekey).style.display = "none";
}
}
</script>
<script type="text/javascript">
var qsParm = new Array();
var $KeepUpdating;
function qs() {
var query = window.location.search.substring(1);
var parms = query.split('&');
for (var i=0; i<parms.length; i++) {
var pos = parms[i].indexOf('=');
if (pos > 0) {
var key = parms[i].substring(0,pos);
var val = parms[i].substring(pos+1);
qsParm[key] = val;
}
}
}
qsParm['uid'] = null;
qsParm['name'] = null;
qsParm['customer'] = null;
qs();
if (qsParm['uid'] < 0){
qsParm['uid'] = 1;
}
function setSelectListToValue(value, selectId){
var i, si, v, args=setSelectListToValue.arguments;
if ((obj=document.getElementById(args[1])) != null){
v = args[0];
for(i=0; i<obj.length; i++){
if(obj.options[i].value == v){
si = i;
}
}
obj.selectedIndex = si;
}
}
function createHTTPrequest()
{
var xmlHttp;
try
{
xmlHttp=new XMLHttpRequest();
}
catch (e)
{
try
{
xmlHttp=new ActiveXObject("Msxml2.XMLHTTP");
}
catch (e)
{
try
{
xmlHttp=new ActiveXObject("Microsoft.XMLHTTP");
}
catch (e)
{
alert("Your browser is old and does not have AJAX support!");
return false;
}
}
}
return (xmlHttp);
}
function updateAudios(){
var getAudios = createHTTPrequest();
getAudios.onreadystatechange=function()
{
if(getAudios.readyState==4)
{
if (getAudios.responseText != null)
{ var Audios = getAudios.responseText.split(",");
try{
for (i=document.getElementById("sLive").length; i<Audios.length; i++){
document.getElementById("sKey0").options[i] = new Option(Audios[i],Audios[i]);
document.getElementById("sKey1").options[i] = new Option(Audios[i],Audios[i]);
document.getElementById("sKey2").options[i] = new Option(Audios[i],Audios[i]);
document.getElementById("sKey3").options[i] = new Option(Audios[i],Audios[i]);
document.getElementById("sKey4").options[i] = new Option(Audios[i],Audios[i]);
document.getElementById("sKey5").options[i] = new Option(Audios[i],Audios[i]);
document.getElementById("sKey6").options[i] = new Option(Audios[i],Audios[i]);
document.getElementById("sKey7").options[i] = new Option(Audios[i],Audios[i]);
document.getElementById("sKey8").options[i] = new Option(Audios[i],Audios[i]);
document.getElementById("sKey9").options[i] = new Option(Audios[i],Audios[i]);
document.getElementById("sKey10").options[i] = new Option(Audios[i],Audios[i]);
document.getElementById("sKey11").options[i] = new Option(Audios[i],Audios[i]);
document.getElementById("sAns").options[i] = new Option(Audios[i],Audios[i]);
document.getElementById("sLive").options[i] = new Option(Audios[i],Audios[i]);
}
updateActions();
}
catch (e)
{
}
}
}
}
if (qsParm['new']==1){
getAudios.open("GET","getAudios.php?use=1&uid="+qsParm['uid'],true);
} else {
getAudios.open("GET","getAudios.php?use=0&uid="+qsParm['customer'],true);
}
getAudios.setRequestHeader("Content-Type","text/xml");
getAudios.send(null);
}
function updateActions(){
setSelectListToValue(document.getElementById("h_Ans").value,"sAns");
setSelectListToValue(document.getElementById("h_Live").value,"sLive");
for (var i = 0; i < 12; i++){
document.getElementById("s_type_"+i).selectedIndex = document.getElementById("h_Action"+i).value;
keychange(i,document.getElementById("h_Action"+i).value);
document.getElementById("tKey"+i).value = document.getElementById("h_Value"+i).value
setSelectListToValue(document.getElementById("h_Value"+i).value,"sKey"+i);
}
}
function clearThings() {
document.getElementById("sKey0").style.display = "none";
document.getElementById("tKey0").style.display = "none";
document.getElementById("sKey1").style.display = "none";
document.getElementById("tKey1").style.display = "none";
document.getElementById("sKey2").style.display = "none";
document.getElementById("tKey2").style.display = "none";
document.getElementById("sKey3").style.display = "none";
document.getElementById("tKey3").style.display = "none";
document.getElementById("sKey4").style.display = "none";
document.getElementById("tKey4").style.display = "none";
document.getElementById("sKey5").style.display = "none";
document.getElementById("tKey5").style.display = "none";
document.getElementById("sKey6").style.display = "none";
document.getElementById("tKey6").style.display = "none";
document.getElementById("sKey7").style.display = "none";
document.getElementById("tKey7").style.display = "none";
document.getElementById("sKey8").style.display = "none";
document.getElementById("tKey8").style.display = "none";
document.getElementById("sKey9").style.display = "none";
document.getElementById("tKey9").style.display = "none";
document.getElementById("sKey10").style.display = "none";
document.getElementById("tKey10").style.display = "none";
document.getElementById("sKey11").style.display = "none";
document.getElementById("tKey11").style.display = "none";
}
function AddData(customer, listuid){
var getStats = createHTTPrequest();
getStats.onreadystatechange=function() {
if(getStats.readyState==4) {
if (getStats.responseText != null) {
var Stats = getStats.responseText;
try {
$KeepUpdating = true;
} catch (e) {
alert(Stats);
}
}
}
}
updateAvailableLists(listuid);
$KeepUpdating = false;
//getStats.open("GET","getAddDataToCampaign.php?listuid="+listuid+"&campaign="+qsParm['schedule']+"&uid="+qsParm['uid']+"&customer="+qsParm['customer'],true);
getStats.open("GET","getAddDataToCampaign.php?listuid="+listuid+"&campaign="+qsParm['schedule']+"&uid="+qsParm['uid']+"&customer="+customer,true);
getStats.setRequestHeader("Content-Type","text/xml");
getStats.send(null);
}
function RemoveData(customer, listuid){
var getStats = createHTTPrequest();
getStats.onreadystatechange=function() {
if(getStats.readyState==4) {
if (getStats.responseText != null) {
var Stats = getStats.responseText;
try {
$KeepUpdating = true;
} catch (e) {
alert(Stats);
}
}
}
}
updateAvailableLists(listuid);
$KeepUpdating = false;
//getStats.open("GET","getDelDataFromCampaign.php?listuid="+listuid+"&campaign="+qsParm['schedule']+"&uid="+qsParm['uid']+"&customer="+qsParm['customer'],true);
getStats.open("GET","getDelDataFromCampaign.php?listuid="+listuid+"&campaign="+qsParm['schedule']+"&uid="+qsParm['uid']+"&customer="+customer,true);
getStats.setRequestHeader("Content-Type","text/xml");
getStats.send(null);
}
function updateAvailableLists(listuid){
var getStats = createHTTPrequest();
getStats.onreadystatechange=function()
{
if(getStats.readyState==4)
{
if (getStats.responseText != null)
{ var Stats = getStats.responseText;
try{
document.getElementById("available_lists").innerHTML = getStats.responseText;
}
catch (e)
{
}
}
setTimeout("updateActiveLists()", 1000);
}
}
if (qsParm['new']==0){
if ($KeepUpdating){
getStats.open("GET","getAvailableLists.php?listuid="+listuid+"&campaign="+qsParm['schedule']+"&uid="+qsParm['uid']+"&customer="+qsParm['customer'],true);
getStats.setRequestHeader("Content-Type","text/xml");
getStats.send(null);
} else {
setTimeout("updateActiveLists()", 1000);
}
}
}
function updateActiveLists(){
var getStats = createHTTPrequest();
getStats.onreadystatechange=function()
{
if(getStats.readyState==4)
{
if (getStats.responseText != null)
{ var Stats = getStats.responseText;
try{
document.getElementById("active_lists").innerHTML = getStats.responseText;
}
catch (e)
{
}
}
setTimeout("updateAvailableLists()", 1000);
}
}
if (qsParm['new']==0){
getStats.open("GET","getActiveLists.php?campaign="+qsParm['schedule']+"&uid="+qsParm['uid']+"&customer="+qsParm['customer'],true);
getStats.setRequestHeader("Content-Type","text/xml");
getStats.send(null);
}
}
updateAvailableLists();
Users browsing this forum: Google [Bot], Majestic-12 [Bot] and 69 guests