You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@roller.apache.org by sn...@apache.org on 2005/10/21 23:46:28 UTC

svn commit: r327589 [71/72] - in /incubator/roller/branches/roller_1.x: ./ contrib/ contrib/lib/ contrib/plugins/ contrib/plugins/src/ contrib/plugins/src/org/ contrib/plugins/src/org/roller/ contrib/plugins/src/org/roller/presentation/ contrib/plugins...

Added: incubator/roller/branches/roller_1.x/web/weblog/WeblogQuery.jsp
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_1.x/web/weblog/WeblogQuery.jsp?rev=327589&view=auto
==============================================================================
--- incubator/roller/branches/roller_1.x/web/weblog/WeblogQuery.jsp (added)
+++ incubator/roller/branches/roller_1.x/web/weblog/WeblogQuery.jsp Fri Oct 21 14:27:36 2005
@@ -0,0 +1,178 @@
+<%@ include file="/taglibs.jsp" %><%@ include file="/theme/header.jsp" %>
+<%@ page import="org.roller.presentation.weblog.actions.WeblogQueryPageModel" %>
+<%
+WeblogQueryPageModel model = (WeblogQueryPageModel)request.getAttribute("model");
+%>
+
+<h1><fmt:message key="weblogEntryQuery.title" /></h1>
+
+<roller:StatusMessage/>
+
+<html:form action="/editor/weblogQuery" method="post" focus="title">
+
+  <%-- ========================================================= --%>
+  <%-- filter by category --%>
+  
+    <div id="categoryControlToggle" class="controlToggle">
+      <span id="icategoryControl">+</span>  
+      <a href="#" class="controlToggle" 
+        onclick="javascript:toggleControl('categoryControlToggle','categoryControl')">
+         <fmt:message key="weblogEntryQuery.filterByCategory" />
+      </a>
+    </div>
+    <div id="categoryControl" class="control" style="display:none">
+
+            <label for="categoryId">
+                <fmt:message key="weblogEntryQuery.label.category" />
+            </label>
+            
+            <html:select property="categoryId" size="1" tabindex="4">
+                <html:option key="weblogEntryQuery.label.any" value="" />
+                <html:optionsCollection name="model" property="categories" value="id" label="path"  />
+            </html:select>
+            
+     </div>
+     
+  <%-- ========================================================= --%>
+  <%-- filter by date --%>
+  
+    <div id="dateControlToggle" class="controlToggle">
+      <span id="idateControl">+</span>  
+      <a href="#" class="controlToggle" onclick="javascript:toggleControl('dateControlToggle','dateControl')">
+        <fmt:message key="weblogEntryQuery.filterByPublishTime" />
+      </a>
+    </div>
+    <div id="dateControl" class="control" style="display:none">
+  
+            <label for="startDateString">
+               <fmt:message key="weblogEntryQuery.label.startDate" />:
+            </label>
+            <roller:Date property="startDateString" dateFormat='<%= model.getShortDateFormat() %>' />
+
+            <label for="endDateString">
+               <fmt:message key="weblogEntryQuery.label.endDate" />:
+            </label>
+            <roller:Date property="endDateString" dateFormat='<%= model.getShortDateFormat() %>' />
+        
+    </div>
+
+  <%-- ========================================================= --%>
+  <%-- filter by status --%>
+  
+    <div id="statusControlToggle" class="controlToggle">
+      <span id="istatusControl">+</span>  
+      <a href="#" class="controlToggle" 
+        onclick="javascript:toggleControl('statusControlToggle','statusControl')">
+         <fmt:message key="weblogEntryQuery.filterByStatus" />
+      </a>
+    </div>
+    <div id="statusControl" class="control" style="display:none">
+
+            <label for="status">
+                <fmt:message key="weblogEntryQuery.label.status" />:
+            </label>
+            
+            <html:radio property="status" value="ALL">
+                <fmt:message key="weblogEntryQuery.label.allEntries" /></html:radio>
+
+            <html:radio property="status" value="DRAFT_ONLY">
+                <fmt:message key="weblogEntryQuery.label.draftOnly" /></html:radio>
+
+            <html:radio property="status" value="PUBLISHED_ONLY" >
+                <fmt:message key="weblogEntryQuery.label.publishedOnly" /></html:radio>
+        
+    </div>
+
+  <%-- ========================================================= --%>
+  <%-- limit number of results --%>
+  
+    <div id="maxControlToggle" class="controlToggle">
+      <span id="imaxControl">+</span>  
+      <a href="#" class="controlToggle" onclick="javascript:toggleControl('maxControlToggle','maxControl')">
+        <fmt:message key="weblogEntryQuery.limitResultsReturned" />
+      </a>
+    </div>
+    <div id="maxControl" class="control" style="display:none">
+
+            <label for="maxEntries">
+                <fmt:message key="weblogEntryQuery.label.maxEntries" />
+            </label>
+            
+            <html:select property="maxEntries" size="1" tabindex="4">
+                <html:option value="25" />
+                <html:option value="50" />
+                <html:option value="75" />
+                <html:option value="100" />
+            </html:select>
+
+    </div>
+
+  <script type="text/javascript">
+  <!--
+  toggleControl('categoryControlToggle','categoryControl');
+  toggleControl('dateControlToggle','dateControl');
+  -->
+  </script>
+
+  <%-- ========================================================= --%>
+  <%-- search button --%>
+  
+    <br />
+    <div class="control">
+        <input type="button" name="post"
+            value='<fmt:message key="weblogEntryQuery.button.query" />' onclick="submit()"></input>
+    </div>
+    <br />
+    <html:hidden name="method" property="method" value="query"/>
+
+</html:form>
+
+<table class="rollertable">
+   <tr>
+      <th class="rollertable"><fmt:message key="weblogEdit.entryCol" /></th>
+   <tr>
+   <c:forEach var="post" items="${model.recentWeblogEntries}">
+      <tr>
+         <td class="rollertable_entry" width="100%" >
+
+            <roller:link page="/editor/weblog.do">
+                <roller:linkparam
+                    id="<%= RollerRequest.WEBLOGENTRYID_KEY %>"
+                    name="post" property="id" />
+                    <roller:linkparam id="method" value="edit" />
+                    <img src='<c:url value="/images/Edit16.png"/>' border="0" alt="icon" title="Edit" />
+                    <c:out value="${post.displayTitle}" />
+            </roller:link>
+            <br />
+
+            <span class="entryDetails">
+                <fmt:message key="weblogEdit.category" /> [<c:out value="${post.category.path}" />] |
+                <fmt:formatDate value="${post.pubTime}" type="both" dateStyle="medium" timeStyle="medium" />
+                <c:if test="${!empty post.link}">
+                  <a href='<c:out value="${post.link}" />' class="entryDetails">
+                     <fmt:message key="weblogEdit.link" />
+                  </a>
+                </c:if>
+                <a href='<c:out value="${model.baseURL}" /><c:out value="${post.permaLink}" />'
+                    class="entrypermalink" title="entry permalink">#</a>
+                <br />
+                <br />
+            </span>
+
+            <roller:ApplyPlugins name="post" skipFlag="true" scope="page" />
+
+         </td>
+       <tr>
+   </c:forEach>
+</table>
+
+<%@ include file="/theme/footer.jsp" %>
+
+
+<script type="text/javascript">
+<!--
+try {Start();} catch (e) {};
+-->
+</script>
+
+

Added: incubator/roller/branches/roller_1.x/web/weblog/bake-weblog.jsp
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_1.x/web/weblog/bake-weblog.jsp?rev=327589&view=auto
==============================================================================
--- incubator/roller/branches/roller_1.x/web/weblog/bake-weblog.jsp (added)
+++ incubator/roller/branches/roller_1.x/web/weblog/bake-weblog.jsp Fri Oct 21 14:27:36 2005
@@ -0,0 +1,16 @@
+<%@ include file="/taglibs.jsp" %><%@ include file="/theme/header.jsp"%>
+
+<div id="content" style="margin-top: 40px">
+
+<roller:StatusMessage/>
+<html:errors />
+
+<h3>Bake your Weblog Template</h3>
+
+    <html:form action="/editor/bake" method="post">
+        <input type="submit" value="Bake" />
+        <input type=hidden name="method" value="bake" />
+    </html:form>
+</div>
+
+<%@ include file="/theme/footer.jsp"%>
\ No newline at end of file

