Author: taylor
Date: Mon Nov 26 13:14:55 2007
New Revision: 598432
URL: http://svn.apache.org/viewvc?rev=598432&view=rev
Log:
Jetspeed Data Importer copied into trunk
Added:
portals/jetspeed-2/trunk/applications/j2-admin/src/java/org/apache/jetspeed/portlets/admin/
portals/jetspeed-2/trunk/applications/j2-admin/src/java/org/apache/jetspeed/portlets/admin/JetspeedDataImporter.java
portals/jetspeed-2/trunk/applications/j2-admin/src/webapp/WEB-INF/view/admin/
portals/jetspeed-2/trunk/applications/j2-admin/src/webapp/WEB-INF/view/admin/importer-header.vm
portals/jetspeed-2/trunk/applications/j2-admin/src/webapp/WEB-INF/view/admin/importer-view.vm
Modified:
portals/jetspeed-2/trunk/applications/j2-admin/src/webapp/WEB-INF/portlet.xml
Added:
portals/jetspeed-2/trunk/applications/j2-admin/src/java/org/apache/jetspeed/portlets/admin/JetspeedDataImporter.java
URL:
http://svn.apache.org/viewvc/portals/jetspeed-2/trunk/applications/j2-admin/src/java/org/apache/jetspeed/portlets/admin/JetspeedDataImporter.java?rev=598432&view=auto
==============================================================================
---
portals/jetspeed-2/trunk/applications/j2-admin/src/java/org/apache/jetspeed/portlets/admin/JetspeedDataImporter.java
(added)
+++
portals/jetspeed-2/trunk/applications/j2-admin/src/java/org/apache/jetspeed/portlets/admin/JetspeedDataImporter.java
Mon Nov 26 13:14:55 2007
@@ -0,0 +1,299 @@
+package org.apache.jetspeed.portlets.admin;
+
+import java.io.File;
+import java.io.FileOutputStream;
+import java.io.IOException;
+import java.util.HashMap;
+import java.util.Iterator;
+import java.util.Map;
+
+import javax.portlet.ActionRequest;
+import javax.portlet.ActionResponse;
+import javax.portlet.PortletConfig;
+import javax.portlet.PortletException;
+import javax.portlet.RenderRequest;
+import javax.portlet.RenderResponse;
+
+import org.apache.commons.fileupload.FileItem;
+import org.apache.commons.fileupload.disk.DiskFileItemFactory;
+import org.apache.commons.fileupload.portlet.PortletFileUpload;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+import org.apache.jetspeed.CommonPortletServices;
+import org.apache.jetspeed.headerresource.HeaderResource;
+import org.apache.jetspeed.security.GroupManager;
+import org.apache.jetspeed.security.RoleManager;
+import org.apache.jetspeed.security.UserManager;
+import org.apache.jetspeed.serializer.JetspeedSerializer;
+import org.apache.jetspeed.serializer.JetspeedSerializerFactory;
+import org.apache.portals.gems.dojo.AbstractDojoVelocityPortlet;
+
+/**
+ * Manage the Portal Site
+ *
+ * @author <a href="mailto:[EMAIL PROTECTED]">Vivek Kumar</a>
+ *
+ * @version $Id$
+ */
+public class JetspeedDataImporter extends AbstractDojoVelocityPortlet
+{
+
+ protected final Log log = LogFactory.getLog(this.getClass());
+
+ // components
+ protected UserManager userManager;
+
+ protected GroupManager groupManager;
+
+ protected RoleManager roleManager;
+
+ private HashMap roleMap = new HashMap();
+
+ private HashMap groupMap = new HashMap();
+
+ private HashMap userMap = new HashMap();
+
+ private HashMap mimeMap = new HashMap();
+
+ private HashMap mimeMapInt = new HashMap();
+
+ private HashMap mediaMap = new HashMap();
+
+ private HashMap capabilityMap = new HashMap();
+
+ private HashMap capabilityMapInt = new HashMap();
+
+ private HashMap clientMap = new HashMap();
+
+ private HashMap permissionMap = new HashMap();
+
+ private HashMap rulesMap = new HashMap();
+
+ int refCouter = 0;
+
+ private static String ENCODING_STRING = "JETSPEED 2.1 - 2006";
+
+ private static String JETSPEED = "JETSPEED";
+
+ protected JetspeedSerializerFactory serializerFactory;
+
+ protected void includeHeaderContent(HeaderResource headerResource)
+ {
+ headerResource.dojoAddCoreLibraryRequire("dojo.lang.*");
+ // headerResource.dojoAddCoreLibraryRequire("dojo.dnd.*");
+ headerResource.dojoAddCoreLibraryRequire("dojo.dnd.HtmlDragManager");
+ headerResource.dojoAddCoreLibraryRequire("dojo.dnd.DragAndDrop");
+ headerResource.dojoAddCoreLibraryRequire("dojo.dnd.HtmlDragAndDrop");
+
+ headerResource.dojoAddCoreLibraryRequire("dojo.event.*");
+ headerResource.dojoAddCoreLibraryRequire("dojo.io");
+
+ headerResource.dojoAddCoreLibraryRequire("dojo.widget.ContentPane");
+
headerResource.dojoAddCoreLibraryRequire("dojo.widget.LayoutContainer");
+
+ headerResource.dojoAddCoreLibraryRequire("dojo.widget.Tree");
+ headerResource
+ .dojoAddCoreLibraryRequire("dojo.widget.TreeRPCController");
+ headerResource.dojoAddCoreLibraryRequire("dojo.widget.TreeSelector");
+ headerResource.dojoAddCoreLibraryRequire("dojo.widget.TreeNode");
+
headerResource.dojoAddCoreLibraryRequire("dojo.widget.TreeContextMenu");
+
+ headerResource
+ .dojoAddCoreLibraryRequire("dojo.widget.ValidationTextbox");
+ headerResource.dojoAddCoreLibraryRequire("dojo.widget.ComboBox");
+ headerResource.dojoAddCoreLibraryRequire("dojo.widget.Checkbox");
+ headerResource.dojoAddCoreLibraryRequire("dojo.widget.Dialog");
+ headerResource.dojoAddCoreLibraryRequire("dojo.widget.Button");
+
+ headerResource.dojoAddModuleLibraryRequire("jetspeed.desktop.core");
+ headerResource
+ .dojoAddModuleLibraryRequire("jetspeed.widget.EditorTable");
+ }
+
+ public void init(PortletConfig config) throws PortletException
+ {
+ super.init(config);
+ userManager = (UserManager) getPortletContext().getAttribute(
+ CommonPortletServices.CPS_USER_MANAGER_COMPONENT);
+ if (null == userManager)
+ {
+ PortletException pe = new PortletException(
+ "Failed to find the User Manager on SiteViewController
initialization");
+ throw new RuntimeException(pe);
+ }
+ groupManager = (GroupManager) getPortletContext().getAttribute(
+ CommonPortletServices.CPS_GROUP_MANAGER_COMPONENT);
+ if (null == groupManager)
+ {
+ PortletException pe = new PortletException(
+ "Failed to find the Group Manager on SiteViewController
initialization");
+ throw new RuntimeException(pe);
+ }
+ roleManager = (RoleManager) getPortletContext().getAttribute(
+ CommonPortletServices.CPS_ROLE_MANAGER_COMPONENT);
+ if (null == roleManager)
+ {
+ PortletException pe = new PortletException(
+ "Failed to find the Group Manager on SiteViewController
initialization");
+ throw new RuntimeException(pe);
+ }
+ serializerFactory = (JetspeedSerializerFactory)
getPortletContext().getAttribute(
+ CommonPortletServices.CPS_JETSPEED_SERIALIZER_FACTORY);
+ if (null == serializerFactory)
+ {
+ PortletException pe = new PortletException(
+ "Failed to find the SerializerFactory on
SiteViewController initialization");
+ throw new RuntimeException(pe);
+ }
+
+ }
+
+ public void doView(RenderRequest request, RenderResponse response)
+ throws PortletException, IOException
+ {
+ super.doView(request, response);
+ request.getPortletSession().removeAttribute("status");
+ request.getPortletSession().removeAttribute("msg");
+ }
+
+ public void processAction(ActionRequest request,
+ ActionResponse actionResponse) throws PortletException,
+ java.io.IOException
+ {
+ String export = request.getParameter("export");
+ String fileName = "";
+ String destPath = "";
+ String fileType = "";
+ String path = "";
+ String usrFolder = "";
+ boolean success = false;
+ String filePath = "";
+ cleanUserFolder(request.getUserPrincipal().toString());
+ try
+ {
+ DiskFileItemFactory diskFileItemFactory = new
DiskFileItemFactory();
+ PortletFileUpload portletFileUpload = new PortletFileUpload(
+ diskFileItemFactory);
+ if (PortletFileUpload.isMultipartContent(request))
+ {
+ Iterator fileIt = portletFileUpload.parseRequest(request)
+ .iterator();
+ while (fileIt.hasNext())
+ {
+ FileItem fileItem = (FileItem) fileIt.next();
+ if (fileItem.getFieldName().equals("importFile"))
+ {
+ synchronized (this)
+ {
+ fileName = fileItem.getName();
+ usrFolder = getTempFolder(request);
+ path = System.getProperty("file.separator");
+ filePath = usrFolder + path + fileItem.getName();
+ FileOutputStream out = new FileOutputStream(
+ filePath);
+ out.write(fileItem.get());
+ out.close();
+ }
+
+ }
+ }
+ success = importJetspeedData(filePath);
+ }
+ if (success)
+ {
+ request.getPortletSession().setAttribute("status", fileName);
+ request.getPortletSession().setAttribute("msg", "File imported
succesfully");
+ }
+ else
+ {
+ request.getPortletSession().setAttribute("status", "false");
+ request.getPortletSession().setAttribute("msg", "Failed to
import file. Please check XML file for correctness.");
+ }
+ } catch (Exception e)
+ {
+ request.getPortletSession().setAttribute("status", "false");
+ request.getPortletSession().setAttribute("msg", e.getMessage());
+ // throw new PortletException("Error occured in file uplodad");
+ }
+ }
+
+ private boolean importJetspeedData(String filePath)
+ {
+ try
+ {
+ Map settings = new HashMap();
+ settings.put(JetspeedSerializer.KEY_PROCESS_USERS, Boolean.TRUE);
+ settings.put(JetspeedSerializer.KEY_PROCESS_CAPABILITIES,
+ Boolean.TRUE);
+ settings.put(JetspeedSerializer.KEY_PROCESS_PROFILER,
Boolean.TRUE);
+ settings.put(JetspeedSerializer.KEY_PROCESS_USER_PREFERENCES,
+ Boolean.TRUE);
+ settings.put(JetspeedSerializer.KEY_OVERWRITE_EXISTING,
+ Boolean.TRUE);
+ settings.put(JetspeedSerializer.KEY_BACKUP_BEFORE_PROCESS,
+ Boolean.FALSE);
+ JetspeedSerializer serializer =
serializerFactory.create(JetspeedSerializerFactory.PRIMARY);
+ try
+ {
+ serializer.importData(filePath, settings);
+ }
+ catch (Exception e)
+ {
+ serializer =
serializerFactory.create(JetspeedSerializerFactory.SECONDARY);
+ serializer.importData(filePath, settings);
+ }
+ return true;
+ }
+ catch (Exception e)
+ {
+ return false;
+ }
+
+ }
+
+ private boolean cleanUserFolder(String userName)
+ {
+ boolean success = false;
+ synchronized (this)
+ {
+ String tmpdir = System.getProperty("java.io.tmpdir");
+ String path = System.getProperty("file.separator");
+ String folder = tmpdir + path + userName;
+ File dir = new File(folder);
+ if (dir.exists())
+ {
+ success = deleteDir(dir);
+ }
+ success = dir.mkdir();
+ }
+ return success;
+ }
+
+ private boolean deleteDir(File dir)
+ {
+ if (dir.exists())
+ {
+ File[] files = dir.listFiles();
+ for (int i = 0; i < files.length; i++)
+ {
+ if (files[i].isDirectory())
+ {
+ deleteDir(files[i]);
+ } else
+ {
+ files[i].delete();
+ }
+ }
+ }
+ return (dir.delete());
+ }
+
+ private String getTempFolder(ActionRequest request)
+ {
+ String dir = System.getProperty("java.io.tmpdir");
+ String path = System.getProperty("file.separator");
+ File file = new File(dir + path + request.getUserPrincipal());
+ file.mkdir();
+ return dir + path + request.getUserPrincipal();
+ }
+}
Modified:
portals/jetspeed-2/trunk/applications/j2-admin/src/webapp/WEB-INF/portlet.xml
URL:
http://svn.apache.org/viewvc/portals/jetspeed-2/trunk/applications/j2-admin/src/webapp/WEB-INF/portlet.xml?rev=598432&r1=598431&r2=598432&view=diff
==============================================================================
---
portals/jetspeed-2/trunk/applications/j2-admin/src/webapp/WEB-INF/portlet.xml
(original)
+++
portals/jetspeed-2/trunk/applications/j2-admin/src/webapp/WEB-INF/portlet.xml
Mon Nov 26 13:14:55 2007
@@ -1828,6 +1828,48 @@
</preference>
</portlet-preferences>
</portlet>
+
+ <portlet>
+ <description>The Portal Data Importer, import and export the jetspeed data
from jetspeed schema. From here you import/export the users,group,roles and
jetspeed objects
+ </description>
+ <portlet-name>PortalSchemaExporter</portlet-name>
+ <display-name>Portal Schema Importer</display-name>
+ <display-name
xml:lang="ja">ãã¼ã¿ã«ãµã¤ãããã¼ã¸ã£</display-name>
+
<portlet-class>org.apache.jetspeed.portlets.admin.JetspeedDataImporter</portlet-class>
+ <init-param>
+ <name>ViewPage</name>
+ <value>/WEB-INF/view/admin/importer-view.vm</value>
+ </init-param>
+ <init-param>
+ <name>HeaderPage</name>
+ <value>/WEB-INF/view/admin/importer-header.vm</value>
+ </init-param>
+ <init-param>
+ <name>dojo.requires.core</name>
+
<value>dojo.lang.*;dojo.event.*;dojo.io.*;dojo.dnd.*;dojo.widget.*;dojo.widget.Tree;dojo.widget.Button;dojo.widget.Checkbox;dojo.widget.Dialog;dojo.widget.TabContainer;dojo.widget.ContentPane;dojo.widget.LayoutContainer;dojo.widget.TreeRPCController;dojo.widget.TreeSelector;dojo.widget.TreeNode;dojo.widget.TreeContextMenu;dojo.widget.validate;dojo.widget.ComboBox;</value>
+ </init-param>
+ <init-param>
+ <name>portlet-icon</name>
+ <value>user-home.png</value>
+ </init-param>
+ <expiration-cache>300</expiration-cache>
+ <supports>
+ <mime-type>text/html</mime-type>
+ <portlet-mode>view</portlet-mode>
+ </supports>
+
<resource-bundle>org.apache.jetspeed.portlets.admin.resources.Importer</resource-bundle>
+ <portlet-info>
+ <title>Import Export Service</title>
+ <short-title>Import-Export</short-title>
+ <keywords>schema,export,import,users,group,roles</keywords>
+ </portlet-info>
+ <portlet-preferences>
+ <preference>
+ <name>defaultLayout</name>
+ <value>jetspeed-layouts::VelocityTwoColumns</value>
+ </preference>
+ </portlet-preferences>
+ </portlet>
<portlet id="CustomConfigModePortlet">
<description>Provides common custom config mode edit portlet.</description>
Added:
portals/jetspeed-2/trunk/applications/j2-admin/src/webapp/WEB-INF/view/admin/importer-header.vm
URL:
http://svn.apache.org/viewvc/portals/jetspeed-2/trunk/applications/j2-admin/src/webapp/WEB-INF/view/admin/importer-header.vm?rev=598432&view=auto
==============================================================================
---
portals/jetspeed-2/trunk/applications/j2-admin/src/webapp/WEB-INF/view/admin/importer-header.vm
(added)
+++
portals/jetspeed-2/trunk/applications/j2-admin/src/webapp/WEB-INF/view/admin/importer-header.vm
Mon Nov 26 13:14:55 2007
@@ -0,0 +1,78 @@
+#*
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+*#
+<style type="text/css">
+
+#toolsDiv img {
+ vertical-align: middle;
+}
+.treeTable tr {
+ vertical-align: top;
+}
+.formQuestion {
+ background-color:#d0e3f5;
+ padding:0.3em;
+ font-weight:900;
+ font-family:Verdana, Arial, sans-serif;
+ font-size:0.8em;
+ color:#5a5a5a;
+ }
+.formAnswer {
+ background-color:#f5eede;
+ padding:0.3em;
+ margin-bottom:1em;
+ width: 100%;
+ }
+.pageSubContentTitle {
+ color:#8e8e8e;
+ font-size:1em;
+ font-family:Verdana, Arial, sans-serif;
+ margin-bottom:0.75em;
+ }
+.small {
+ width: 2.5em;
+ }
+.medium {
+ width: 15em;
+ }
+.long {
+ width: 30em;
+ }
+
+span.invalid, span.missing {
+ display: inline;
+ margin-left: 1em;
+ font-weight: bold;
+ font-style: italic;
+ font-family: Arial, Verdana, sans-serif;
+ color: #f66;
+ font-size: 0.9em;
+ }
+
+.noticeMessage {
+ display: block;
+ float: right;
+ font-weight: normal;
+ font-family:Arial, Verdana, sans-serif;
+ color:#663;
+ font-size:0.9em;
+ }
+ /* group multiple buttons in a row */
+ div .dojoButton {
+ float: left;
+ margin-left: 10px;
+ }
+</style>
Added:
portals/jetspeed-2/trunk/applications/j2-admin/src/webapp/WEB-INF/view/admin/importer-view.vm
URL:
http://svn.apache.org/viewvc/portals/jetspeed-2/trunk/applications/j2-admin/src/webapp/WEB-INF/view/admin/importer-view.vm?rev=598432&view=auto
==============================================================================
---
portals/jetspeed-2/trunk/applications/j2-admin/src/webapp/WEB-INF/view/admin/importer-view.vm
(added)
+++
portals/jetspeed-2/trunk/applications/j2-admin/src/webapp/WEB-INF/view/admin/importer-view.vm
Mon Nov 26 13:14:55 2007
@@ -0,0 +1,242 @@
+#*
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+*#
+#set($rc =
$renderRequest.getAttribute("org.apache.jetspeed.request.RequestContext"))
+#set($req = $rc.Request)
+#set($app = $renderRequest.getContextPath())
+#set($rooturl =
"${req.scheme}://${req.serverName}:${req.serverPort}${req.contextPath}/")
+#set($treeName = $renderRequest.getParameter("treeName"))
+#set($renderURL = $renderResponse.createRenderURL())
+#set($actionURL = $renderResponse.createActionURL())
+#set($status = $renderRequest.getPortletSession().getAttribute("status"))
+#set($msg = $renderRequest.getPortletSession().getAttribute("msg"))
+<script>
+ function buildExportquery(){
+ var users = document.getElementById('users');
+ if(users.checked)
+ {
+ users.value = 'y';
+ }
+ else
+ {
+ users.value = 'n';
+ }
+ var profiling = document.getElementById('profiling');
+ if(profiling.checked)
+ {
+ profiling.value='y';
+ }
+ else
+ {
+ profiling.value='n';
+ }
+ var capabilities = document.getElementById('capabilities');
+ if(capabilities.checked)
+ {
+ capabilities.value='y';
+ }
+ else
+ {
+ capabilities.value='n';
+ }
+ var permissions = document.getElementById('permissions');
+ if(permissions.checked)
+ {
+ permissions.value='y';
+ }
+ else
+ {
+ permissions.value='n';
+ }
+ var names = new Array("users", "profiles","capabilities",
"permissions");
+ var values = new
Array(users.value,profiling.value,capabilities.value,permissions.value);
+ ajaxInvoke("jetspeedexport", names, values, new exportHandler()
);
+ }
+ function buildPrefsquery()
+ {
+ var prefs = document.getElementById('prefs');
+ if(prefs.checked)
+ {
+ prefs = 'y';
+ }else
+ {
+ prefs = 'n';
+ }
+ var names = new Array("prefs");
+ var values = new Array(prefs);
+ ajaxInvoke("jetspeedexport", names, values, new
exportHandler());
+ }
+ function exportHandler()
+ {
+ this.populate = function(xml)
+ {
+ var path = xml.getElementsByTagName("link");
+ if (path != null && path.length > 0)
+ {
+ for (ix=0; ix < path.length; ix++)
+ {
+ var refName = path[ix].firstChild.nodeValue;
+ }
+ }
+ var pgCol = document.getElementById("exportAns");
+ var a = document.createElement("a");
+ a.innerHTML ='Download';
+ a.href = refName;
+ a.setAttribute("target","_blank");
+ a.setAttribute("onClick","javascript:downloadObject()");
+ pgCol.appendChild(a);
+ }
+ this.failure = function(data)
+ {
+ var stsElmnt = xml.getElementsByTagName("status");
+ if(stsElmnt == 'failure')
+ {
+ alert('Error occurred during export');
+ }
+ }
+ }
+ function downloadObject()
+ {
+ document.getElementById("exportAns").innerHTML = '';
+ }
+ function ajaxInvoke(action, names, values, handler)
+ {
+ var contextPath = document.location.protocol + "/" + "/" +
document.location.host + "$req.ContextPath";
+ var requestUrl = contextPath + "/ajaxapi?action=" + action;
+ if (names != null)
+ {
+ for (var ix=0; ix<names.length; ix++)
+ {
+ requestUrl = requestUrl + "&" + names[ix] + "="
+ encodeURIComponent(values[ix]);
+ }
+ }
+ var mimeType = "text/xml";
+ dojo.io.bind({
+ url: requestUrl,
+ mimetype: mimeType,
+ load: function( type, data, evt )
+ {
+ var success = false;
+ var statusElmt = data.getElementsByTagName( "status" );
+ if ( statusElmt != null )
+ {
+ var successVal = statusElmt[0].firstChild.nodeValue;
+ if ( successVal == "success" )
+ {
+ handler.populate(data);
+ success = true;
+ }
+ }
+ if ( ! success )
+ {
+ var textContent = dojo.dom.innerXML( data );
+ if ( ! textContent )
+ textContent = ( data != null ? "!= null (IE no
XMLSerializer)" : "null" );
+ // dojo.raise( "saveEntrySubmit failure url=" + requestUrl
+ " xml-content=" + textContent );
+ if (data instanceof XMLDocument)
+ {
+ var reason = retrieveElementValue("reason", data);
+ alert("Portal Communication Failure: " + reason);
+ handler.failure(reason);
+ }
+ else
+ alert("Unknown Portal Communication Failure");
+ }
+ },
+ error: function( type, error )
+ {
+ var msg = "Portal Communication Error: " + requestUrl + " type:
" + type + jetspeed.url.formatBindError( error );
+ // dojo.raise(msg);
+ alert(msg);
+ handler.failure(msg);
+ }
+ });
+ }
+</script>
+<table width="100%" height="194" border="1">
+ <tr>
+ <form><td width="40%" height="188">
+ <table width="97%" border="1">
+ <tr>
+ <td colspan="2"><div align="left"><b>Export</b></div></td>
+ </tr>
+ <tr>
+ <td colspan="2"><input type="checkbox" name="users" id="users"
value="n">
+ Users/Groups/Roles</td>
+ </tr>
+ <tr>
+ <td colspan="2"><input type="checkbox" name="profiling" id="profiling"
value="n">
+ Profiling Rules </td>
+ </tr>
+ <tr>
+ <td colspan="2"><input type="checkbox" name="Capabilities"
id="capabilities" value="n">
+ Capabilities (Mimetypes, mediatypes, capabilities,clients)</td>
+ </tr>
+ <tr>
+ <td colspan="2"><input type="checkbox" name="permissions"
id="permissions" value="n">
+ Permissions</td>
+ </tr>
+ <tr>
+ <td><input type="button" value="Export"
onClick="javascript:buildExportquery();"></td>
+ <td id='exportAns'></td>
+ </tr>
+ </table>
+ <table width="97%" border="1">
+ <tr>
+ <td colspan="2"><div align="left"><b>Export Preferences</b></div></td>
+ </tr>
+ <tr>
+ <td colspan="2"><input type="checkbox" name="prefs" id="prefs"
value="n">
+ Preferences</td>
+ </tr>
+ <tr>
+ <td><input type="button" value="Export Prefs"
onClick="javascript:buildPrefsquery();"></td>
+ <td id='exportPrefsAns'></td>
+ </tr>
+ </table>
+ </td>
+ </form>
+ <td width="60%">
+ <form action="$actionURL" method="post" name="importObject"
enctype="multipart/form-data">
+ <table width="100%" border="1">
+ <tr>
+ <td><div><b>Import</b></div></td>
+ </tr>
+#if("$!status" != "")
+<tr>
+#if($status == 'false')
+ <td class="portlet-msg-error">$!msg</td>
+#else
+ <td class="portlet-msg-info">$!msg</td>
+#end
+</tr>
+#end
+ <tr>
+ <td>Choose file to import
+ <input type="file" name="importFile"></td>
+ </tr>
+ <tr>
+ <td>Please select xml file to import, containing jetspeed objects</td>
+ </tr>
+ <tr>
+ <td> </td>
+ </tr>
+ <tr>
+ <td><input type="button" value="Import"
onClick="javascript:document.importObject.submit();"></td>
+ </tr>
+ </table></form></td>
+ </tr>
+</table>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]