Location: PHPKode > projects > ADbNewsSender > ADbNewsSender 2.1.0/protected/admin/specialheaders/import.php.inc
<?php
//Copyright (c) Florian Grannemann
//Last change in version: 2.1 Alpha 4
/*
    ******************************************************************************
    ADbNewsSender 2

    Copyright (C) 2010 Florian Grannemann (hide@address.com)
    Website: http://adbnewssender.sf.net



    This program is free software; you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
    the Free Software Foundation; either version 3 of the License, or
    any later version.

    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License			
    along with this program.  If not, see http://www.gnu.org/licenses/
    ******************************************************************************
*/

	//Defining some java script functions to ease the switch between web and ftp upload
	print "<script type=\"text/javascript\">\n";
	print "<!--\n\n";

	
	print "function UploadMSG(MSG_importing, MSG_Uploading) {\n";
	print "
		document.getElementById(\"submit\").disabled=true;

		if(document.getElementById(\"web\").selected==true)
		{
		    document.getElementById(\"submit\").value=MSG_Uploading;
		}
		else
		{
		    document.getElementById(\"submit\").value=MSG_importing;
		}
		";

	print "}\n \n";

	print "function switch_file_select() {\n";
	print "
		if(document.getElementById(\"web\").selected==true)
		{
		    document.getElementById(\"ftpuploadform\").style.visibility=\"hidden\";
		    document.getElementById(\"ftpuploadform\").disabled=true;
		    document.getElementById(\"refreshftpfiles\").style.visibility=\"hidden\";
		    document.getElementById(\"webuploadform\").style.visibility=\"visible\";
		    document.getElementById(\"webuploadform\").disabled=false;
		}
		else
		{
		    document.getElementById(\"webuploadform\").style.visibility=\"hidden\";
		    document.getElementById(\"webuploadform\").disabled=true;
		    document.getElementById(\"ftpuploadform\").style.visibility=\"visible\";
		    document.getElementById(\"ftpuploadform\").disabled=false;
		    document.getElementById(\"refreshftpfiles\").style.visibility=\"visible\";
		    
		}

		";

	print "}\n -->\n</script>";
    


?>
Return current item: ADbNewsSender