Added: incubator/roller/branches/roller_1.x/web/weblog/colors.html
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_1.x/web/weblog/colors.html?rev=327589&view=auto
==============================================================================
--- incubator/roller/branches/roller_1.x/web/weblog/colors.html (added)
+++ incubator/roller/branches/roller_1.x/web/weblog/colors.html Fri Oct 21 14:27:36 2005
@@ -0,0 +1,134 @@
+<html>
+<head>
+<title>Text Color</title>
+<script>
+function selectColor(color)
+{
+parent.document.getElementById("edit").contentDocument.execCommand(parent.command, false, color);
+parent.document.getElementById("colorpalette").style.visibility="hidden";
+parent.document.getElementById("edit").contentWindow.focus();
+}
+
+function InitColorPalette() {
+  if (document.getElementsByTagName)
+    var x = document.getElementsByTagName('TD');
+  else if (document.all)
+    var x = document.all.tags('TD');
+  for (var i=0;i<x.length;i++)
+  {
+    x[i].onmouseover = over;
+    x[i].onmouseout = out;
+    x[i].onclick = click;
+  }
+}
+
+function over()
+{
+this.style.border='2px dotted white';
+}
+
+function out()
+{
+this.style.border='1px solid gray';
+}
+
+function click()
+{
+  selectColor(this.id);
+}
+</script>
+</head>
+<body bgcolor="white" onLoad="InitColorPalette()">
+<table border="1" cellpadding="1" cellspacing="1">
+<tr>
+<td id="#FFFFFF" bgcolor="#FFFFFF" width="20" height="20"><img width="1" height="1"></td>
+<td id="#FFCCCC" bgcolor="#FFCCCC" width="20" height="20"><img width="1" height="1"></td>
+<td id="#FFCC99" bgcolor="#FFCC99" width="20" height="20"><img width="1" height="1"></td>
+<td id="#FFFF99" bgcolor="#FFFF99" width="20" height="20"><img width="1" height="1"></td>
+<td id="#FFFFCC" bgcolor="#FFFFCC" width="20" height="20"><img width="1" height="1"></td>
+<td id="#99FF99" bgcolor="#99FF99" width="20" height="20"><img width="1" height="1"></td>
+<td id="#99FFFF" bgcolor="#99FFFF" width="20" height="20"><img width="1" height="1"></td>
+
+<td id="#CCFFFF" bgcolor="#CCFFFF" width="20" height="20"><img width="1" height="1"></td>
+<td id="#CCCCFF" bgcolor="#CCCCFF" width="20" height="20"><img width="1" height="1"></td>
+<td id="#FFCCFF" bgcolor="#FFCCFF" width="20" height="20"><img width="1" height="1"></td>
+</tr>
+<tr>
+<td id="#CCCCCC" bgcolor="#CCCCCC" width="20" height="20"><img width="1" height="1"></td>
+<td id="#FF6666" bgcolor="#FF6666" width="20" height="20"><img width="1" height="1"></td>
+<td id="#FF9966" bgcolor="#FF9966" width="20" height="20"><img width="1" height="1"></td>
+<td id="#FFFF66" bgcolor="#FFFF66" width="20" height="20"><img width="1" height="1"></td>
+<td id="#FFFF33" bgcolor="#FFFF33" width="20" height="20"><img width="1" height="1"></td>
+<td id="#66FF99" bgcolor="#66FF99" width="20" height="20"><img width="1" height="1"></td>
+<td id="#33FFFF" bgcolor="#33FFFF" width="20" height="20"><img width="1" height="1"></td>
+<td id="#66FFFF" bgcolor="#66FFFF" width="20" height="20"><img width="1" height="1"></td>
+<td id="#9999FF" bgcolor="#9999FF" width="20" height="20"><img width="1" height="1"></td>
+<td id="#FF99FF" bgcolor="#FF99FF" width="20" height="20"><img width="1" height="1"></td>
+</tr>
+<tr>
+
+<td id="#C0C0C0" bgcolor="#C0C0C0" width="20" height="20"><img width="1" height="1"></td>
+<td id="#FF0000" bgcolor="#FF0000" width="20" height="20"><img width="1" height="1"></td>
+<td id="#FF9900" bgcolor="#FF9900" width="20" height="20"><img width="1" height="1"></td>
+<td id="#FFCC66" bgcolor="#FFCC66" width="20" height="20"><img width="1" height="1"></td>
+<td id="#FFFF00" bgcolor="#FFFF00" width="20" height="20"><img width="1" height="1"></td>
+<td id="#33FF33" bgcolor="#33FF33" width="20" height="20"><img width="1" height="1"></td>
+<td id="#66CCCC" bgcolor="#66CCCC" width="20" height="20"><img width="1" height="1"></td>
+<td id="#33CCFF" bgcolor="#33CCFF" width="20" height="20"><img width="1" height="1"></td>
+<td id="#6666CC" bgcolor="#6666CC" width="20" height="20"><img width="1" height="1"></td>
+<td id="#CC66CC" bgcolor="#CC66CC" width="20" height="20"><img width="1" height="1"></td>
+</tr>
+<tr>
+<td id="#999999" bgcolor="#999999" width="20" height="20"><img width="1" height="1"></td>
+<td id="#CC0000" bgcolor="#CC0000" width="20" height="20"><img width="1" height="1"></td>
+<td id="#FF6600" bgcolor="#FF6600" width="20" height="20"><img width="1" height="1"></td>
+<td id="#FFCC33" bgcolor="#FFCC33" width="20" height="20"><img width="1" height="1"></td>
+<td id="#FFCC00" bgcolor="#FFCC00" width="20" height="20"><img width="1" height="1"></td>
+
+<td id="#33CC00" bgcolor="#33CC00" width="20" height="20"><img width="1" height="1"></td>
+<td id="#00CCCC" bgcolor="#00CCCC" width="20" height="20"><img width="1" height="1"></td>
+<td id="#3366FF" bgcolor="#3366FF" width="20" height="20"><img width="1" height="1"></td>
+<td id="#6633FF" bgcolor="#6633FF" width="20" height="20"><img width="1" height="1"></td>
+<td id="#CC33CC" bgcolor="#CC33CC" width="20" height="20"><img width="1" height="1"></td>
+</tr>
+<tr>
+<td id="#666666" bgcolor="#666666" width="20" height="20"><img width="1" height="1"></td>
+<td id="#990000" bgcolor="#990000" width="20" height="20"><img width="1" height="1"></td>
+<td id="#CC6600" bgcolor="#CC6600" width="20" height="20"><img width="1" height="1"></td>
+<td id="#CC9933" bgcolor="#CC9933" width="20" height="20"><img width="1" height="1"></td>
+<td id="#999900" bgcolor="#999900" width="20" height="20"><img width="1" height="1"></td>
+<td id="#009900" bgcolor="#009900" width="20" height="20"><img width="1" height="1"></td>
+<td id="#339999" bgcolor="#339999" width="20" height="20"><img width="1" height="1"></td>
+<td id="#3333FF" bgcolor="#3333FF" width="20" height="20"><img width="1" height="1"></td>
+<td id="#6600CC" bgcolor="#6600CC" width="20" height="20"><img width="1" height="1"></td>
+<td id="#993399" bgcolor="#993399" width="20" height="20"><img width="1" height="1"></td>
+
+</tr>
+<tr>
+<td id="#333333" bgcolor="#333333" width="20" height="20"><img width="1" height="1"></td>
+<td id="#660000" bgcolor="#660000" width="20" height="20"><img width="1" height="1"></td>
+<td id="#993300" bgcolor="#993300" width="20" height="20"><img width="1" height="1"></td>
+<td id="#996633" bgcolor="#996633" width="20" height="20"><img width="1" height="1"></td>
+<td id="#666600" bgcolor="#666600" width="20" height="20"><img width="1" height="1"></td>
+<td id="#006600" bgcolor="#006600" width="20" height="20"><img width="1" height="1"></td>
+<td id="#336666" bgcolor="#336666" width="20" height="20"><img width="1" height="1"></td>
+<td id="#000099" bgcolor="#000099" width="20" height="20"><img width="1" height="1"></td>
+<td id="#333399" bgcolor="#333399" width="20" height="20"><img width="1" height="1"></td>
+<td id="#663366" bgcolor="#663366" width="20" height="20"><img width="1" height="1"></td>
+</tr>
+<tr>
+<td id="#000000" bgcolor="#000000" width="20" height="20"><img width="1" height="1"></td>
+<td id="#330000" bgcolor="#330000" width="20" height="20"><img width="1" height="1"></td>
+<td id="#663300" bgcolor="#663300" width="20" height="20"><img width="1" height="1"></td>
+
+<td id="#663333" bgcolor="#663333" width="20" height="20"><img width="1" height="1"></td>
+<td id="#333300" bgcolor="#333300" width="20" height="20"><img width="1" height="1"></td>
+<td id="#003300" bgcolor="#003300" width="20" height="20"><img width="1" height="1"></td>
+<td id="#003333" bgcolor="#003333" width="20" height="20"><img width="1" height="1"></td>
+<td id="#000066" bgcolor="#000066" width="20" height="20"><img width="1" height="1"></td>
+<td id="#330099" bgcolor="#330099" width="20" height="20"><img width="1" height="1"></td>
+<td id="#330033" bgcolor="#330033" width="20" height="20"><img width="1" height="1"></td>
+</tr>
+</table>
+</body>
+</html>

