⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 uploadflash.php

📁 学校网站源码http://您的网址/admin/admin_login.asp 默认登录用户:admin 默认登录密码:admin
💻 PHP
字号:
<?php


include( "../../config.inc.php" );
include( "../../includes/SysGlobal.php" );
include( "../language/".$aLan."_".$charset.".php" );
include( "../../includes/version.php" );
include( "../../includes/pro.php" );
include( "../func/adm.inc.php" );
include( "../func/common.inc.php" );
include( "../func/db.inc.php" );
needauth( 0 );
error_reporting( E_ERROR | E_WARNING | E_PARSE );
echo "<html>\r\n<head>\r\n<meta http-equiv=\"Content-Type\" content=\"text/html; charset=";
echo $charset;
echo "\">\r\n<link rel=stylesheet type=text/css href=style.css>\r\n<title>";
echo $strHtmlFlash;
echo "</title>\r\n\r\n\r\n";
echo "<s";
echo "cript>\r\nfunction chose_flash (){\r\n\tupload_flash.hiddenField.value = \"2\";\r\n\tupload_flash.flash_src.style.display = \"block\";\r\n\tupload_flash.nlFile.style.display = \"none\";\r\n\tvar res = showModalDialog('slibFlash.php', null, 'dialogWidth: 700px; dialogHeight: 420px; center: yes; resizable: no; scroll: no; status: no;');\r\n\tif (res) {\r\n\t\tres = res.split(\"*\");\r\n\t\tvar file_src = res[0];\r\n\t\tvar file_width =";
echo " res[1];\r\n\t\tvar file_height = res[2];\r\n\t\tupload_flash.flash_src.value = file_src;\r\n\t\tupload_flash.txtWidth.value = file_width;\r\n\t\tupload_flash.txtHeight.value = file_height;\r\n\t} else {\r\n\t\twindow.location = \"uploadflash.php\";\r\n\t}\r\n}\r\n\r\nfunction flash_upload () {\r\n\tupload_flash.hiddenField.value = \"1\";\r\n\tupload_flash.flash_src.style.display = \"none\";\r\n\tupload_flash.nlFile.style.display = \"block\";\r\n}";
echo "\r\n\r\nfunction flash_fill () {\r\n\tupload_flash.hiddenField.value = \"2\";\r\n\tupload_flash.flash_src.style.display = \"block\";\r\n\tupload_flash.nlFile.style.display = \"none\";\r\n}\r\n\r\nfunction check_form () {\r\n\tif (upload_flash.hiddenField.value == \"1\" || upload_flash.hiddenField.value == \"\") {\r\n\t\tif (upload_flash.nlFile.value == \"\") {\r\n\t\t\talert (\"";
echo $strHtmlFlashNotice1;
echo "\");\r\n\t\t\treturn false;\r\n\t\t}\r\n\t} else if (upload_flash.hiddenField.value == \"2\"){\r\n\t\tif (upload_flash.flash_src.value == \"\" || upload_flash.flash_src.value == \"http://\") {\r\n\t\talert (\"";
echo $strHtmlFlashNotice2;
echo "\");\r\n\t\treturn false;\r\n\t\t}\r\n\t\tif (upload_flash.txtWidth.value == \"\" || upload_flash.txtHeight.value == \"\" ) {\r\n\t\talert (\"";
echo $strHtmlFlashNotice3;
echo "\");\r\n\t\treturn false;\r\n\t\t}\r\n\r\n\t}\r\n\treturn true;\r\n}\r\n</script>\r\n</HEAD>\r\n";
$sAction = $_POST['sAction'];
$radiobutton = $_POST['radiobutton'];
if ( $sAction == $strConfirm )
{
	$txtname = $_POST['txtname'];
	$txtborder = $_POST['txtborder'];
	$txttitle = $_POST['txttitle'];
	$txtWidth = $_POST['txtWidth'];
	$WidthUnits = $_POST['WidthUnits'];
	$txtHeight = $_POST['txtHeight'];
	$HeightUnits = $_POST['HeightUnits'];
	$txthspace = $_POST['txthspace'];
	$txtvspace = $_POST['txtvspace'];
	$chkplay = $_POST['chkplay'];
	$chkmenu = $_POST['chkmenu'];
	$chkloop = $_POST['chkloop'];
	$hkdevicefont = $_POST['hkdevicefont'];
	$sltalign = $_POST['sltalign'];
	$tmpquality = $_POST['tmpquality'];
	$tmpscale = $_POST['tmpscale'];
	if ( $radiobutton == "upload" )
	{
		$img = $_FILES['nlFile'];
		if ( $img['size'] <= 0 )
		{
			echo "<script>alert ('".$strHtmlFlashNotice1."');\r\n\t\t\tself.location = 'uploadflash.php'</script>";
			exit( );
		}
		else if ( $img['type'] != "application/x-shockwave-flash" )
		{
			echo "<script>alert ('".$strHtmlFlashNotice4."');\r\n\t\t\tself.location = 'uploadflash.php'</script>";
			exit( );
		}
		$img_directory = "../../pic/swf/";
		$file_name = time( ).".swf";
		$flash_src = $img_directory.$file_name;
	}
	else
	{
		$flash_src = $_POST['flash_src'];
		if ( $txtWidth == "" || $txtHeight == "" )
		{
			popback( $strHtmlFlashNotice3, "uploadflash.php" );
		}
		if ( $flash_src == "" || $flash_src == "http://" )
		{
			popback( $strHtmlFlashNotice2, "uploadflash.php" );
		}
	}
	$size = @getimagesize( $img['tmp_name'] );
	if ( 0 < $size[0] )
	{
		$txtWidth = $size[0];
		$txtHeight = $size[1];
	}
	if ( !file_exists( $img_directory ) )
	{
		@mkdir( $img_directory, 511 );
	}
	copy( $img['tmp_name'], $flash_src );
	chmod( $file_path, 438 );
	echo "<script>\r\n\tfunction returnvar () {\r\n\t\twindow.returnValue = \"".str_replace( "../../", $SiteUrl, $flash_src )."\" + \"*\" + \"".$txtname."\" + \"*\" + \"".$txtborder."\" + \"*\" + \"".$txttitle."\" + \"*\"+ \"".$txtWidth."\" + \"*\" + \"".$WidthUnits."\" + \"*\" + \"".$txtHeight."\" + \"*\" + \"".$HeightUnits."\" + \"*\" + \"".$txthspace."\" + \"*\" + \"".$txtvspace."\" + \"*\" + \"".$chkplay."\" + \"*\" + \"".$chkmenu."\" + \"*\" + \"".$chkloop."\" + \"*\" + \"".$hkdevicefont."\" + \"*\"+ \"".$sltalign."\" + \"*\" + \"".$tmpquality."\" + \"*\" + \"".$tmpscale."\";\r\n\t\twindow.close();\r\n\t}\r\n\treturnvar ();\r\n</script>";
}
echo "<BODY leftMargin=0 topMargin=0 marginheight=\"0\" marginwidth=\"0\" class=\"bodybackground\">\r\n<TABLE cellSpacing=12 cellPadding=0 width=\"100%\">\r\n  <FORM name=\"upload_flash\" method=post encType=multipart/form-data onSubmit=\"return check_form ()\">\r\n    <TBODY>\r\n      <TR align=\"center\"> \r\n        <TD> <FIELDSET>\r\n          <LEGEND>";
echo $strHtmlFlash;
echo "</LEGEND>\r\n          \r\n        <table border=\"0\" width=\"100%\">\r\n          <tr valign=\"baseline\"> \r\n              <td colspan=\"4\" nowrap> <input name=\"radiobutton\" type=\"radio\" value=\"upload\" checked onClick=\"flash_upload ();\">\r\n                <a href=\"#\" style=\"cursor:default;color:#000000;text-decoration: none;\" onClick=\"upload_flash.radiobutton[0].checked=true;flash_upload ();\">\r\n\t\t\t\t";
echo $strHtmlFlashFileUp;
echo "</a>\r\n<input type=\"radio\" name=\"radiobutton\" value=\"fill\" onClick=\"flash_fill ();\">\r\n              <a href=\"#\" style=\"cursor:default;color:#000000;text-decoration: none;\" onClick=\"upload_flash.radiobutton[1].checked=true;flash_fill ();\">";
echo $strHtmlFlashFileUrl;
echo " \r\n              </a> \r\n              <input type=\"radio\" name=\"radiobutton\" value=\"3\" onClick=\"chose_flash ()\">\r\n                <a href=\"#\" style=\"cursor:default;color:#000000;text-decoration: none;\" onClick=\"upload_flash.radiobutton[2].checked=true;chose_flash ();\">";
echo $strHtmlFlashFileLib;
echo " </a>\r\n                <input type=\"hidden\" name=\"hiddenField\">\r\n                <lable></td>\r\n            </tr>\r\n            <tr valign=\"baseline\"> \r\n              <td width=\"81\" align=\"right\" nowrap><lable>";
echo $strHtmlFlashFile;
echo "</td>\r\n              <td colspan=\"3\" align=\"left\" nowrap><INPUT name=nlFile type=file size=\"27\">\r\n                <input name=\"flash_src\" type=\"text\" style=\"display: none\" value=\"http://\" size=\"38\"></td>\r\n            </tr>\r\n            <tr valign=\"baseline\"> \r\n              <td align=\"right\" nowrap><label>";
echo $strHtmlFlashName;
echo "</label></td>\r\n              <td width=\"95\"  align=\"left\" nowrap><input name=\"txtname\" type=\"text\" size=\"7\"> \r\n              </td>\r\n              <td width=\"60\" align=\"right\" nowrap>";
echo $strHtmlFlashBorder;
echo "</td>\r\n              <td width=\"107\" align=\"left\" nowrap><input name=\"txtborder\" type=\"text\" size=\"7\" maxlength=\"5\"></td>\r\n            </tr>\r\n            <tr valign=\"baseline\"> \r\n              <td align=\"right\" nowrap><label>";
echo $strHtmlFlashTitle;
echo "</label></td>\r\n              <td colspan=\"3\"  align=\"left\" nowrap><input type=\"text\" name=\"txttitle\" style=\"width:195px\"></td>\r\n            </tr>\r\n            <tr> \r\n              <td align=\"right\" valign=\"baseline\" nowrap>";
echo $strHtmlFlashWidth;
echo "</td>\r\n              <td colspan=\"3\" valign=\"baseline\" nowrap> <input name=\"txtWidth\" type=\"text\" size=\"8\" > \r\n                ";
echo "<s";
echo "elect name=\"WidthUnits\">\r\n                  <option value=\"%\" name=\"percent\">";
echo $strHtmlFlashPercent;
echo "</option>\r\n                  <option value=\"px\" selected name=\"pixels\" nowrap>";
echo $strHtmlFlashPx;
echo "</option>\r\n                </select> </td>\r\n            </tr>\r\n            <tr> \r\n              <td align=\"right\" valign=\"baseline\" nowrap>";
echo $strHtmlFlashHeight;
echo "</td>\r\n              <td colspan=\"3\" valign=\"baseline\" nowrap> <input name=\"txtHeight\" type=\"text\" size=\"8\" > \r\n                ";
echo "<s";
echo "elect name=\"HeightUnits\">\r\n                  <option value=\"%\" name=\"percent\">";
echo $strHtmlFlashPercent;
echo "</option>\r\n                  <option value=\"px\" selected name=\"pixels\" nowrap>";
echo $strHtmlFlashPx;
echo "</option>\r\n                </select> </td>\r\n            </tr>\r\n            <tr> \r\n              <td align=\"right\" valign=\"baseline\" nowrap>";
echo $strHtmlFlashHspace;
echo "</td>\r\n              <td valign=\"baseline\" nowrap><input type=\"text\" name=\"txthspace\" size=\"8\" > \r\n              </td>\r\n              <td align=\"right\" valign=\"baseline\" nowrap>";
echo $strHtmlFlashVspace;
echo "</td>\r\n              <td valign=\"baseline\" nowrap><input type=\"text\" name=\"txtvspace\" size=\"8\" ></td>\r\n            </tr>\r\n            <tr> \r\n              <td align=\"right\" valign=\"top\" nowrap>";
echo $strHtmlFlashPlay;
echo "</td>\r\n              <td colspan=\"3\" valign=\"baseline\" nowrap><table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\">\r\n                  <tr> \r\n                    <td><input name=\"chkplay\" type=\"checkbox\" value=\"-1\" checked>\r\n                      ";
echo $strHtmlFlashAuto;
echo " </td>\r\n                    <td><input name=\"chkmenu\" type=\"checkbox\" value=\"-1\" checked>\r\n                      ";
echo $strHtmlFlashMenu;
echo " </td>\r\n                  </tr>\r\n                  <tr> \r\n                    <td><input name=\"chkloop\" type=\"checkbox\" value=\"-1\" checked>\r\n                      ";
echo $strHtmlFlashReplay;
echo " </td>\r\n                    <td><input type=\"checkbox\" name=\"chkdevicefont\" value=\"0\">\r\n                      ";
echo $strHtmlFlashFont;
echo " </td>\r\n                  </tr>\r\n                </table></td>\r\n            </tr>\r\n            <tr valign=\"baseline\"> \r\n              <td align=\"right\" nowrap><label>";
echo $strHtmlFlashDq;
echo "</label></td>\r\n              <td colspan=\"3\"  align=\"left\" nowrap>";
echo "<s";
echo "elect name=\"sltalign\" style=\"width:150px\">\r\n                <option value=\"\" selected>";
echo $strHtmlFlashDefault;
echo "</option>\r\n                <option value=\"top\">";
echo $strHtmlFlashTop;
echo "</option>\r\n                <option value=\"middle\">";
echo $strHtmlFlashMiddle;
echo "</option>\r\n                <option value=\"bottom\">";
echo $strHtmlFlashBottom;
echo "</option>\r\n                <option value=\"left\">";
echo $strHtmlFlashLeft;
echo "</option>\r\n                <option value=\"center\">";
echo $strHtmlFlashCenter;
echo "</option>\r\n                <option value=\"right\">";
echo $strHtmlFlashRight;
echo "</option>\r\n              </select></td>\r\n            </tr>\r\n            <tr valign=\"baseline\"> \r\n             <td align=\"right\" nowrap><label>";
echo $strHtmlFlashPz;
echo "</label></td>\r\n              <td colspan=\"3\"  align=\"left\" nowrap>";
echo "<s";
echo "elect name=\"tmpquality\" style=\"width:150px\">\r\n                  <option value=\"Low\">";
echo $strHtmlFlashPzLow;
echo "</option>\r\n                  <option value=\"AutoLow\">";
echo $strHtmlFlashPzAutoLow;
echo "</option>\r\n                  <option value=\"AutoHigh\">";
echo $strHtmlFlashPzAutoHigh;
echo "</option>\r\n                  <option value=\"Medium\">";
echo $strHtmlFlashPzMedium;
echo "</option>\r\n                  <option value=\"High\" selected>";
echo $strHtmlFlashPzHigh;
echo "</option>\r\n                  <option value=\"Best\">";
echo $strHtmlFlashPzBest;
echo "</option>\r\n                </select></td>\r\n            </tr>\r\n            <tr valign=\"baseline\"> \r\n              <td align=\"right\" nowrap><label>";
echo $strHtmlFlashBL;
echo "</label></td>\r\n              <td colspan=\"3\"  align=\"left\" nowrap>";
echo "<s";
echo "elect name=\"tmpscale\" style=\"width:150px\">\r\n                  <option>";
echo $strHtmlFlashBLDefault;
echo "</option>\r\n                  <option value=\"noborder\">";
echo $strHtmlFlashBLNoBorder;
echo "</option>\r\n                  <option value=\"exactfit\">";
echo $strHtmlFlashBLExactfit;
echo "</option>\r\n                  <option value=\"noscale\">";
echo $strHtmlFlashBLNoscale;
echo "</option>\r\n                </select></td>\r\n            </tr>\r\n          </table>\r\n          </FIELDSET></TD>\r\n      </TR>\r\n      <TR> \r\n        <TD align=right><INPUT  type=submit value=\"";
echo $strConfirm;
echo "\" name=sAction> <INPUT name=\"button\" type=button onclick=\"javascript: window.close();\" value=\"";
echo $strCancel;
echo "\"></TD>\r\n      </TR>\r\n  </FORM>\r\n</TABLE>\r\n</body>\r\n</html>\r\n";
?>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -