Index: openacs-4/packages/acs-templating/www/resources/xinha-nightly/plugins/OacsAttach/oacs-attach.js =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-templating/www/resources/xinha-nightly/plugins/OacsAttach/oacs-attach.js,v diff -u -N -r1.3 -r1.4 --- openacs-4/packages/acs-templating/www/resources/xinha-nightly/plugins/OacsAttach/oacs-attach.js 31 Aug 2006 14:15:19 -0000 1.3 +++ openacs-4/packages/acs-templating/www/resources/xinha-nightly/plugins/OacsAttach/oacs-attach.js 17 Oct 2006 23:21:51 -0000 1.4 @@ -37,7 +37,11 @@ OacsAttach.folder_id = this.editor.config.folder_id; OacsAttach.file_types = this.editor.config.file_types; OacsAttach.fullscreen_mode = additionalArgs[1]; - + if (this.editor.config.key) { + OacsAttach.key = this.editor.config.key; + } else { + OacsAttach.key = ''; + } var cfg = editor.config; var tt = OacsAttach.I18N; var bl = OacsAttach.btnList; @@ -124,7 +128,9 @@ // fs_package_id; var PopupUrl = "/acs-templating/scripts/xinha/attach-file?"; - if (typeof OacsAttach.attach_parent_id != "undefined") { + if (typeof OacsAttach.key != "undefinied") { + PopupUrl = PopupUrl + "&parent_id=" + OacsAttach.key; + } else if (typeof OacsAttach.attach_parent_id != "undefined") { PopupUrl = PopupUrl + "&parent_id=" + OacsAttach.attach_parent_id; } if (typeof OacsAttach.fs_package_id != "undefined") { @@ -189,7 +195,9 @@ } var PopupUrl = "/acs-templating/scripts/xinha/attach-file?"; - if (typeof OacsAttach.attach_parent_id != "undefined") { + if (typeof OacsAttach.key != "undefinied") { + PopupUrl = PopupUrl + "&parent_id=" + OacsAttach.key; + } else if (typeof OacsAttach.attach_parent_id != "undefined") { PopupUrl = PopupUrl + "&parent_id=" + OacsAttach.attach_parent_id; } if (typeof OacsAttach.fs_package_id != "undefined") { @@ -263,7 +271,9 @@ // fs_package_id; var PopupUrl = "/acs-templating/scripts/xinha/attach-image?"; - if (typeof OacsAttach.attach_parent_id != "undefined") { + if (typeof OacsAttach.key != "undefinied") { + PopupUrl = PopupUrl + "&parent_id=" + OacsAttach.key; + } else if (typeof OacsAttach.attach_parent_id != "undefined") { PopupUrl = PopupUrl + "&parent_id=" + OacsAttach.attach_parent_id; } if (typeof OacsAttach.folder_id != "undefined") { @@ -290,6 +300,7 @@ } else { img.src = param.f_url; } + if (img) { for (field in param) { var value = param[field]; switch (field) { @@ -300,5 +311,6 @@ case "f_horiz" : img.hspace = parseInt(value || "0"); break; } } + } }, outparam); }; Index: openacs-4/packages/acs-templating/www/scripts/xinha/attach-file.adp =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-templating/www/scripts/xinha/attach-file.adp,v diff -u -N -r1.7 -r1.8 --- openacs-4/packages/acs-templating/www/scripts/xinha/attach-file.adp 9 Oct 2006 19:29:51 -0000 1.7 +++ openacs-4/packages/acs-templating/www/scripts/xinha/attach-file.adp 17 Oct 2006 23:21:50 -0000 1.8 @@ -99,13 +99,21 @@ -
+ + + + + +
Choose File
@formgroup.widget;noquote@ @formgroup.label;noquote@
+ +
@formerror.choose_file@
+