Added: incubator/roller/branches/roller_1.x/web/weblog/editor-dhtml.jsp
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_1.x/web/weblog/editor-dhtml.jsp?rev=327589&view=auto
==============================================================================
--- incubator/roller/branches/roller_1.x/web/weblog/editor-dhtml.jsp (added)
+++ incubator/roller/branches/roller_1.x/web/weblog/editor-dhtml.jsp Fri Oct 21 14:27:36 2005
@@ -0,0 +1,294 @@
+
+<%-- This page is designed to be included in edit-weblog.jsp --%>
+
+<%@ include file="/taglibs.jsp" %>
+
+<html:hidden property="text" />
+    
+<script language="JavaScript">
+<!--
+    // dhtml editor requires IE 6
+    var agt=navigator.userAgent.toLowerCase();
+    msie = agt.indexOf("msie");
+    ie   = (msie != -1);
+    major = parseInt(navigator.appVersion);
+    if (ie)
+    {
+        major = parseInt( agt.substring( msie+5 ) );
+    }
+    if (!ie || major < 6)
+    {
+        document.write("<span class=\"statusMsg\">");
+        document.write("We recommend ");
+        document.write("<a href=\"http://www.microsoft.com/windows/ie/default.asp\">IE 6 or higher</a> ");
+        document.write("for using the dHtml editor. ")
+        document.write("Please <a href=\"");
+        document.write("editor/website.do?method=edit&rmik=Settings\">");
+        document.write("change to the text editor</a> or upgrade ");
+        document.write("your browser.</span>");
+    }
+    
+    function postWeblogEntry(publish)
+    {
+        document.weblogEntryFormEx.text.value = iView.document.body.innerHTML;
+        if (publish)
+            document.weblogEntryFormEx.publishEntry.value = "true";
+        document.weblogEntryFormEx.submit();
+    }
+
+    var viewMode = 1; // WYSIWYG
+
+    function selOn(ctrl)
+    {
+        ctrl.style.borderColor = '#000000';
+        ctrl.style.backgroundColor = '#B5BED6';
+        ctrl.style.cursor = 'hand'; 
+    }
+
+    function selOff(ctrl)
+    {
+        ctrl.style.borderColor = '#D6D3CE';  
+        ctrl.style.backgroundColor = '#D6D3CE';
+    }
+
+    function selDown(ctrl)
+    {
+        ctrl.style.backgroundColor = '#8492B5';
+    }
+
+    function selUp(ctrl)
+    {
+        ctrl.style.backgroundColor = '#B5BED6';
+    }
+
+    function doBold()
+    {
+        iView.document.execCommand('bold', false, null);
+    }
+
+    function doItalic()
+    {
+        iView.document.execCommand('italic', false, null);
+    }
+
+    function doUnderline()
+    {
+        iView.document.execCommand('underline', false, null);
+    }
+
+    function doLeft()
+    {
+        iView.document.execCommand('justifyleft', false, null);
+    }
+
+    function doCenter()
+    {
+        iView.document.execCommand('justifycenter', false, null);
+    }
+
+    function doRight()
+    {
+        iView.document.execCommand('justifyright', false, null);
+    }
+
+    function doOrdList()
+    {
+        iView.document.execCommand('insertorderedlist', false, null);
+    }
+
+    function doBulList()
+    {
+        iView.document.execCommand('insertunorderedlist', false, null);
+    }
+
+    function doForeCol()
+    {
+        var fCol = prompt('Enter foreground color', '');
+
+        if(fCol != null)
+            iView.document.execCommand('forecolor', false, fCol);
+    }
+
+    function doBackCol()
+    {
+        var bCol = prompt('Enter background color', '');
+
+        if(bCol != null)
+            iView.document.execCommand('backcolor', false, bCol);
+    }
+
+    function doLink()
+    {
+        iView.document.execCommand('createlink');
+    }
+
+    function doImage()
+    {
+        var imgSrc = prompt('Enter image location', '');
+
+        if(imgSrc != null)    
+            iView.document.execCommand('insertimage', false, imgSrc);
+    }
+
+    function doRule()
+    {
+        iView.document.execCommand('inserthorizontalrule', false, null);
+    }
+
+    function doFont(fName)
+    {
+        if(fName != '')
+            iView.document.execCommand('fontname', false, fName);
+    }
+
+    function doSize(fSize)
+    {
+        if(fSize != '')
+            iView.document.execCommand('fontsize', false, fSize);
+    }
+
+    function doHead(hType)
+    {
+        if(hType != '')
+        {
+            iView.document.execCommand('formatblock', false, hType);  
+            doFont(selFont.options[selFont.selectedIndex].value);
+        }
+    }
+
+    function doToggleView()
+    {  
+        if(viewMode == 1)
+        {
+            iHTML = iView.document.body.innerHTML;
+            iView.document.body.innerText = iHTML;
+
+            // Hide all controls
+            tblCtrls.style.display = 'none';
+            tblCtrls2.style.display = 'none';
+            //selFont.style.display = 'none';
+            //selSize.style.display = 'none';
+            //selHeading.style.display = 'none';
+            iView.focus();
+
+            viewMode = 2; // Code
+        }
+        else
+        {
+            iText = iView.document.body.innerText;
+            iView.document.body.innerHTML = iText;
+
+            // Show all controls
+            tblCtrls.style.display = 'inline';
+            tblCtrls2.style.display = 'inline';
+            //selFont.style.display = 'inline';
+            //selSize.style.display = 'inline';
+            //selHeading.style.display = 'inline';
+            iView.focus();
+
+            viewMode = 1; // WYSIWYG
+        }
+    }
+// -->
+</script>
+<style>
+
+    .butClass
+    {    
+        border: 1px solid;
+        border-color: #D6D3CE;
+    }
+
+    .tdClass
+    {
+        padding-left: 3px;
+        padding-top:3px;
+    }
+
+</style>
+
+<table width="95%" height="30px" border="0" cellspacing="0" cellpadding="0" bgcolor="#D6D3CE">
+<tr>
+    <td id="tblCtrls" class="tdClass">
+        <img alt="Bold" class="butClass" src="<%= request.getContextPath() %>/images/editor/bold.gif" onMouseOver="selOn(this)" onMouseOut="selOff(this)" onMouseDown="selDown(this)" onMouseUp="selUp(this)" onClick="doBold()">
+        <img alt="Italic" class="butClass" src="<%= request.getContextPath() %>/images/editor/italic.gif" onMouseOver="selOn(this)" onMouseOut="selOff(this)" onMouseDown="selDown(this)" onMouseUp="selUp(this)" onClick="doItalic()">
+        <img alt="Underline" class="butClass" src="<%= request.getContextPath() %>/images/editor/underline.gif" onMouseOver="selOn(this)" onMouseOut="selOff(this)" onMouseDown="selDown(this)" onMouseUp="selUp(this)" onClick="doUnderline()">
+
+        <img alt="Left" class="butClass" src="<%= request.getContextPath() %>/images/editor/left.gif" onMouseOver="selOn(this)" onMouseOut="selOff(this)" onMouseDown="selDown(this)" onMouseUp="selUp(this)" onClick="doLeft()">
+        <img alt="Center" class="butClass" src="<%= request.getContextPath() %>/images/editor/center.gif" onMouseOver="selOn(this)" onMouseOut="selOff(this)" onMouseDown="selDown(this)" onMouseUp="selUp(this)" onClick="doCenter()">
+        <img alt="Right" class="butClass" src="<%= request.getContextPath() %>/images/editor/right.gif" onMouseOver="selOn(this)" onMouseOut="selOff(this)" onMouseDown="selDown(this)" onMouseUp="selUp(this)" onClick="doRight()">
+
+        <img alt="Ordered List" class="butClass" src="<%= request.getContextPath() %>/images/editor/ordlist.gif" onMouseOver="selOn(this)" onMouseOut="selOff(this)" onMouseDown="selDown(this)" onMouseUp="selUp(this)" onClick="doOrdList()">
+        <img alt="Bulleted List" class="butClass" src="<%= request.getContextPath() %>/images/editor/bullist.gif" onMouseOver="selOn(this)" onMouseOut="selOff(this)" onMouseDown="selDown(this)" onMouseUp="selUp(this)" onClick="doBulList()">
+
+        <img alt="Text Color" class="butClass" src="<%= request.getContextPath() %>/images/editor/forecol.gif" onMouseOver="selOn(this)" onMouseOut="selOff(this)" onMouseDown="selDown(this)" onMouseUp="selUp(this)" onClick="doForeCol()">
+        <img alt="Background Color" class="butClass" src="<%= request.getContextPath() %>/images/editor/bgcol.gif" onMouseOver="selOn(this)" onMouseOut="selOff(this)" onMouseDown="selDown(this)" onMouseUp="selUp(this)" onClick="doBackCol()">
+
+        <img alt="Hyperlink" class="butClass" src="<%= request.getContextPath() %>/images/editor/link.gif" onMouseOver="selOn(this)" onMouseOut="selOff(this)" onMouseDown="selDown(this)" onMouseUp="selUp(this)" onClick="doLink()">
+        <img alt="Image" class="butClass" src="<%= request.getContextPath() %>/images/editor/image.gif" onMouseOver="selOn(this)" onMouseOut="selOff(this)" onMouseDown="selDown(this)" onMouseUp="selUp(this)" onClick="doImage()">
+        <img alt="Horizontal Rule" class="butClass" src="<%= request.getContextPath() %>/images/editor/rule.gif" onMouseOver="selOn(this)" onMouseOut="selOff(this)" onMouseDown="selDown(this)" onMouseUp="selUp(this)" onClick="doRule()">
+
+    </td>
+    <td class="tdClass" colspan="1" width="20%" align="right">
+      <img alt="Toggle Mode" class="butClass" src="<%= request.getContextPath() %>/images/editor/mode.gif" onMouseOver="selOn(this)" onMouseOut="selOff(this)" onMouseDown="selDown(this)" onMouseUp="selUp(this)" onClick="doToggleView()">
+      &nbsp;&nbsp;&nbsp;
+    </td>
+</tr>
+</table>
+
+<table width="95%" height="30px" border="0" cellspacing="0" cellpadding="0" bgcolor="#D6D3CE">
+<tr>
+    <td id="tblCtrls2" class="tdClass" colspan="1" width="80%">
+      <select id="selFont" onChange="doFont(this.options[this.selectedIndex].value)">
+        <option value="">-- Font --</option>
+        <option value="Arial">Arial</option>
+        <option value="Courier">Courier</option>
+        <option value="Sans Serif">Sans Serif</option>
+        <option value="Tahoma">Tahoma</option>
+        <option value="Verdana">Verdana</option>
+        <option value="Wingdings">Wingdings</option>
+      </select>
+      <select id="selSize" onChange="doSize(this.options[this.selectedIndex].value)">
+        <option value="">-- Size --</option>
+        <option value="1">Very Small</option>
+        <option value="2">Small</option>
+        <option value="3">Medium</option>
+        <option value="4">Large</option>
+        <option value="5">Larger</option>
+        <option value="6">Very Large</option>
+      </select>
+      <select id="selHeading" onChange="doHead(this.options[this.selectedIndex].value)">
+        <option value="">-- Heading --</option>
+        <option value="Heading 1">H1</option>
+        <option value="Heading 2">H2</option>
+        <option value="Heading 3">H3</option>
+        <option value="Heading 4">H4</option>
+        <option value="Heading 5">H5</option>
+        <option value="Heading 6">H6</option>
+      </select>
+    </td>
+</tr>
+
+</table>
+
+<% // hack to support iframe's src attribute doing a call out 
+// No longer needed because form is now session scope
+//session.setAttribute("weblogEntryFormEx", 
+    //request.getAttribute("weblogEntryFormEx")); 
+%>
+<table width="95%" border="0" cellspacing="0" cellpadding="0" >
+<tr>
+    <td><iframe id="iView" width="100%" height="250" tabindex="2">
+        Your browser does not support iframes.  
+        Either change browsers or select a 
+        different editor for your website.</iframe>
+    </td>
+</tr>
+</table>
+<script language="JavaScript">
+    iView.document.designMode = 'On';
+    iView.document.open();
+    iView.document.write(document.weblogEntryFormEx.text.value);
+    iView.document.close();
+</script>
+

Added: incubator/roller/branches/roller_1.x/web/weblog/editor-ekit.jsp
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_1.x/web/weblog/editor-ekit.jsp?rev=327589&view=auto
==============================================================================
--- incubator/roller/branches/roller_1.x/web/weblog/editor-ekit.jsp (added)
+++ incubator/roller/branches/roller_1.x/web/weblog/editor-ekit.jsp Fri Oct 21 14:27:36 2005
@@ -0,0 +1,63 @@
+
+<%-- This page is designed to be included in edit-weblog.jsp --%>
+<%@ page import="org.roller.presentation.weblog.formbeans.WeblogEntryFormEx" %>
+<%@ include file="/taglibs.jsp" %>
+
+<script type="text/javascript">
+<!--
+function postWeblogEntry(publish)
+{
+    document.weblogEntryFormEx.text.value = document.Ekit.getDocumentText();
+    if (publish)
+        document.weblogEntryFormEx.publishEntry.value = "true";
+    document.weblogEntryFormEx.submit();
+}
+-->
+</script>
+
+<html:hidden property="text" />
+
+<%-- Use the Ekit applet --%>
+<APPLET CODEBASE="../" CODE="com.hexidec.ekit.EkitApplet.class"
+    ARCHIVE="ekitappletspell.jar" NAME="Ekit" WIDTH="95%" HEIGHT="550">
+<PARAM NAME="codebase" VALUE="../">
+<PARAM NAME="code" VALUE="com.hexidec.ekit.EkitApplet.class">
+<PARAM NAME="archive" VALUE="ekitappletspell.jar">
+<PARAM NAME="type" VALUE="application/x-java-applet;version=1.3">
+<PARAM NAME="scriptable" VALUE="true">
+
+<!-- Load text into Ekit applet by using the form bean -->
+<PARAM NAME="DOCUMENT"
+    VALUE="<HTML><HEAD></HEAD><BODY><bean:write
+        name="weblogEntryFormEx" property="text" /></BODY></HTML>">
+        
+<PARAM NAME="BASE64" VALUE="false">
+<PARAM NAME="STYLESHEET" VALUE="ekit.css">
+<PARAM NAME="LANGCODE" VALUE="en">
+<PARAM NAME="LANGCOUNTRY" VALUE="US">
+<PARAM NAME="TOOLBAR" VALUE="true">
+<PARAM NAME="TOOLBARMULTI" VALUE="true">
+<PARAM NAME="SOURCEVIEW" VALUE="false">
+<PARAM NAME="EXCLUSIVE" VALUE="true">
+<PARAM NAME="SPELLCHECK" VALUE="true">
+<PARAM NAME="MENUICONS" VALUE="true">
+<PARAM NAME="MENU_EDIT" VALUE="true">
+<PARAM NAME="MENU_VIEW" VALUE="true">
+<PARAM NAME="MENU_FONT" VALUE="true">
+<PARAM NAME="MENU_FORMAT" VALUE="true">
+<PARAM NAME="MENU_INSERT" VALUE="true">
+<PARAM NAME="MENU_TABLE" VALUE="true">
+<PARAM NAME="MENU_FORMS" VALUE="true">
+<PARAM NAME="MENU_SEARCH" VALUE="true">
+<PARAM NAME="MENU_TOOLS" VALUE="true">
+<PARAM NAME="MENU_HELP" VALUE="true">
+</APPLET>  
+
+
+<br /><a href="http://www.hexidec.com">Ekit</a> 
+editor by Howard Kistler of 
+<a href="http://www.hexidec.com">hexidec codex</a>
+<br />
+<br />
+
+

