Rank: Member
Groups: Member
Joined: 1/10/2007(UTC) Posts: 15
|
Before the user even gets to the page we first check to see if they are on IE or another browser... another browser goes to our own java upload tool. Then we check to see if the user has the old version (3) loaded... (see code below) if they do, the go to an "upgrade page" that just lets them know they will need to approve the active x again. They should only see this page one time ever Code:
Function supportImageUploader()
If ScriptEngineMajorVersion >= 1 Then
supportImageUploader = "NotInstalled"
Dim installed
installed = False
installed = IsObject(CreateObject("[b]FortuneCity.EasyUploadTool[/b]"))
If installed Then
supportImageUploader = "Installed"
End If
Else
supportImageUploader = "Unsupported"
End If
End Function
Function isInstalled()
On Error Resume Next
installed = false
installed = IsObject(CreateObject("[b]FortuneCity.EasyUploadTool[/b]"))
If installed Then
isInstalled = "yes"
Else
isInstalled = "no"
End If
end function
If they have the new version loaded (see code below) They go right to the easy upload version Code:
Function supportNewImageUploader()
If ScriptEngineMajorVersion >= 4 Then
supportNewImageUploader = "NotInstalled"
Dim installed
installed = False
installed = IsObject(CreateObject("[b]FortuneCitycomInc.MyPhotoAlbumEasyUploadTool.4[/b]"))
If installed Then
supportNewImageUploader = "Installed"
End If
Else
supportNewImageUploader = "Unsupported"
End If
End Function
Function isNewInstalled()
On Error Resume Next
installed = false
installed = IsObject(CreateObject("[b]FortuneCitycomInc.MyPhotoAlbumEasyUploadTool.4[/b]"))
If installed Then
isNewInstalled = "yes"
Else
isNewInstalled = "no"
End If
end function
The actual load of the tool utilzes the js that you provide (see below) I have bolded all the itmes we have changed Code:
// Aurigma Image Uploader Embedding Script
// Version 2.0.2.0 August 21, 2006
// Copyright(c) Aurigma Inc. 2002-2006
function __Browser(){
var a=navigator.userAgent.toLowerCase();
this.isOpera=(a.indexOf("opera")!=-1);
this.isKonq=(a.indexOf('konqueror')!=-1);
this.isSafari=(a.indexOf('safari')!=-1)&&(a.indexOf('mac')!=-1);
this.isKhtml=this.isSafari||this.isKonq;
this.isIE=(a.indexOf("msie")!=-1)&&!this.isOpera;
this.isWinIE=this.isIE&&(a.indexOf("win")!=-1);
this.isCSS1Compat=(!this.isIE)||(document.compatMode&&document.compatMode=="CSS1Compat");
}
var __browser=new __Browser();
//Create set/get expando methods for ActiveX
function _createExpandoMethods(id){
var o=document.getElementById(id);
var props=new Array();
for (propName in o){
var c=propName.charAt(0);
if (c==c.toUpperCase()){
props.push(propName);
}
}
for (i=0;i<props.length;i++){
//Check whether property is indexed
if (typeof(o[props[i]])=="unknown"){
eval("o.set"+props[i]+"=function(i,v){this."+props[i]+"(i)=v;};");
eval("o.get"+props[i]+"=function(i){return this."+props[i]+"(i);};");
}
else{
eval("o.set"+props[i]+"=function(v){this."+props[i]+"=v};");
eval("o.get"+props[i]+"=function(){return this."+props[i]+"};");
}
}
// PaneItemDesign
//eval("o.setPaneItemDesign = function(Pane, Index, Value){this.PaneItemDesign(Pane, Index) = Value;};");
//eval("o.getPaneItemDesign = function(Pane, Index){return this.PaneItemDesign(Pane, Index);};");
// PaneItemSelected
//eval("o.getPaneItemSelected = function(Pane, Index){return this.PaneItemSelected(Pane, Index);};");
// PaneItemEnabled
//eval("o.setPaneItemEnabled = function(Pane, Index, Value){this.PaneItemEnabled(Pane, Index) = Value;};");
//eval("o.getPaneItemEnabled = function(Pane, Index){return this.PaneItemEnabled(Pane, Index);};");
}
//Installation instructions
function _addInstructions(obj){
obj.instructionsEnabled=true;
if (obj.controlClass=="FileDownloader"){
obj.instructionsCommon="File Downloader ActiveX control is necessary to download "+
"files quickly and easily. You will be able to select required files "+
"in a user-friendly interface and simply click a 'Download' button. "+
"Installation will take up to few minutes, please be patient. To install File Downloader, ";
obj.instructionsNotWinXPSP2="please reload the page and click the \"Yes\" button " +
"when you see the control installation dialog."
obj.instructionsWinXPSP2="please click the Information Bar. After page reloads click \"Yes\" when "+
"you see the control installation dialog.";
} else {
obj.instructionsCommon="[b]Please follow the directions to the left to install the new easy upload tool[/b]";
obj.instructionsNotWinXPSP2="";
obj.instructionsWinXPSP2="";
}
}
function ControlWriter(id,width,height){
//Private
this._params=new Array();
this._events=new Array();
this._getObjectParamHtml=function(name,value){
return "<param name=\""+name+"\" value=\""+value+"\" />";
}
this._getObjectParamsHtml=function(){
var r="";
var p=this._params;
var i;
for (i=0;i<p.length;i++){
r+=this._getObjectParamHtml(p[i].name,p[i].value);
}
return r;
}
this._getObjectEventsHtml=function(){
var r="";
var e=this._events;
for (i=0;i<e.length;i++){
r+=this._getObjectParamHtml(e[i].name+"Listener",e[i].listener);
}
return r;
}
this._getEmbedParamHtml=function(name,value){
return " "+name+"=\""+value+"\"";
}
this._getEmbedParamsHtml=function(){
var r="";
var p=this._params;
var i;
for (i=0;i<p.length;i++){
r+=this._getEmbedParamHtml(p[i].name,p[i].value);
}
return r;
}
this._getEmbedEventsHtml=function(){
var r="";
var e=this._events;
for (i=0;i<e.length;i++){
r+=this._getEmbedParamHtml(e[i].name+"Listener",e[i].listener);
}
return r;
}
//Public
//Properties
this.id=id;
this.width=width;
this.height=height;
this.activeXControlEnabled=true;
this.activeXControlVersion="";
this.javaAppletEnabled=true;
this.javaAppletCodeBase="./";
this.javaAppletCached=true;
this.javaAppletVersion="";
this.fullPageLoadListenerName=null;
//Methods
this.addParam=function(paramName,paramValue){
var p=new Object();
p.name=paramName;
p.value=paramValue;
this._params.push(p);
}
this.addEventListener=function(eventName,eventListener){
var p=new Object();
p.name=eventName;
p.listener=eventListener;
this._events.push(p);
}
this.getActiveXInstalled=function(){
if (this.activeXProgId){
try{
var a=new ActiveXObject(this.activeXProgId);
return true;
}
catch(e){
return false;
}
}
return false;
}
this.getHtml=function(){
var r="";
if (this.fullPageLoadListenerName){
r+="<" + "script type=\"text/javascript\">";
r+="var __"+this.id+"_pageLoaded=false;";
r+="var __"+this.id+"_controlLoaded=false;";
r+="function __fire_"+this.id+"_fullPageLoad(){";
r+="if (__"+this.id+"_pageLoaded&&__"+this.id+"_controlLoaded){";
r+=this.fullPageLoadListenerName + "();";
r+="}";
r+="}";
var pageLoadCode="new Function(\"__"+this.id+"_pageLoaded=true;__fire_"+this.id+"_fullPageLoad();\")";
if (__browser.isWinIE){
r+="window.attachEvent(\"onload\","+pageLoadCode+");";
}
else{
r+="var r=window.addEventListener?window:document.addEventListener?document:null;";
r+="if (r){r.addEventListener(\"load\","+pageLoadCode+",false);}";
}
r+="<"+"/script>";
}
_addInstructions(this);
//ActiveX control
if(__browser.isWinIE&&this.activeXControlEnabled){
var v=this.activeXControlVersion.replace(/\./g,",")
var cb=this.activeXControlCodeBase+(v==""?"":"#version="+v);
r+="<" + "script for=\""+this.id+"\" event=\"InitComplete()\">";
r+="_createExpandoMethods(\""+this.id+"\");";
if (this.fullPageLoadListenerName){
r+="__"+this.id+"_controlLoaded=true;";
r+="__fire_"+this.id+"_fullPageLoad();";
}
r+="<"+"/script>";
r+="<object id=\""+this.id+"\" name=\""+this.id+"\" classid=\"clsid:"+this.activeXClassId+"\" codebase=\""+cb+"\" width=\""+this.width+"\" height=\""+this.height+"\">";
if (this.instructionsEnabled){
r+=this.instructionsCommon;
var isXPSP2=(window.navigator.userAgent.indexOf("SV1") != -1);
if (isXPSP2){
r+=this.instructionsWinXPSP2;
}
else{
r+=this.instructionsNotWinXPSP2;
}
}
r+=this._getObjectParamsHtml();
r+="</object>";
//Event handlers
var e=this._events;
var eventParams;
for (i=0;i<e.length;i++){
if (this.controlClass=="FileDownloader"){
switch (e[i].name){
case "DownloadComplete":
eventParams="Value";
break;
case "DownloadItemComplete":
eventParams="Result, ErrorPage, Url, FileName, ContentType, FileSize";
break;
case "DownloadStep":
eventParams="Step";
break;
case "Progress":
eventParams="PercentTotal, PercentCurrent, Index";
break;
case "Error":
eventParams="ErrorCode, HttpErrorCode, ErrorPage, Url, Index";
break;
default:
eventParams="";
}
r+="<script for=\""+this.id+"\" event=\""+e[i].name+"("+eventParams+")\">";
r+=e[i].listener+"("+eventParams+");";
r+="<"+"/script>";
}
else {
switch (e[i].name){
case "Progress":
eventParams="Status, Progress, ValueMax, Value, StatusText";
break;
case "InnerComplete":
eventParams="Status, StatusText";
break;
case "ViewChange":
case "SortModeChange":
eventParams="Pane";
break;
default:
eventParams="";
}
}
r+="<" + "script for=\""+this.id+"\" event=\""+e[i].name+"("+eventParams+")\">";
if (e[i].name=="BeforeUpload"){
r+="return ";
}
r+=e[i].listener+"("+eventParams+");";
r+="<"+"/script>";
}
}
else
//Java appplet
if(this.javaAppletEnabled){
if (this.fullPageLoadListenerName){
r+="<" + "script type=\"text/javascript\">";
r+="function __"+this.id+"_InitComplete(){";
r+="__"+this.id+"_controlLoaded=true;";
r+="__fire_"+this.id+"_fullPageLoad();";
r+="}";
r+="<"+"/script>";
}
//<object> for IE and <applet> for Safari
if (__browser.isWinIE||__browser.isKhtml){
if (__browser.isWinIE){
r+="<object id=\""+this.id+"\" classid=\"clsid:F1F51698-7B63-4394-8743-1F4CF1853DE1\" codebase=\""+window.location.protocol+"//java.sun.com/update/1.4.2/jinstall-1_4-windows-i586.cab#Version=1,4,0,0\" width=\""+this.width+"\" height=\""+this.height+"\">";
}
else{
r+="<applet id=\""+this.id+"\" code=\""+this.javaAppletClassName+"\" java_codebase=\"../\" align=\"baseline\" archive=\""+this.javaAppletJarFileName+"\" mayscript=\"true\" scriptable=\"true\" width=\""+this.width+"\" height=\""+this.height+"\">";
}
if (this.javaAppletCached&&this.javaAppletVersion!=""){
r+=this._getObjectParamHtml("cache_archive",this.javaAppletJarFileName);
var v=this.javaAppletVersion.replace(/\,/g,".");
//r+=this._getObjectParamHtml("cache_version",v+","+v);
r+=this._getObjectParamHtml("cache_version",v);
}
r+=this._getObjectParamHtml("type","application/x-java-applet;version=1.4");
r+=this._getObjectParamHtml("codebase",this.javaAppletCodeBase);
r+=this._getObjectParamHtml("archive",this.javaAppletJarFileName);
r+=this._getObjectParamHtml("code",this.javaAppletClassName);
r+=this._getObjectParamHtml("scriptable","true");
r+=this._getObjectParamHtml("mayscript","true");
r+=this._getObjectParamsHtml();
r+=this._getObjectEventsHtml();
if (this.fullPageLoadListenerName){
r+=this._getObjectParamHtml("InitCompleteListener","__"+this.id+"_InitComplete");
}
if (__browser.isWinIE){
r+="</object>";
}
else{
r+="</applet>";
}
}
//<embed> for all other browsers
else{
r+="<embed id=\""+this.id+"\" type=\"application/x-java-applet;version=1.4\" codebase=\""+this.javaAppletCodeBase+"\" code=\""+this.javaAppletClassName+"\" archive=\""+this.javaAppletJarFileName+"\" width=\""+this.width+"\" height=\""+this.height+"\" scriptable=\"true\" mayscript=\"true\" pluginspage=\""+window.location.protocol+"//java.sun.com/products/plugin/index.html#download\"";
if (this.javaAppletCached&&this.javaAppletVersion!=""){
r+=this._getEmbedParamHtml("cache_archive",this.javaAppletJarFileName);
var v=this.javaAppletVersion.replace(/\,/g,".");
//r+=this._getEmbedParamHtml("cache_version",v+","+v);
r+=this._getEmbedParamHtml("cache_version",v);
}
r+=this._getEmbedParamsHtml();
r+=this._getEmbedEventsHtml();
if (this.fullPageLoadListenerName){
r+=this._getEmbedParamHtml("InitCompleteListener","__"+this.id+"_InitComplete");
}
r+=">";
r+="</embed>";
}
}
else
{
r+="Your browser is not supported.";
}
//For backward compatibility
this.controlType=this.getControlType();
return r;
}
this.getControlType=function(){
return (__browser.isWinIE&&this.activeXControlEnabled)?"ActiveX":(this.javaAppletEnabled?"Java":"None");
}
this.writeHtml=function(){
document.write(this.getHtml());
}
}
function ImageUploaderWriter(id,width,height){
this._base=ControlWriter;
this._base(id,width,height);
//These properties should be modified for private label versions only
this.activeXControlCodeBase="ImageUploader4.cab";
this.activeXClassId="[b]F1F51698-7B63-4394-8743-1F4CF1853DE1[/b]";
this.activeXProgId="[b]FortuneCitycomInc.MyPhotoAlbumEasyUploadTool.4[/b]";
this.javaAppletJarFileName="ImageUploader2.jar";
this.javaAppletClassName="com.aurigma.imageuploader.ImageUploader.class";
//Extend
this.showNonemptyResponse="off";
this._getHtml=this.getHtml;
this.getHtml=function(){
var r="";
if (this.showNonemptyResponse!="off"){
r+="<" + "script type=\"text/javascript\">";
r+="function __"+this.id+"_InnerComplete(Status,StatusText){";
r+="if (new String(Status)==\"COMPLETE\" && new String(StatusText).replace(/\\s*/g,\"\")!=\"\"){";
if (this.showNonemptyResponse=="dump"){
r+="var f=document.createElement(\"fieldset\");";
r+="var l=f.appendChild(document.createElement(\"legend\"));";
r+="l.appendChild(document.createTextNode(\"Server Response\"));";
r+="var d=f.appendChild(document.createElement(\"div\"));";
r+="d.innerHTML=StatusText;";
r+="var b=f.appendChild(document.createElement(\"button\"));";
r+="b.appendChild(document.createTextNode(\"Clear Server Response\"));";
r+="b.onclick=function(){var f=this.parentNode;f.parentNode.removeChild(f)};";
r+="document.body.appendChild(f);";
}
else{
var s="";
for (var i=0;i<80;i++){s+="-";}
r+="alert(\""+s+"\\r\\nServer Response\\r\\n"+s+"\\r\\n\"+StatusText);";
}
r+="}";
r+="}";
r+="<"+"/script>";
this.addEventListener("InnerComplete","__"+this.id+"_InnerComplete");
}
return r+this._getHtml();
}
}
function ThumbnailWriter(id,width,height){
this._base=ControlWriter;
this._base(id,width,height);
//These properties should be modified for private label versions only
this.activeXControlCodeBase="ImageUploader4.cab";
this.activeXClassId="[b]47937974-690E-49F5-ACD3-8115B61FC6D8[/b]";
this.activeXProgId="[b]FortuneCitycomInc.Thumbnail.4[/b]";
this.javaAppletJarFileName="ImageUploader2.jar";
this.javaAppletClassName="com.aurigma.imageuploader.Thumbnail.class";
}
function ShellComboBoxWriter(id,width,height){
this._base=ControlWriter;
this._base(id,width,height);
//These properties should be modified for private label versions only
this.activeXControlCodeBase="ImageUploader4.cab";
this.activeXClassId="[b]82B56B47-90DC-4F58-9A7D-D27BA46D3C0F[/b]";
this.activeXProgId="[b]FortuneCitycomInc.ShellCombo.4[/b]";
this.javaAppletJarFileName="ImageUploader2.jar";
this.javaAppletClassName="com.aurigma.imageuploader.ShellComboBox.class";
}
function UploadPaneWriter(id,width,height){
this._base=ControlWriter;
this._base(id,width,height);
//These properties should be modified for private label versions only
this.activeXControlCodeBase="ImageUploader4.cab";
this.activeXClassId="[b]2484BA21-8DF7-4C3E-97EB-E7290252ACBD[/b]";
this.activeXProgId="[b]FortuneCitycomInc.UploadPane.4[/b]";
this.javaAppletJarFileName="ImageUploader2.jar";
this.javaAppletClassName="com.aurigma.imageuploader.UploadPane.class";
}
function FileDownloaderWriter(id,width,height){
this._base=ControlWriter;
this._base(id,width,height);
//These properties should be modified for private label versions only
this.activeXControlCodeBase="FileDownloader.cab";
this.activeXClassId="[b]F1F51698-7B63-4394-8743-1F4CF1853DE1[/b]";
this.activeXProgId="[b]FortuneCitycomInc.FileDownloader.1[/b]";
this.javaAppletEnabled=false;
this.controlClass="FileDownloader";
}
function getControlObject(id){
if (__browser.isSafari){
return document[id];
}
else{
return document.getElementById(id);
}
}
function getImageUploader(id){
return getControlObject(id);
}
function getFileDownloader(id){
return getControlObject(id);
}
[/quote]
And the tool is called within our php page with the following code (nearly identical to the sample provided I have [b]bolded[/b] all the items we have changed:
[quote]
<table cellpadding="0" cellspacing="3" border="0">
<tr>
<td align="right">
Click to Look in:</td>
<td>
<table cellpadding="0" cellspacing="0" border="0" width="100%">
<tr>
<td>
<script type="text/javascript">
//<![CDATA[
//Create JavaScript object that will embed ShellComboBox to the page.
var sc = new ShellComboBoxWriter("ShellComboBox1", 320,24);
//For ActiveX control full path to CAB file (including file name) should be specified.
sc.activeXControlCodeBase = "[b]http://whoozie.myphotodevel.com/ImageUploader4.cab[/b]";
sc.activeXControlVersion = "[b]4,1,25,0[/b]";
//For Java applet only path to directory with JAR files should be specified (without file name).
sc.javaAppletCodeBase = "../";
sc.javaAppletCached = true;
sc.javaAppletVersion = "2.1.1.0";
//Configure appearance.
sc.addParam("BackgroundColor", "#ece9d8");
//Link ShellComboBox with ImageUploader
sc.addParam("AdditionalFolderNavigator", "[b]EasyUploadTool1[/b]");
//Tell the ShellComboBox writer object to generate all necessary HTML code to embed
//it to the page.
sc.writeHtml();
//]]>
</script>
</td>
<td align="right">
<button onclick="getImageUploader('[b]EasyUploadTool[/b]').GoToPreviousFolder();" title="Back"
class="SmallButton">
<img src="images/Back.gif" alt="Back" class="Icon" /></button>
<button onclick="getImageUploader('[b]EasyUploadTool[/b]').GoToParentFolder();" title="Up"
class="SmallButton">
<img src="images/Up.gif" alt="Up" class="Icon" /></button>
<button onclick="changeView(0);" title="Thumbnails" class="SmallButton">
<img src="images/Thumbnails.gif" alt="Thumbnails" class="Icon" />
</button>
<button onclick="changeView(3);" title="Details" class="SmallButton">
<img src="images/Details.gif" alt="Details" class="Icon" /></button>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td valign="top" class="LeftPanel">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="ShortcutPanel" valign="top">
<table>
<tr id="DesktopHolder">
<td>
<button title="Desktop" class="IconButton" onclick="getImageUploader('[b]EasyUploadTool[/b]').GoToFolder(desktop);">
<img src="images/Desktop.gif" alt="Desktop" class="Icon" />
Desktop
</button>
</td>
</tr>
<tr id="MyComputerHolder">
<td>
<button title="My Computer" class="IconButton" onclick="getImageUploader('[b]EasyUploadTool[/b]').GoToFolder(myComputer);">
<img src="images/MyComputer.gif" alt="My Computer" class="Icon" />
MyComputer
</button>
</td>
</tr>
<tr id="MyDocumentsHolder">
<td>
<button title="My Documents" class="IconButton" onclick="getImageUploader('[b]EasyUploadTool[/b]').GoToFolder(myDocuments);">
<img src="images/MyDocuments.gif" alt="My Documents" class="Icon" />
MyDocuments
</button>
</td>
</tr>
<tr id="MyPicturesHolder">
<td>
<button title="My Pictures" class="IconButton" onclick="getImageUploader('[b]EasyUploadTool[/b]').GoToFolder(myPictures);">
<img src="images/MyPictures.gif" alt="My Pictures" class="Icon" />
MyPictures
</button>
</td>
</tr>
<tr id="MyVideoHolder">
<td>
<button title="My Video" class="IconButton" onclick="getImageUploader('[b]EasyUploadTool[/b]').GoToFolder(myVideo);">
<img src="images/MyVideo.gif" alt="My Video" class="Icon" />
MyVideo
</button>
</td>
</tr>
<tr id="NetworkHolder">
<td>
<button title="Network" class="IconButton" onclick="getImageUploader('[b]EasyUploadTool[/b]').GoToFolder(network);">
<img src="images/Network.gif" alt="Network" class="Icon" />
Network
</button>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
<td valign="top">
<table width="100%">
<tr>
<td>
<button title="Select All" onclick="getImageUploader('[b]EasyUploadTool[/b]').SelectAll();"
class="Button" style="font-size:11px;">
Select All</button>
</td>
<td align="right">
<button title="Upload" onclick="getImageUploader('[b]EasyUploadTool[/b]').Send();" class="Button" class="submit" style="font-weight:bold;font-family:Arial, Verdana, Tahoma;">
<span class=blue>Upload Photos Now!</span></button>
</td>
</tr>
</table>
<script type="text/javascript">
//<![CDATA[
//Create JavaScript object that will embed Image Uploader to the page.
var iu = new ImageUploaderWriter("[b]EasyUploadTool[/b]", 540, 450);
//For ActiveX control full path to CAB file (including file name) should be specified.
iu.activeXControlCodeBase = "[b]http://whoozie.myphotoalbum.com/ImageUploader4.cab[/b]";
iu.activeXControlVersion = sc.activeXControlVersion;
//For Java applet only path to directory with JAR files should be specified (without file name).
iu.javaAppletCodeBase = "../";
iu.javaAppletCached = true;
iu.javaAppletVersion = sc.javaAppletVersion;
iu.showNonemptyResponse = "off";
iu.addParam("LicenseKey", "[b]6526-6190-7501-5974-64751;7430-6063-6063-7750-74030[/b]");
//Configure appearance and behaviour.
iu.addParam("PaneLayout", "TwoPanes");
iu.addParam("FolderView", "Thumbnails");
iu.addParam("UploadView", "Details");
iu.addParam("PreviewThumbnailSize", "70");
iu.addParam("ShowButtons", "false");
iu.addParam("ShowSubfolders", "true");
iu.addParam("ShowDescriptions", "false");
iu.addParam("ShowContextMenu", "false");
iu.addParam("ShowDebugWindow", "true");
iu.addParam("AllowMultipleRotate", "true");
iu.addParam("AllowFolderUpload", "false");
//Configure colors.
iu.addParam("PaneBackgroundColor", "#ffffff");
iu.addParam("BackgroundColor", "#ffffff");
iu.addParam("PreviewThumbnailBorderColor", "#eeeeee");
iu.addParam("PreviewThumbnailBorderHoverColor", "#f8b330");
//Configure Messages.
iu.addParam("LoadingFilesText", "Loading photos, please be patient...");
iu.addParam("ProgressDialogTitleText", "MyPhotoAlbum Easy Upload Tool");
iu.addParam("MegabytesText", "MB");
iu.addParam("KilobytesText", "KB");
iu.addParam("ProgressDialogPreparingDataText", "Preparing photos...");
iu.addParam("ProgressDialogEstimatedTimeText", "Estimated:[Current] of [Total]");
iu.addParam("ProgressDialogPreviewThumbnailSize", "100");
iu.addParam("ProgressDialogWidth", "450");
iu.addParam("MessageUploadCompleteText", "Success, your photos have been added to your album.");
iu.addParam("MessageUploadCancelledText", "You photo upload has been cancelled.");
iu.addParam("MessageUploadFailedText", "Your photo upload failed (the connection was interrupted), please try again.");
iu.addParam("MessageNoResponseFromServerText", "uring upload of your photos, the connection to MyPhotoAlbum was dropped, please try again");
iu.addParam("MessageNoInternetSessionTex", "During upload of your photos, the connection to MyPhotoAlbum was dropped, please try again.");
iu.addParam("MessageNoResponseFromServerText", "No response from MyPhotoAlbum server, please try again");
iu.addParam("MessageBoxTitleText", "MyPhotoAlbum Easy Upload Tool");
//Hide tree pane.
iu.addParam("TreePaneWidth", "-1");
//Allow upload not only files, but also entire folders.
//iu.addParam("AllowFolderUpload", "true");
//Single or multiple file selection.
//iu.addParam("AllowMultipleSelection", "false");
//Link ImageUploader with ShellComboBox.
iu.addParam("AdditionalFolderNavigator", "[b]EasyUploadTool1[/b]");
//Configure file mask to display images only.
iu.addParam("FileMask", "*.jpg;*.jpeg;*.jpe;*.gif;*.png");
//Configure thumbnail settings.
iu.addParam("UploadThumbnail1FitMode", "ActualSize");
iu.addParam("UploadThumbnail1JpegQuality", "100");
iu.addParam("UploadSourceFile", "true");
//Configure upload settings.
iu.addParam("Action", "[b]http://whoozie.myphotodevel.com:8080/image_uploader3.php[/b]");
iu.addParam("FilesPerOnePackageCount", "1");
iu.addParam("AutoRecoverMaxTriesCount", "3");
iu.addParam("AutoRecoverTimeOut", "2000");
//Configure URL where to redirect after upload.
iu.addParam("RedirectUrl", "[b]/personalize_album.php?set_albumName=<?php echo $gallery->session->albumName; ?>[/b]");
iu.fullPageLoadListenerName = "FullPageLoad";
//Tell Image Uploader writer object to generate all necessary HTML code to embed
//Image Uploader to the page.
iu.writeHtml();
//]]>
</script>
</td>
</tr>
</table>
Edited by user Tuesday, December 18, 2007 4:22:45 PM(UTC)
| Reason: Not specified
|