Added: incubator/roller/branches/roller_1.x/web/weblog/editor-midas.jsp
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_1.x/web/weblog/editor-midas.jsp?rev=327589&view=auto
==============================================================================
--- incubator/roller/branches/roller_1.x/web/weblog/editor-midas.jsp (added)
+++ incubator/roller/branches/roller_1.x/web/weblog/editor-midas.jsp Fri Oct 21 14:27:36 2005
@@ -0,0 +1,430 @@
+
+<%-- This page is designed to be included in edit-weblog.jsp --%>
+
+<%@ include file="/taglibs.jsp" %>
+
+<html:hidden property="text" />
+
+<script type="text/javascript">
+<!--
+    function postWeblogEntry(publish)
+    {
+        document.weblogEntryFormEx.text.value = document.getElementById('edit').contentWindow.document.body.innerHTML;
+        if (publish) document.weblogEntryFormEx.publishEntry.value = "true";
+        document.weblogEntryFormEx.submit();
+    }
+-->
+</script>
+
+<%-- The rest of this is straight from the Midas demo, except the DMJ_MOD marked changes --%>
+
+<style type="text/css">
+.imagebutton {height: 22; width: 23; border: solid 2px #C0C0C0; background-color: #C0C0C0}
+.image {position: relative; left: 1; top: 1; height:20; width:21; border:none;}
+.toolbar {height: 30; background-color: #C0C0C0;}
+</style>
+
+<script>
+
+var command = "";
+
+function InitToolbarButtons() {
+  kids = document.getElementsByTagName('DIV');
+
+  for (var i=0; i < kids.length; i++) {
+    if (kids[i].className == "imagebutton") {
+      kids[i].onmouseover = tbmouseover;
+      kids[i].onmouseout = tbmouseout;
+      kids[i].onmousedown = tbmousedown;
+      kids[i].onmouseup = tbmouseup;
+      kids[i].onclick = tbclick;
+    }
+  }
+}
+
+function tbmousedown(e)
+{
+  this.firstChild.style.left = 2;
+  this.firstChild.style.top = 2;
+  this.style.border="inset 2px";
+  e.preventDefault();
+}
+
+function tbmouseup()
+{
+  this.firstChild.style.left = 1;
+  this.firstChild.style.top = 1;
+  this.style.border="outset 2px";
+}
+
+function tbmouseout()
+{
+  this.style.border="solid 2px #C0C0C0";
+}
+
+function tbmouseover()
+{
+  this.style.border="outset 2px";
+}
+
+  function insertNodeAtSelection(win, insertNode)
+  {
+      // get current selection
+      var sel = win.getSelection();
+
+      // get the first range of the selection
+      // (there's almost always only one range)
+      var range = sel.getRangeAt(0);
+
+      // deselect everything
+      sel.removeAllRanges();
+
+      // remove content of current selection from document
+      range.deleteContents();
+
+      // get location of current selection
+      var container = range.startContainer;
+      var pos = range.startOffset;
+
+      // make a new range for the new selection
+      range=document.createRange();
+
+      if (container.nodeType==3 && insertNode.nodeType==3) {
+
+        // if we insert text in a textnode, do optimized insertion
+        container.insertData(pos, insertNode.nodeValue);
+
+        // put cursor after inserted text
+        range.setEnd(container, pos+insertNode.length);
+        range.setStart(container, pos+insertNode.length);
+
+      } else {
+
+
+        var afterNode;
+        if (container.nodeType==3) {
+
+          // when inserting into a textnode
+          // we create 2 new textnodes
+          // and put the insertNode in between
+
+          var textNode = container;
+          container = textNode.parentNode;
+          var text = textNode.nodeValue;
+
+          // text before the split
+          var textBefore = text.substr(0,pos);
+          // text after the split
+          var textAfter = text.substr(pos);
+
+          var beforeNode = document.createTextNode(textBefore);
+          var afterNode = document.createTextNode(textAfter);
+
+          // insert the 3 new nodes before the old one
+          container.insertBefore(afterNode, textNode);
+          container.insertBefore(insertNode, afterNode);
+          container.insertBefore(beforeNode, insertNode);
+
+          // remove the old node
+          container.removeChild(textNode);
+
+        } else {
+
+          // else simply insert the node
+          afterNode = container.childNodes[pos];
+          container.insertBefore(insertNode, afterNode);
+        }
+
+        range.setEnd(afterNode, 0);
+        range.setStart(afterNode, 0);
+      }
+
+      sel.addRange(range);
+  };
+
+function getOffsetTop(elm) {
+
+  var mOffsetTop = elm.offsetTop;
+  var mOffsetParent = elm.offsetParent;
+
+  while(mOffsetParent){
+    mOffsetTop += mOffsetParent.offsetTop;
+    mOffsetParent = mOffsetParent.offsetParent;
+  }
+ 
+  return mOffsetTop;
+}
+
+function getOffsetLeft(elm) {
+
+  var mOffsetLeft = elm.offsetLeft;
+  var mOffsetParent = elm.offsetParent;
+
+  while(mOffsetParent){
+    mOffsetLeft += mOffsetParent.offsetLeft;
+    mOffsetParent = mOffsetParent.offsetParent;
+  }
+ 
+  return mOffsetLeft;
+}
+
+function tbclick()
+{
+  if ((this.id == "forecolor") || (this.id == "hilitecolor")) {
+    parent.command = this.id;
+    buttonElement = document.getElementById(this.id);
+    document.getElementById("colorpalette").style.left = getOffsetLeft(buttonElement);
+    document.getElementById("colorpalette").style.top = getOffsetTop(buttonElement) + buttonElement.offsetHeight;
+    document.getElementById("colorpalette").style.visibility="visible";
+  } else if (this.id == "createlink") {
+    var szURL = prompt("Enter a URL:", "");
+    document.getElementById('edit').contentWindow.document.execCommand("CreateLink",false,szURL)
+  } else if (this.id == "createtable") {
+    e = document.getElementById("edit");
+    rowstext = prompt("enter rows");
+    colstext = prompt("enter cols");
+    rows = parseInt(rowstext);
+    cols = parseInt(colstext);
+    if ((rows > 0) && (cols > 0)) {
+      table = e.contentWindow.document.createElement("table");
+      table.setAttribute("border", "1");
+      table.setAttribute("cellpadding", "2");
+      table.setAttribute("cellspacing", "2");
+      tbody = e.contentWindow.document.createElement("tbody");
+      for (var i=0; i < rows; i++) {
+        tr =e.contentWindow.document.createElement("tr");
+        for (var j=0; j < cols; j++) {
+          td =e.contentWindow.document.createElement("td");
+          br =e.contentWindow.document.createElement("br");
+          td.appendChild(br);
+          tr.appendChild(td);
+        }
+        tbody.appendChild(tr);
+      }
+      table.appendChild(tbody);      
+      insertNodeAtSelection(e.contentWindow, table);
+    }
+  } else {
+    document.getElementById('edit').contentWindow.document.execCommand(this.id, false, null);
+  }
+}
+
+function Select(selectname)
+{
+  var cursel = document.getElementById(selectname).selectedIndex;
+  /* First one is always a label */
+  if (cursel != 0) {
+    var selected = document.getElementById(selectname).options[cursel].value;
+    document.getElementById('edit').contentWindow.document.execCommand(selectname, false, selected);
+    document.getElementById(selectname).selectedIndex = 0;
+  }
+  document.getElementById("edit").contentWindow.focus();
+}
+
+function dismisscolorpalette()
+{
+  document.getElementById("colorpalette").style.visibility="hidden";
+}
+
+function Start() {
+  document.getElementById('edit').contentWindow.document.designMode = "on";
+  try 
+  {
+    //document.getElementById('edit').contentWindow.document.execCommand("undo", false, null);
+  }  
+  catch (e) 
+  {
+    alert("This demo is not supported on your level of Mozilla.");
+  }
+
+  InitToolbarButtons();
+  document.addEventListener("mousedown", dismisscolorpalette, true);
+  document.getElementById("edit").contentWindow.document.addEventListener("mousedown", dismisscolorpalette, true);
+  document.addEventListener("keypress", dismisscolorpalette, true);
+  document.getElementById("edit").contentWindow.document.addEventListener("keypress", dismisscolorpalette, true);
+
+  <%-- DMJ_MOD --%>
+  document.getElementById('edit').contentWindow.document.body.innerHTML = document.weblogEntryFormEx.text.value;
+}
+
+</script>
+
+<%-- DMJ_MOD  commented this out, Roller provides the body
+</head> 
+<body onLoad="Start()">
+<h2>Please note that the changing of text format (Heading, Paragraph, etc.) will only function
+properly on a 1.3b build dated after January 26, 2003. Thanks.</h2>
+--%>
+
+<table bgcolor="#C0C0C0" id="toolbar1">
+<tr>
+<td>
+
+<%-- DMJ_MOD change image paths to add images/midas --%>
+
+<div class="imagebutton" id="cut"><img class="image" src='<c:url value="/images/midas/cut.gif"/>' alt="Cut" title="Cut"></div>
+</td>
+<td>
+<div class="imagebutton" id="copy"><img class="image" src='<c:url value="/images/midas/copy.gif"/>' alt="Copy" title="Copy"></div>
+</td>
+<td>
+<div class="imagebutton" id="paste"><img class="image" src='<c:url value="/images/midas/paste.gif"/>' alt="Paste" title="Paste"></div>
+<td>
+</td>
+<td>
+</td>
+<td>
+<div class="imagebutton" id="undo"><img class="image" src='<c:url value="/images/midas/undo.gif"/>' alt="Undo" title="Undo"></div>
+</td>
+<td>
+<div class="imagebutton" id="redo"><img class="image" src='<c:url value="/images/midas/redo.gif"/>' alt="Redo" title="Redo"></div>
+</td>
+
+<td>
+</td>
+<td>
+<div style="left: 10;" class="imagebutton" id="createlink"><img class="image" src='<c:url value="/images/midas/link.gif"/>' alt="Insert Link" title="Insert Link"></div>
+</td>
+<td>
+</td>
+<td>
+<div style="left: 10;" class="imagebutton" id="createtable"><img class="image" src='<c:url value="/images/midas/table.gif"/>' alt="Insert Table" title="Insert Table"></div>
+</td>
+</tr>
+</table>
+<br>
+<table bgcolor="#C0C0C0" id="toolbar2">
+<tr>
+<td>
+<select id="formatblock" onchange="Select(this.id);">
+
+  <option value="<p>">Normal</option>
+  <option value="<p>">Paragraph</option>
+  <option value="<h1>">Heading 1 <h1></option>
+  <option value="<h2>">Heading 2 <h2></option>
+  <option value="<h3>">Heading 3 <h3></option>
+  <option value="<h4>">Heading 4 <h4></option>
+
+  <option value="<h5>">Heading 5 <h5></option>
+  <option value="<h6>">Heading 6 <h6></option>
+  <option value="<address>">Address <ADDR></option>
+  <option value="<pre>">Formatted <pre></option>
+</select>
+</td>
+<td>
+<select id="fontname" onchange="Select(this.id);">
+  <option value="Font">Font</option>
+
+  <option value="Arial">Arial</option>
+  <option value="Courier">Courier</option>
+  <option value="Times New Roman">Times New Roman</option>
+</select>
+</td>
+<td>
+<select unselectable="on" id="fontsize" onchange="Select(this.id);">
+  <option value="Size">Size</option>
+  <option value="1">1</option>
+
+  <option value="2">2</option>
+  <option value="3">3</option>
+  <option value="4">4</option>
+  <option value="5">5</option>
+  <option value="6">6</option>
+  <option value="7">7</option>  
+
+</select>
+</td>
+
+<%-- DMJ_MOD change image paths to add images/midas --%>
+
+<td>
+<div class="imagebutton" id="bold"><img class="image" src='<c:url value="/images/midas/bold.gif"/>' alt="Bold" title="Bold"></div>
+</td>
+<td>
+<div class="imagebutton" id="italic"><img class="image" src='<c:url value="/images/midas/italic.gif"/>' alt="Italic" title="Italic"></div>
+</td>
+<td>
+<div class="imagebutton" id="underline"><img class="image" src='<c:url value="/images/midas/underline.gif"/>' alt="Underline" title="Underline"></div>
+</td>
+<td>
+</td>
+<td>
+<div style="left: 10;" class="imagebutton" id="forecolor"><img class="image" src='<c:url value="/images/midas/forecolor.gif"/>' alt="Text Color" title="Text Color"></div>
+</td>
+<td>
+
+<div style="left: 40;" class="imagebutton" id="hilitecolor"><img class="image" src='<c:url value="/images/midas/backcolor.gif"/>' alt="Background Color" title="Background Color"></div>
+</td>
+<td>
+</td>
+<td>
+<div style="left: 10;" class="imagebutton" id="justifyleft"><img class="image" src='<c:url value="/images/midas/justifyleft.gif"/>' alt="Align Left" title="Align Left"></div>
+</td>
+<td>
+<div style="left: 40;" class="imagebutton" id="justifycenter"><img class="image" src='<c:url value="/images/midas/justifycenter.gif"/>' alt="Center" title="Center"></div>
+</td>
+<td>
+<div style="left: 70;" class="imagebutton" id="justifyright"><img class="image" src='<c:url value="/images/midas/justifyright.gif"/>' alt="Align Right" title="Align Right"></div>
+</td>
+<td>
+</td>
+<td>
+<div style="left: 10;" class="imagebutton" id="insertorderedlist"><img class="image" src='<c:url value="/images/midas/orderedlist.gif"/>' alt="Ordered List" title="Ordered List"></div>
+
+</td>
+<td>
+<div style="left: 40;" class="imagebutton" id="insertunorderedlist"><img class="image" src='<c:url value="/images/midas/unorderedlist.gif"/>' alt="Unordered List" title="Unordered List"></div>
+</td>
+<td>
+</td>
+<td>
+<div style="left: 10;" class="imagebutton" id="outdent"><img class="image" src='<c:url value="/images/midas/outdent.gif"/>' alt="Outdent" title="Outdent"></div>
+</td>
+<td>
+<div style="left: 40;" class="imagebutton" id="indent"><img class="image" src='<c:url value="/images/midas/indent.gif"/>' alt="Indent" title="Indent"></div>
+</td>
+</tr>
+</table>
+<br />
+<%-- DMJ_MOD added weblogs/ to colors.html path --%>
+<iframe width="250" height="170" id="colorpalette" src="weblog/colors.html" style="visibility:hidden; position: absolute;"></iframe>
+<iframe id="edit" width="95%" height="350px"></iframe>
+<script type="text/javascript">
+function viewsource(source)
+{
+  if (source) {
+    var html = document.createTextNode(document.getElementById('edit').contentWindow.document.body.innerHTML);
+    document.getElementById('edit').contentWindow.document.body.innerHTML = "";
+    document.getElementById('edit').contentWindow.document.body.appendChild(html);
+    document.getElementById("toolbar1").style.visibility="hidden";
+    document.getElementById("toolbar2").style.visibility="hidden";  
+  } else {
+    var html = document.getElementById('edit').contentWindow.document.body.ownerDocument.createRange();
+    html.selectNodeContents(document.getElementById('edit').contentWindow.document.body);
+    document.getElementById('edit').contentWindow.document.body.innerHTML = html.toString();
+    document.getElementById("toolbar1").style.visibility="visible";
+    document.getElementById("toolbar2").style.visibility="visible";  
+  }
+}
+
+function usecss(source)
+{
+  document.getElementById('edit').contentWindow.document.execCommand("useCSS", false, !(source));  
+}
+
+function readonly(source)
+{
+    document.getElementById('edit').contentWindow.document.execCommand("readonly", false, !(source));  
+}
+</script>
+<br />
+<input type="checkbox" onclick="viewsource(this.checked)">
+View HTML Source</input>
+<input checked type="checkbox" onclick="usecss(this.checked)">
+Use CSS</input>
+<input type="checkbox" onclick="readonly(this.checked)">
+Read only</input>
+
+<br />
+<br />
+

Added: incubator/roller/branches/roller_1.x/web/weblog/editor-rte.jsp
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_1.x/web/weblog/editor-rte.jsp?rev=327589&view=auto
==============================================================================
--- incubator/roller/branches/roller_1.x/web/weblog/editor-rte.jsp (added)
+++ incubator/roller/branches/roller_1.x/web/weblog/editor-rte.jsp Fri Oct 21 14:27:36 2005
@@ -0,0 +1,55 @@
+
+<%-- This page is designed to be included in edit-weblog.jsp --%>
+
+<%@ include file="/taglibs.jsp" %>
+
+<html:hidden property="text" />
+
+<script type="text/javascript" src="richtext.js" ></script>
+<script type="text/javascript">
+<!--
+    function postWeblogEntry(publish)
+    {
+	updateRTE('rte1');
+        document.weblogEntryFormEx.text.value = document.weblogEntryFormEx.rte1.value;
+        if (publish) document.weblogEntryFormEx.publishEntry.value = "true";
+        document.weblogEntryFormEx.submit();
+    }
+   // Usage: initRTE(imagesPath, includesPath, cssFile)
+   initRTE("images/", "<%= request.getContextPath() %>/editor/", "");
+//-->
+</script>
+<noscript><p><b>Javascript must be enabled to use this form.</b></p></noscript>
+
+
+<br />
+<script language="JavaScript" type="text/javascript">
+<!--
+//Usage: writeRichText(fieldname, html, width, height, buttons, readOnly)
+writeRichText('rte1', document.weblogEntryFormEx.text.value, '95%', 300, true, false);
+//-->
+</script>
+
+        <script type="text/javascript">
+            <!--
+            if (getCookie("editorSize") != null) {
+                document.weblogEntryFormEx.text.rows = getCookie("editorSize");
+            }
+            -->
+        </script>
+       <div style="float:right">
+          <script type="text/javascript">
+            <!--
+            function changeSize(e,num) {
+                e.form.text.rows = e.form.text.rows + num;
+                var expires = new Date();
+                expires.setTime(expires.getTime() + 24 * 90 * 60 * 60 * 1000); // sets it for approx 90 days.
+                setCookie("editorSize",e.form.rte1.rows,expires);
+            }
+            -->
+          </script>
+          <!-- Add buttons to make this textarea taller or shorter
+          <input type="button" name="taller" value=" &darr; " onclick="changeSize(this,5)" />
+          <input type="button" name="shorter" value=" &uarr; " onclick="changeSize(this,-5)" />
+           -->
+       </div>
\ No newline at end of file

Added: incubator/roller/branches/roller_1.x/web/weblog/editor-text-js.jsp
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_1.x/web/weblog/editor-text-js.jsp?rev=327589&view=auto
==============================================================================
--- incubator/roller/branches/roller_1.x/web/weblog/editor-text-js.jsp (added)
+++ incubator/roller/branches/roller_1.x/web/weblog/editor-text-js.jsp Fri Oct 21 14:27:36 2005
@@ -0,0 +1,269 @@
+
+<%-- This page is designed to be included in edit-weblog.jsp --%>
+
+<%@ include file="/taglibs.jsp" %>
+<script type="text/javascript" src="<html:rewrite page="/theme/scripts/xmlp.js"/>"></script>
+<script type="text/javascript">
+<!--  
+var expires = new Date();
+expires.setTime(expires.getTime() + 24 * 30 * 60 * 60 * 1000); // sets it for approx 30 days.
+
+function doParse() {
+    var parser = new XMLParser();
+    var form = document.forms[0];
+    // wrap contents of textarea with root element
+    var xml = "<root>" + form.text.value + "</root>";
+    try 
+    {
+        parser.parse(xml);
+    }
+    catch (e) 
+    {
+        var msg = "Invalid XML: " + e.message;
+            msg += "\n\nClick OK to continue posting with (possibly) invalid markup.";
+        var ans = confirm(msg);
+        if (ans) 
+        {
+            return true;
+        } 
+        else 
+        {
+            return false;
+        }
+    }
+    return true;
+}
+
+function postWeblogEntry(publish)
+{   
+    if (document.getElementById("parseXML").checked) {
+        setCookie("parseXML","true",expires,"/");
+        if (doParse()) {        
+            if (publish) {
+                document.weblogEntryFormEx.publishEntry.value = "true";
+            }
+            document.weblogEntryFormEx.submit();
+        }
+    } else {
+        deleteCookie("parseXML");
+        if (publish) {
+            document.weblogEntryFormEx.publishEntry.value = "true";
+        }
+        document.weblogEntryFormEx.submit();
+    }
+}
+
+function htmlcode(theform,htmltag,prompttext) 
+{
+	// insert <x>yyy</x> style markup
+	inserttext = prompt(tag_prompt+"\n<"+htmltag+">xxx</"+htmltag+">",'');
+	if ((inserttext != null) && (inserttext != "")) {
+		theform.text.value += "<"+htmltag+">"+inserttext+"</"+htmltag+"> ";
+	}
+	theform.text.focus();
+}
+
+// *******************************************************
+
+function dolist(theform) {
+// inserts list with option to have numbered or alphabetical type
+	listtype = prompt(list_type_prompt, "");
+	if ((listtype == "b") || (listtype == "1")) {
+		if (listtype == "b") {
+			thelist = "<ul>\n";
+			listend = "</ul> ";
+		}
+		else {
+			if (listtype == "1") {
+				thelist = "<ol>\n";
+				listend = "</ol> ";
+			}
+		}
+	}
+	else {
+		thelist = "<ul>\n";
+		listend = "</ul> ";
+	}
+	listentry = "initial";
+	while ((listentry != "") && (listentry != null)) {
+		listentry = prompt(list_item_prompt, "");
+		if ((listentry != "") && (listentry != null))
+			thelist = thelist+"<li>"+listentry+"\n";
+		}
+	theform.text.value += thelist+listend;
+	theform.text.focus();
+}
+
+// *******************************************************
+
+function htmllink(theform,thetag) {
+// inserts named url or email link
+	linktext = prompt(link_text_prompt,"");
+	var prompttext;
+	if (thetag == "url") {
+		thetype = "a href=\"";
+		prompt_text = link_url_prompt;
+		prompt_contents = "http://";
+	}
+	else {
+		thetype = "a href=mailto:";
+		prompt_text = link_email_prompt;
+		prompt_contents = "";
+	}
+	linkurl = prompt(prompt_text,prompt_contents);
+	if ((linkurl != null) && (linkurl != "")) {
+		theform.text.value += "<"+thetype+linkurl+"\">"+linktext+"</a> ";
+	}
+	else {
+		theform.text.value += "<"+thetype+linkurl+"\">"+linktext+"</a> ";
+	}
+	theform.text.focus();
+}
+
+// *******************************************************
+
+function insertimage(theform) {
+	//insert <img src="" alt="" align=""> tag
+	imgsrc = prompt(img_src_prompt,"http://");
+	imgalt = prompt(img_alt_prompt,"");
+	imgalign = prompt(img_align_prompt,"");
+	if (imgalign == "r") imgalign = "right";
+	if (imgalign == "l") imgalign = "left";
+	theform.text.value += "<img src=\""+imgsrc+"\" alt=\""+imgalt+"\" align=\""+imgalign+"\">";
+	theform.text.focus();
+}
+
+// *******************************************************
+
+function insertmedia(theform,type) {
+	if (type == 'img') {
+		//insert <img src="" alt="" align=""> tag'
+		imgsrc = "";
+		imgsrc = theform.imagefile.options[theform.imagefile.selectedIndex].value;
+		imgsrc2 = ""
+		for (i=0; i < imgsrc.length; i++) {
+			if (imgsrc.charAt(i) == "'") {
+				imgsrc2 = imgsrc2 + "\"";
+			}
+			else {
+				imgsrc2 = imgsrc2 + imgsrc.charAt(i);
+			}
+		}
+		imgalt = prompt(img_alt_prompt,"");
+		imgalign = prompt(img_align_prompt,"");
+		if (imgalign == "r") imgalign = "right";
+		if (imgalign == "l") imgalign = "left";
+		theform.text.value += "<img src="+imgsrc2+" alt=\""+imgalt+"\" align=\""+imgalign+"\">";
+	}
+	else {
+		//type must be 'other'
+		linksrc = "";
+		linksrc = theform.mediafile.options[theform.mediafile.selectedIndex].value;
+		linktext = "";
+		linktext = prompt("Please enter the text for this link: ");
+		theform.text.value += "<a href="+linksrc+">"+linktext+"</a>";
+	}
+	theform.text.focus();
+}
+
+// *******************************************************
+// the following are the text prompts for buttons etc.
+// DO NOT ADD LINE-BREAKS BETWEEN THE "...." QUOTES!
+
+// MINI-HELP MESSAGES
+
+b_text = "Insert BOLD text";
+i_text = "Insert ITALIC text";
+u_text = "Insert UNDERLINED text";
+
+url_text = "Insert a hyperlink into your message";
+email_text = "Insert an email-link into your message";
+img_text = "Insert an image into your message";
+
+list_text = "Insert an ordered list into your message";
+quote_text = "Insert a quote into your message";
+
+// TEXT FOR POP-UP PROMPTS
+
+tag_prompt = "Enter the text to be formatted:";
+
+font_formatter_prompt = "Enter the text to be formatted with the specified";
+
+img_src_prompt = "Enter the url to the image you would like displayed";
+img_alt_prompt = "Enter the text to appear while the image is downloading";
+img_align_prompt = "Image alignment: leave blank for no alignment, r for right, l for left";
+
+link_text_prompt = "Enter the text to be displayed for the link (optional)";
+link_url_prompt = "Enter the full URL for the link";
+link_email_prompt = "Enter the email address for the link";
+
+list_type_prompt = "What type of list do you want? Enter '1' for a numbered list, enter 'b' for an bulleted list.";
+list_item_prompt = "Enter a list item.\nLeave the box empty or press 'Cancel' to complete the list.";
+// -->
+</script>
+
+<div>
+<div style="text-align: right; width: 95%">
+<div style="float: left">
+<input type="checkbox" name="parseXML" id="parseXML" 
+    onclick="parseXML()"> <label for="parseXML">Validate as XML</label>
+<script type="text/javascript">
+<!--
+// determine user's parse XML preference and check box appropriately
+if (getCookie("parseXML") == "true") {
+    document.getElementById('parseXML').checked = true;
+} else {
+    document.getElementById('parseXML').checked = false;
+}
+// -->
+</script>
+</div>
+
+<input type="button" name="bold" value="bold" tabindex="3"
+    onclick="htmlcode(weblogEntryFormEx,'strong',tag_prompt)" />
+<input type="button" name="italics" value="italics" tabindex="4"
+    onclick="htmlcode(weblogEntryFormEx,'em',tag_prompt)" />
+<input type="button" name="underline" value="underline" tabindex="5"
+    onclick="htmlcode(weblogEntryFormEx,'u',tag_prompt)" />
+<input type="button" name="list" value="list" tabindex="6"
+    onclick="dolist(weblogEntryFormEx)" />
+<input type="button" name="url" value="link" tabindex="7"
+    onclick="htmllink(weblogEntryFormEx,'url')" />
+<input type="button" name="email" value="e-mail" 
+    onclick="htmllink(weblogEntryFormEx,'email')" tabindex="8" />
+<input type="button" name="image" value="image" tabindex="9"
+    onclick="insertimage(weblogEntryFormEx)" />
+</div>
+
+
+<html:textarea property="text" cols="75" rows="20" 
+    styleId="text" style="width: 95%" tabindex="2"/> 
+</div>
+
+        <script type="text/javascript">
+            <!--
+            if (getCookie("editorSize") != null) {
+                document.weblogEntryFormEx.text.rows = getCookie("editorSize");
+            }
+            -->
+        </script>
+
+       <div style="float:right">
+          <script type="text/javascript">
+            <!--
+            function changeSize(e,num) {
+                e.form.text.rows = e.form.text.rows + num;
+                var expires = new Date();
+                expires.setTime(expires.getTime() + 24 * 90 * 60 * 60 * 1000); // sets it for approx 90 days.
+                setCookie("editorSize",e.form.text.rows,expires);
+            }
+            -->
+          </script>
+          <!-- Add buttons to make this textarea taller or shorter -->
+          <input type="button" name="taller" value=" &darr; " onclick="changeSize(this,5)" />
+          <input type="button" name="shorter" value=" &uarr; " onclick="changeSize(this,-5)" />
+       </div>
+
+
+
+

Added: incubator/roller/branches/roller_1.x/web/weblog/editor-text.jsp
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_1.x/web/weblog/editor-text.jsp?rev=327589&view=auto
==============================================================================
--- incubator/roller/branches/roller_1.x/web/weblog/editor-text.jsp (added)
+++ incubator/roller/branches/roller_1.x/web/weblog/editor-text.jsp Fri Oct 21 14:27:36 2005
@@ -0,0 +1,50 @@
+
+<%-- This page is designed to be included in edit-weblog.jsp --%>
+
+<%@ include file="/taglibs.jsp" %>
+
+<script type="text/javascript">
+<!--
+function postWeblogEntry(publish)
+{
+    if (publish)
+        document.weblogEntryFormEx.publishEntry.value = "true";
+    document.weblogEntryFormEx.submit();
+}
+// -->
+</script>
+
+        <script type="text/javascript">
+            <!--
+            if (getCookie("editorSize") != null) {
+                document.weblogEntryFormEx.text.rows = getCookie("editorSize");
+            }
+            -->
+        </script>
+
+<html:textarea property="text" cols="75" rows="20" style="width: 100%" tabindex="2"/>
+
+        <script type="text/javascript">
+            <!--
+            if (getCookie("editorSize") != null) {
+                document.weblogEntryFormEx.text.rows = getCookie("editorSize");
+            }
+            -->
+        </script>
+
+       <div style="float:right">
+          <script type="text/javascript">
+            <!--
+            function changeSize(e,num) {
+                e.form.text.rows = e.form.text.rows + num;
+                var expires = new Date();
+                expires.setTime(expires.getTime() + 24 * 90 * 60 * 60 * 1000); // sets it for approx 90 days.
+                setCookie("editorSize",e.form.text.rows,expires);
+            }
+            -->
+          </script>
+          <!-- Add buttons to make this textarea taller or shorter -->
+          <input type="button" name="taller" value=" &darr; " onclick="changeSize(this,5)" />
+          <input type="button" name="shorter" value=" &uarr; " onclick="changeSize(this,-5)" />
+       </div>
+

Added: incubator/roller/branches/roller_1.x/web/weblog/editor-wiki-js.jsp
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_1.x/web/weblog/editor-wiki-js.jsp?rev=327589&view=auto
==============================================================================
--- incubator/roller/branches/roller_1.x/web/weblog/editor-wiki-js.jsp (added)
+++ incubator/roller/branches/roller_1.x/web/weblog/editor-wiki-js.jsp Fri Oct 21 14:27:36 2005
@@ -0,0 +1,187 @@
+
+<%-- This page is designed to be included in edit-weblog.jsp --%>
+
+<%@ include file="/taglibs.jsp" %>
+
+<script type="text/javascript">
+<!--
+function postWeblogEntry(publish)
+{
+    if (publish)
+        document.weblogEntryFormEx.publishEntry.value = "true";
+    document.weblogEntryFormEx.submit();
+}
+function convertTextArea(textArea) {
+    $text = textArea.value;
+    
+    // first off, __xxx__ to strong
+    $text = $text.replace(/__([^_]*)__/g, "<strong>$1</strong>");
+
+    // next, ''xxx'' to emphasis
+    $text = $text.replace(/''([^']*)''/g, "<em>$1</em>");
+
+    // next, {{{xxx}}} to pre
+    $text = $text.replace(/\{\{\{([^\}]*)\}\}\}/g, "</p><pre>$1</pre><p>");
+
+    // next, {{xxx}} to tt
+    $text = $text.replace(/\{\{([^\}]*)\}\}/g, "<tt>$1</tt>");
+
+    // next, ==xxx== to underline
+    $text = $text.replace(/==([^=]*)==/g, "<u>$1</u>");
+
+    // newlines
+    $text = $text.replace(/-----*/g, "<hr/>");
+
+    // --xxx-- to strike-through
+    $text = $text.replace(/--([^-]*)--/g, "<s>$1</s>");
+
+    // headings
+    $text = $text.replace(/^!!!!!(.*)$/mg, "</p><h5>$1</h5><p>");
+    $text = $text.replace(/^!!!!(.*)$/mg, "</p><h4>$1</h4><p>");
+    $text = $text.replace(/^!!!(.*)$/mg, "</p><h3>$1</h3><p>");
+    $text = $text.replace(/^!!(.*)$/mg, "</p><h2>$1</h2><p>");
+    $text = $text.replace(/^!(.*)$/mg, "</p><h1>$1</h1><p>");
+
+    // Need to be able to handle nested *'s and #'s. Need to 
+    // know when to put the ul and ol in, and when to close.
+    // Hard in regexp, so I'm doing it by hand 
+    $text = handleList($text, "\*", "<ul>", "</ul>");
+    $text = handleList($text, "\#", "<ol>", "</ol>");
+
+    // table |..|..|.. is a row, and ||..||..||.. is a header
+    // another one that will be hard to do in pure regexp
+    $text = handleTable($text);
+
+    // def lists:   ;term:definition to dl/dt/dd
+
+    // img before http means we can have links made of images
+    // img://....|...\s becomes image with alt or title
+    $text = $text.replace(/\[img(:\/\/[^|]*)\|([^\]]*)\]/g, "<img src='http$1' title='$2'>");
+    // img://....\s becomes an image
+    $text = $text.replace(/\[img(:\/\/[^\]]*)\]/g, "<img src='http$1'/>");
+    // http://....|...\s becomes an anchor
+    $text = $text.replace(/\[(http:\/\/[^|]*)\|([^\]]*)\]/g, "<a href='$1'>$2</a>");
+    $text = $text.replace(/\[(http:\/\/[^\]]*)\]/g, "<a href='$1'>$1</a>");
+
+    // textareas often stick a newline at the end 
+    $text = $text.replace(/<br\/>\n+$/, "<br/>");
+
+    // lastly, all newlines to br's
+    while($text.match(/\n\n/)) {
+        $text = $text.replace(/\n\n/g, "<br/><br/>\n");
+    }
+    $text = $text.replace(/\\$/m, "<br/>\n");
+
+    // TODO:
+    //  automatic <a href for http://  ?? hard. Use [...|,,,] instead?
+    //  automatic <img src for img://
+    //  ability to escape any matching block with \
+    //  use this for comments?
+    //  add help
+    
+    textArea.value = $text;
+}
+
+function handleList($page, $char, $start, $end) {
+    if(! $page.match("\n"+$char)) {
+        return $page;
+    }
+    $regexpCharCount = "[^"+$char+"]";
+    $regexpCharReplace = "^"+$char+"*\s";
+    $lines = $page.split("\n");
+    $text = "";
+    $depth = 0;
+    for($i=0; $i<$lines.length; $i++) {
+        $line = $lines[$i];
+        $count = $line.search($regexpCharCount);
+        if($count < 1) { 
+            if($depth != 0) {
+                for($j=0; $j<$depth; $j++) {
+                    $text += $end;
+                }
+	        // hack for css
+	        if($depth == 1) {
+		    $text += "<p>";
+		}
+                $depth = 0;
+            }
+            $text += $line;
+            $text += "\n";
+            continue;
+        }
+        $line = $line.substring($count+1);
+        if($depth < $count) {
+	    // hack for css
+	    if($depth == 0) {
+	        $text += "</p>";
+	    }
+	    while($depth < $count) {
+                $depth++;
+                $text += $start+"\n";
+	    }
+	    $text += "<li>"+$line+"</li>\n";
+            continue;
+        }
+        if($depth > $count) {
+            while($depth > $count) {
+                $depth--;
+                $text += $end+"\n";
+	    }
+            $text += "<li>"+$line+"</li>\n";
+            continue;
+        }
+        $text += "<li>"+$line+"</li>\n";
+    }
+    if($depth != 0) {
+        for($j=0; $j<$depth; $j++) {
+            $text += $end;
+        }
+	// hack for css
+        $text += "<p>";
+    }
+    return $text;
+}
+
+function handleTable($page) {
+    if(! $page.match(/^\|/)) {
+        return $page;
+    }   
+    $lines = $page.split("\n");
+    $text = "";
+    $inTable = false; 
+    for($i=0; $i<$lines.length; $i++) {
+        $line = $lines[$i];
+        if($line.match(/^\|\|/)) { 
+            if(!$inTable) {
+                $text += "<table border='1'>\n";
+                $inTable = true;
+            }
+            $line = $line.replace(/^\|\|([^\|]*)/, "<tr><th>$1");
+            $line = $line.replace(/\|\|([^\|]*)/g, "</th><th>$1");
+            $line = $line + "</th></tr>\n";
+        } else
+        if($line.match(/^\|/)) {
+            if(!$inTable) {
+                $text += "<table border='1'>\n";
+                $inTable = true;
+            }
+            $line = $line.replace(/^\|([^\|]*)/, "<tr><td>$1");
+            $line = $line.replace(/\|([^\|]*)/g, "</td><td>$1");
+            $line = $line + "</td></tr>\n";
+        } else { 
+            if($inTable) {
+                $text += "</table>\n";
+                $inTable = false;
+            }
+        }
+        $text += $line+"\n";
+    }
+    return $text;
+}
+
+// -->
+</script>
+
+(<a href="weblog/help-wiki-js.html" alt="Wiki-js help" target="_blank">wiki-js help</a>)
+
+<html:textarea property="text" cols="75" rows="20" style="width: 100%" tabindex="2" onchange="convertTextArea(this)"/>

Added: incubator/roller/branches/roller_1.x/web/weblog/export-entries.jsp
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_1.x/web/weblog/export-entries.jsp?rev=327589&view=auto
==============================================================================
--- incubator/roller/branches/roller_1.x/web/weblog/export-entries.jsp (added)
+++ incubator/roller/branches/roller_1.x/web/weblog/export-entries.jsp Fri Oct 21 14:27:36 2005
@@ -0,0 +1,62 @@
+<%@ include file="/taglibs.jsp" %><%@ include file="/theme/header.jsp" %>
+<%@ page import="org.roller.presentation.BasePageModel" %>
+<%
+BasePageModel model = (BasePageModel)request.getAttribute("model");
+%>
+
+<h1><fmt:message key="weblogEntryExport.title" /></h1>
+
+<roller:StatusMessage/>
+
+<html:form action="/editor/exportEntries" method="post" focus="title">
+
+    <html:hidden name="method" property="method" value="export"/>
+
+    <h3><fmt:message key="weblogEntryQuery.section.dateRange" /></h3>
+    
+    <div class="row">
+        <label style="width:20%; float:left; text-align:right; padding: 2px" for="startDateString">
+           <fmt:message key="weblogEntryQuery.label.startDate" />:
+        </label>
+        <roller:Date property="startDateString" dateFormat='<%= model.getShortDateFormat() %>' />
+    </div>
+    
+    <div class="row">
+        <label style="width:20%; float:left; text-align:right; padding: 2px" for="endDateString">
+           <fmt:message key="weblogEntryQuery.label.endDate" />:
+        </label>
+        <roller:Date property="endDateString" dateFormat='<%= model.getShortDateFormat() %>' />
+    </div>
+    
+    <h3><fmt:message key="weblogEntryQuery.section.format" /></h3>
+    
+    <div class="row">
+        <label style="width:20%; float:left; text-align:right; padding: 2px" for="fileBy">
+            <fmt:message key="weblogEntryQuery.label.separateEntries" />:
+        </label>
+        <select name="fileBy">
+            <option><fmt:message key="weblogEntryQuery.label.day" /></option>
+            <option selected="selected"><fmt:message key="weblogEntryQuery.label.month" /></option>
+            <option><fmt:message key="weblogEntryQuery.label.year" /></option>
+        </select>
+    </div>
+    
+    <div class="row">
+        <label style="width:20%; float:left; text-align:right; padding: 2px" for="exportFormat">
+            <fmt:message key="weblogEntryQuery.label.exportTo" />:
+        </label>
+        <input type="radio" name="exportFormat" value="Atom" checked="checked">
+            <fmt:message key="weblogEntryQuery.label.atom" /></input>
+        <br />
+        <input type="radio" name="exportFormat" value="RSS" >
+            <fmt:message key="weblogEntryQuery.label.rss" /></input>
+    </div>
+    
+    <div class="buttonBox">
+        <input type="button" name="post" 
+            value='<fmt:message key="weblogEntryQuery.button.export" />' onclick="submit()" />
+    </div>
+    
+</html:form>
+
+<%@ include file="/theme/footer.jsp" %>

Added: incubator/roller/branches/roller_1.x/web/weblog/help-wiki-js.html
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_1.x/web/weblog/help-wiki-js.html?rev=327589&view=auto
==============================================================================
--- incubator/roller/branches/roller_1.x/web/weblog/help-wiki-js.html (added)
+++ incubator/roller/branches/roller_1.x/web/weblog/help-wiki-js.html Fri Oct 21 14:27:36 2005
@@ -0,0 +1,40 @@
+<h4>Help on Wiki-JS editor</h4>
+<p>You are currently using the wiki-js editor, a very lightweight javascript system to allow text to be written using the wiki style (based on JSPWiki format). </p>
+<p>There are some major advantages to wiki-js; </p>
+<ol>
+<li>Firstly it does not change anything as far as the database or Roller is concerned.  It changes your text to HTML before your eyes, so as far as the server is concerned, you wrote HTML. This also means you don't have to worry about older entries that are in HTML and conditional rendering. </li>
+<li>It still allows HTML. This is in no way an attempt to stop you using HTML, just a shorthand. </li>
+<li>You can edit the HTML it creates. Wiki-js appears to be good at not abusing existing HTML. </li>
+<li>It works with the CSS. Various tags are the same level as 'p' tags, and as Roller puts your entry in a 'p' tag they break the CSS. Wiki-js closes the 'p' and re-opens it after these tags. </li>
+<li>Lastly, it is easy to code and develop. No compiling, no deploying, no submitting even; though preview can help sometimes. </li>
+</ol>
+<p>The biggest negative is that it's not a Wiki system. Just a wiki-style markup shorthand. </p>
+
+<p>Here's a concise explanation of the markup: </p>
+<table border="1">
+<tr><td>Bold</td><td>__foo__</td><td> is <strong>foo</strong>; ie) bold, though it uses the strong tag. </td></tr>
+<tr><td>Italic</td><td>''foo''</td><td> is <em>foo</em>; ie) italic, though it uses the em tag. </td></tr>
+<tr><td>Underlined</td><td>==foo==</td><td> is <u>foo</u>; ie) underlined. </td></tr>
+<tr><td>Strike-through</td><td>--foo--</td><td> is <s>foo</s>; ie) striked-through. </td></tr>
+<tr><td>Source block</td><td>{{{foo}}}</td><td> is for source code, using the pre tag; ie) <pre>foo</pre></td></tr>
+<tr><td>Source inline</td><td>{{foo}}</td><td> is <tt>foo</tt>; ie) source code, using the tt tag. </td></tr>
+<tr><td>Newlines</td><td>2 or more newlines become 2 or more br tags</td><td> this means that your newlines (return/enter) should be maintained, but only when you really mean it. </td></tr>
+<tr><td>Headings</td><td>! is h1, !! is h2, .., !!!!! is h5</td><td>everything else on that line becomes the heading. </td></tr>
+<tr><td>Lists</td><td>* for ul and # for ol</td><td>** is a nested ul etc. Must be at the start of a line. </td></tr>
+<tr><td>Forced breaks</td><td>\ on end of line forces extra newline</td><td>Should rarely be needed. </td></tr>
+<tr><td>Line separators</td><td>4+ '-' characters</td><td>hr tag. </td></tr>
+<tr><td>Tables</td><td>|text|more text|</td><td> Makes a table. Double bars for a table heading. </td></tr>
+<tr><td>Anchors</td><td>[http://www.rollerweblogger.org/|Roller]</td><td><a href='http://www.rollerweblogger.org/'>Roller</a></td></tr>
+<tr><td>Images</td><td>[img://www.google.com/images/logo.gif|Google Logo]</td><td><img src='http://www.google.com/images/logo.gif' title='Google Logo'></td></tr>
+<tr><td>Anchor'd Images</td><td>[http://www.google.com/|[img://www.google.com/images/logo.gif|Goto Google]]</td><td><a href='http://www.google.com/'><img src='http://www.google.com/images/logo.gif' title='Google Logo'></a></td></tr>
+<tr><td>CSS friendly</td><td>lists, pre, p and h* all at the same level</td><td>wiki-js inserts p's which helps with CSS oddities a lot. </td></tr>
+</table>
+<p>If you want to look at the code, hit view-source on the blog entry page and find the handleTable, handleList and convertTextArea javascript functions. </p>
+<p>Some todo's</p>
+<ol>
+<li>&lt;!-- wiki-js-off --&gt; at the top of the page that turns off parsing. Will be useful if it's being irritating. </li>
+<li>JSPWiki-clone: ;term:def        Defines 'term' with 'def'.  Use this with empty 'term' to make short comments. This is a dl/dt/dd list. </li>
+<li>JSPWiki-clone: {{ should remove any newlines between the tt tags. </li>
+<li>Headings to include named anchor so you can link directly to them. Needs to know name of blog though, so that might be a bit of a hack</li>
+<li>Allow http://www.foo.com|Blah for ones that don't need a space in the title. Same for images. </li>
+</ol>

Added: incubator/roller/branches/roller_1.x/web/weblog/import-entries.jsp
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_1.x/web/weblog/import-entries.jsp?rev=327589&view=auto
==============================================================================
--- incubator/roller/branches/roller_1.x/web/weblog/import-entries.jsp (added)
+++ incubator/roller/branches/roller_1.x/web/weblog/import-entries.jsp Fri Oct 21 14:27:36 2005
@@ -0,0 +1,32 @@
+<%@ include file="/taglibs.jsp" %><%@ include file="/theme/header.jsp" %>
+
+<h1><fmt:message key="weblogEntryImport.title" /></h1>
+
+<roller:StatusMessage/>
+
+<html:form action="/editor/importEntries" method="post" focus="title">
+
+    <html:hidden name="method" property="method" value="importEntries"/>
+
+    <h3><fmt:message key="weblogEntryImport.selectXML" /></h3>
+
+    <table cellspacing="0" cellpadding="0" class="edit">
+        <tr>
+            <td><fmt:message key="weblogEntryImport.XMLFile" /><br />
+            <html:select property="importFileName" size="1" >
+                <html:options property="xmlFiles" />
+            </html:select>
+            </td>
+        </tr>
+
+        <tr>
+            <td class="buttonBox" colspan="1">
+                <input type="button" name="post" value='<fmt:message key="weblogEntryImport.button.import" />'
+                        onclick="submit()" />
+            </td>
+        </tr>
+    </table>
+
+</html:form>
+
+<%@ include file="/theme/footer.jsp" %>
\ No newline at end of file

Added: incubator/roller/branches/roller_1.x/web/weblog/referers.jsp
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_1.x/web/weblog/referers.jsp?rev=327589&view=auto
==============================================================================
--- incubator/roller/branches/roller_1.x/web/weblog/referers.jsp (added)
+++ incubator/roller/branches/roller_1.x/web/weblog/referers.jsp Fri Oct 21 14:27:36 2005
@@ -0,0 +1,42 @@
+<%@ include file="/taglibs.jsp" %><%@ include file="/theme/header.jsp" %>
+
+<%-- Form allows deleting of referers --%>
+<h1><fmt:message key="referers.todaysReferers" /></h1>
+<html:form action="/editor/referers" method="post">
+<input type="hidden" name="method" value="delete" />
+
+<%-- Table of referers, with check box for each --%>
+<table width="75%" class="rollertable" >
+    <tr class="rollertable">
+        <th class="rollertable"></th>
+        <th class="rollertable"><fmt:message key="referers.url" /></th>
+        <th class="rollertable"><fmt:message key="referers.hits" /></th>
+    </tr>
+ 
+    <c:forEach var="referer" items="${referers}">
+        <tr>
+            <td class="rollertable">
+                <input type="checkbox" name="id" value='<c:out value="${referer.id}" />' />
+            </td>
+            <td class="rollertable">               
+               <c:out value="${referer.displayUrl}" escapeXml="false" />
+            </td>
+            <td class="rollertable"><c:out value="${referer.dayHits}" /></td>
+        </tr>
+    </c:forEach> 
+    
+</table>
+
+<br />
+<input type="submit" value='<fmt:message key="referers.deleteSelected" />' /></input>
+</html:form>
+
+<%-- Form allows reset of day hits --%>
+<h2><fmt:message key="referers.hitCounters" /></h2>
+<p><fmt:message key="referers.hits" />: <c:out value="${pageHits}"/></p>
+<html:form action="/editor/referers" method="post">
+    <input type="hidden" name="method" value="reset" />
+    <input type="submit" value='<fmt:message key="referers.reset" />' /></input>
+</html:form>
+
+<%@ include file="/theme/footer.jsp" %>

Added: incubator/roller/branches/roller_1.x/web/weblog/spellcheck-entry.jsp
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_1.x/web/weblog/spellcheck-entry.jsp?rev=327589&view=auto
==============================================================================
--- incubator/roller/branches/roller_1.x/web/weblog/spellcheck-entry.jsp (added)
+++ incubator/roller/branches/roller_1.x/web/weblog/spellcheck-entry.jsp Fri Oct 21 14:27:36 2005
@@ -0,0 +1,86 @@
+<!-- spellcheck-entry.jsp -->
+<%@ include file="/taglibs.jsp" %>
+<%@ page import="org.roller.model.RollerSpellCheck,com.swabunga.spell.event.SpellCheckEvent" %>
+<%@ page import="org.apache.commons.lang.StringUtils,java.util.*" %>
+<%@ include file="/theme/header.jsp" %>
+<script type="text/javascript">
+<!--
+    function postWeblogEntry(activeForm,publish)
+    {
+        if (publish)
+            activeForm.publishEntry.value = "true";
+        activeForm.submit();
+    }
+    
+    function spellcheck(activeForm)
+    {
+        activeForm.method.value = "spellCheck";
+        postWeblogEntry(activeForm);
+    }
+// -->
+</script>
+
+<roller:StatusMessage/>
+
+<html:form action="/editor/weblog" method="post">
+    <bean:define id="text" name="weblogEntryFormEx" 
+          property="text" type="java.lang.String" />
+    <input type="hidden" name="method" value="spellCheck"/>
+    <input type="hidden" name="publishEntry" value="false" />
+    <html:hidden property="title" />
+    <html:hidden property="categoryId" />
+    <html:hidden property="dateString" />
+    <html:hidden property="hours" />
+    <html:hidden property="minutes" />
+    <html:hidden property="seconds" />
+    <html:hidden property="day"/>
+    <html:hidden property="id"/>
+    <html:hidden property="anchor"/>
+<h3>Use Spell Check Results</h3>
+
+    <table class="rTable" width="90%" border="1">
+        <tr class="rEvenTr">
+            <td class="rTd"><font style='font-size: 14px; vertical-align: middle; line-height= 18px; font-family: verdana, sans-serif;'><%= escapeText %></font></td>
+        </tr>
+    </table>
+    <br />
+    <input type="button" name="post" value="Post to Weblog" 
+            onClick="javascript:postWeblogEntry(this.form,true)" />
+    &nbsp; &nbsp;
+    <input type="button" name="draft" value="Save as Draft" 
+            onClick="javascript:postWeblogEntry(this.form)" />      
+
+</html:form>
+
+<h2>Or</h2>
+
+<html:form action="/weblog" method="post" focus="title">
+
+<h3>Edit Manually</h3>
+    <input type="hidden" name="method" value="update"/>
+    <input type="hidden" name="publishEntry" value="false" />
+    <html:hidden property="title" />
+    <html:hidden property="categoryId" />
+    <html:hidden property="dateString" />
+    <html:hidden property="hours" />
+    <html:hidden property="minutes" />
+    <html:hidden property="seconds" />
+    <html:hidden property="day"/>
+    <html:hidden property="id"/>
+    <html:hidden property="anchor"/>
+    <html:textarea property="text" cols="75" rows="20" style="width: 90%"/> 
+    <br />
+    <br />
+    <input type="button" name="post" value="Post to Weblog" 
+            onClick="javascript:postWeblogEntry(this.form, true)" />
+    &nbsp; &nbsp;
+    <input type="button" name="draft" value="Save as Draft" 
+            onClick="javascript:postWeblogEntry(this.form)" />      
+    &nbsp; &nbsp;
+    <input type="button" name="spelling" value="Recheck" 
+            onClick="javascript:spellcheck(this.form)" />  
+
+</html:form>
+
+    
+<%@ include file="/theme/footer.jsp" %>
\ No newline at end of file

Added: incubator/roller/branches/roller_1.x/web/website/CommonPingTargetDeleteOK.jsp
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_1.x/web/website/CommonPingTargetDeleteOK.jsp?rev=327589&view=auto
==============================================================================
--- incubator/roller/branches/roller_1.x/web/website/CommonPingTargetDeleteOK.jsp (added)
+++ incubator/roller/branches/roller_1.x/web/website/CommonPingTargetDeleteOK.jsp Fri Oct 21 14:27:36 2005
@@ -0,0 +1,36 @@
+<%@ include file="/taglibs.jsp" %><%@ include file="/theme/header.jsp" %>
+
+<br />
+<h1><fmt:message key="pingTarget.confirmRemoveTitle" /></h1>
+
+<p/>
+<fmt:message key="pingTarget.confirmCommonRemove" />
+<p/>
+
+<table>
+<tr><td><fmt:message key="pingTarget.name" />&nbsp;&nbsp;</td><td><b><c:out value="${pingTargetForm.name}" /></b></td></tr>
+<tr><td><fmt:message key="pingTarget.pingUrl" />&nbsp;&nbsp;</td><td><b><c:out value="${pingTargetForm.pingUrl}" /></b></td></tr>
+</table>
+
+<table>
+<tr>
+<td>
+<html:form action="/admin/commonPingTargets" method="post">
+    <html:hidden property="method" value="deleteConfirmed" />
+    <html:hidden property="id" />
+    <div class="control">
+       <input type="submit" value='<fmt:message key="pingTarget.removeOK" />' />
+    </div>
+</html:form>
+</td>
+<td>
+<html:form action="/admin/commonPingTargets" method="post">
+    <!-- Results in returning to the view on common ping targets. -->
+    <div class="control">
+       <input type="submit" value='<fmt:message key="pingTarget.cancel" />' />
+    </div>
+</html:form>
+</td>
+</tr>
+</table>
+<%@ include file="/theme/footer.jsp" %>

Added: incubator/roller/branches/roller_1.x/web/website/CommonPingTargetEdit.jsp
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_1.x/web/website/CommonPingTargetEdit.jsp?rev=327589&view=auto
==============================================================================
--- incubator/roller/branches/roller_1.x/web/website/CommonPingTargetEdit.jsp (added)
+++ incubator/roller/branches/roller_1.x/web/website/CommonPingTargetEdit.jsp Fri Oct 21 14:27:36 2005
@@ -0,0 +1,29 @@
+<%@ include file="/taglibs.jsp" %><%@ include file="/theme/header.jsp" %>
+
+<br />
+<h1><fmt:message key="pingTarget.pingTarget" /></h1>
+
+<br />
+<html:form action="/admin/commonPingTargets" method="post" focus="name">
+    <html:hidden property="method" value="save" />
+    <html:hidden property="id" />
+
+    <div class="formrow">
+       <label for="name" class="formrow"><fmt:message key="pingTarget.name" /></label>
+       <html:text property="name" size="30" maxlength="30" />
+    </div>
+
+    <div class="formrow">
+       <label for="pingUrl" class="formrow"><fmt:message key="pingTarget.pingUrl" /></label>
+       <html:text property="pingUrl" size="100" maxlength="255" />
+    </div>
+
+    <p/>
+    <div class="formrow">
+       <label for="" class="formrow">&nbsp;</label>
+       <input type="submit" value='<fmt:message key="pingTarget.save" />' />
+    </div>
+
+</html:form>
+
+<%@ include file="/theme/footer.jsp" %>

Added: incubator/roller/branches/roller_1.x/web/website/CommonPingTargets.jsp
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_1.x/web/website/CommonPingTargets.jsp?rev=327589&view=auto
==============================================================================
--- incubator/roller/branches/roller_1.x/web/website/CommonPingTargets.jsp (added)
+++ incubator/roller/branches/roller_1.x/web/website/CommonPingTargets.jsp Fri Oct 21 14:27:36 2005
@@ -0,0 +1,71 @@
+<%@ page import="org.roller.presentation.RollerRequest"%>
+<%@ include file="/taglibs.jsp" %><%@ include file="/theme/header.jsp" %>
+
+<br />
+<h1><fmt:message key="commonPingTargets.commonPingTargets" /></h1>
+
+<p/>
+<fmt:message key="commonPingTargets.explanation"/>
+<p/>
+
+<table class="rollertable">
+
+    <%-- Headings --%>
+    <tr class="rollertable">
+        <th class="rollertable" width="20%%"><fmt:message key="pingTarget.name" /></th>
+        <th class="rollertable" width="70%"><fmt:message key="pingTarget.pingUrl" /></th>
+        <th class="rollertable" width="5%"><fmt:message key="pingTarget.edit" /></th>
+        <th class="rollertable" width="5%"><fmt:message key="pingTarget.remove" /></th>
+    </tr>
+
+    <%-- Listing of current common targets --%>
+    <c:forEach var="pingTarget" items="${pingTargets}" >
+        <roller:row oddStyleClass="rollertable_odd" evenStyleClass="rollertable_even">
+
+            <td class="rollertable">
+               <str:truncateNicely lower="15" upper="20" ><c:out value="${pingTarget.name}" /></str:truncateNicely>
+            </td>
+
+            <td class="rollertable">
+                <str:truncateNicely lower="70" upper="75" ><c:out value="${pingTarget.pingUrl}" /></str:truncateNicely>
+            </td>
+
+            <td class="rollertable" align="center">
+               <roller:link page="/admin/commonPingTargets.do">
+                   <roller:linkparam
+                       id="<%= RollerRequest.PINGTARGETID_KEY %>"
+                       name="pingTarget" property="id" />
+                   <roller:linkparam
+	                   id="method" value="editSelected" />
+                   <img src='<c:url value="/images/Edit16.png"/>' border="0"
+                        alt="<fmt:message key="pingTarget.edit" />" />
+               </roller:link>
+            </td>
+
+            <td class="rollertable" align="center">
+               <roller:link page="/admin/commonPingTargets.do">
+                   <roller:linkparam
+	                   id="<%= RollerRequest.PINGTARGETID_KEY %>"
+	                   name="pingTarget" property="id" />
+                   <roller:linkparam
+	                   id="method" value="deleteSelected" />
+                   <img src='<c:url value="/images/Remove16.gif"/>' border="0"
+                        alt="<fmt:message key="pingTarget.remove" />" />
+               </roller:link>
+            </td>
+
+        </roller:row>
+    </c:forEach>
+
+</table>
+
+<p/>
+<html:form action="/admin/commonPingTargets" method="post">
+    <div class="control">
+       <html:hidden property="method" value="addNew" />
+       <input type="submit" value='<fmt:message key="pingTarget.addNew"/>' />
+    </div>
+</html:form>
+<p/>
+
+<%@ include file="/theme/footer.jsp" %>

Added: incubator/roller/branches/roller_1.x/web/website/Maintenance.jsp
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_1.x/web/website/Maintenance.jsp?rev=327589&view=auto
==============================================================================
--- incubator/roller/branches/roller_1.x/web/website/Maintenance.jsp (added)
+++ incubator/roller/branches/roller_1.x/web/website/Maintenance.jsp Fri Oct 21 14:27:36 2005
@@ -0,0 +1,23 @@
+<%@ include file="/taglibs.jsp" %><%@ include file="/theme/header.jsp" %>
+
+<h1><fmt:message key="maintenance.title" /></h1>
+    
+<html:form action="/editor/maintenance" method="post">
+
+    <input type="hidden" name="method" value="" />
+
+    <fmt:message key="maintenance.prompt.index" /><br />
+    <input type="submit" value='<fmt:message key="maintenance.button.index" />' 
+    		  onclick="this.form.method.value='index'" />
+    	<br />	  
+    	<br />	  
+    		  
+    <fmt:message key="maintenance.prompt.flush" /><br />
+    <input type="submit" value='<fmt:message key="maintenance.button.flush" />' 
+    		  onclick="this.form.method.value='flushCache'" />
+    		  
+</html:form>
+
+<%@ include file="/theme/footer.jsp" %>
+
+