File: Upgrades.html

package info (click to toggle)
squishdot 1.5.0-3
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 1,016 kB
  • ctags: 440
  • sloc: python: 2,829; makefile: 56; sh: 23
file content (349 lines) | stat: -rw-r--r-- 15,156 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1" />
<title>Squishdot Documentation</title>
<style type="text/css">
body {
    background-color: #F4F4F4;
    color: #000000;
}
a:link {
    color: #0066cc;
}
a:visited {
    color: #006666;
}
#sections {
    font-family: Arial, Helvetica, sans-serif;
    font-size: 0.9em;
}
#sections ul.sub {
    padding-left: 10px;
}
.small {
    font-size: 0.8em;
}
</style>
</head>
<body>
<table border="0" cellspacing="2" cellpadding="8" width="99%" summary="Squishdot documentation">
<tr>
    <td colspan="2">
        <h2>Squishdot Documentation</h2>
    </td>
</tr>
<tr>	  
    <td rowspan="10" valign="top" width="15%">
        <strong>Sections</strong>
        <ul id="sections">
            <li><a href="http://www.squishdot.org">Squishdot Home</a></li>
            <li><a href="index.html#intro">Introduction</a></li>
            <li><a href="index.html#features">Features</a></li>
            <li><a href="http://www.squishdot.org/Download">Download</a></li>
            <li><a href="index.html#install">Installation</a>
                <ul class="sub">
                    <li><a href="Security.html">Security</a></li>
                    <li><a href="Upgrades.html">Upgrade Notes</a></li>
                </ul>
            </li>
            <li><a href="index.html#support">Support</a></li>
            <li><a href="http://www.squishdot.org/Subscribe">Mailing List</a></li>
            <li><a href="index.html#versions">Squishdot Versioning</a>
                <ul class="sub">    
                    <li><a href="Changes.html">Changes</a></li>
                    <li><a href="Credits.html">Credits</a></li>
                    <li><a href="file:///usr/share/doc/squishdot/copyright">License</a></li>
                </ul>
            </li>
        </ul>
    </td>
    <td>
        <p><em>To use the Updaters, you will need to install the UpdateSupport product.<br />
            This can be downloaded from <a href="http://www.zope.org/Members/chrisw/UpdateSupport">here</a>,
            where you will also find some documentation.<br /> See the README.TXT file in
            the Updaters folder of the Squishdot distribution for more help.</em></p>

        <h2>Upgrading to Squishdot 1.5.0</h2>
        <ul>
            <li>Run the 1-4-x_1-5-0.py updater.</li>
        </ul>
        <p>
        <strong>NB:</strong> Please make sure you upgrade to Squishdot 1.5.0 
        <em>before</em> upgrading to Zope 2.6.0!
        </p>
        
        <h2>Upgrading to Squishdot 1.4.0</h2>
        <ul>
            <li>Run the 1-3-0_1-4-0.py updater.</li>
            <li>in the <tt>mail_html</tt> method of any Squishdot Sites, change:<br />
                <tt>&lt;dtml-var absolute_url&gt;/cancelNotify</tt><br />
                to<br />
                <tt>&lt;dtml-var "aq_parent.absolute_url()"&gt;/cancelNotify</tt>
            </li>
            <li>If you are using the 'Plain' demo as a base, in <code>previewPosting</code>
                change:<br />
                <tt>&lt;dtml-let msgstr=validatePosting</tt><br />
                to<br />
                <tt>&lt;dtml-let msgstr=validatePosting&gt;</tt>
            </li>
        </ul>


        <h2>Upgrading to Squishdot 1.3.0</h2>

        <ul>
            <li>Run the 1-2-x_1-3-0.py updater.</li>
            <li>in the <tt>mail_html</tt> method of any Squishdot Sites, change:<br />
                <pre>
&lt;dtml-if summary&gt;&lt;dtml-if "meta_type=='Article'"&gt;
 &lt;dtml-var "html2text(_.string.join(summary,'\n'))"&gt;
&lt;/dtml-if&gt;&lt;/dtml-if&gt;
&lt;dtml-var "html2text(_.string.join(body,'\n'))"&gt;
</pre><br />
                to<br />
                <pre>
&lt;dtml-var plain_text&gt;
</pre></li>
            <li>in the <tt>previewPosting</tt> method of any Squishdot Sites, change:<br />
                <pre>
&lt;dtml-unless skipvalid&gt;
&lt;dtml-if "meta_type == 'Squishdot Site'"&gt;
&lt;dtml-let msgstr=validateArticle&gt;
&lt;dtml-if msgstr&gt;
&lt;dtml-return "showError(_.None,_,title='Data Missing',message=msgstr,action=REQUEST['URL1'] + ''/previewPosting'')"&gt;
&lt;/dtml-if&gt;
&lt;/dtml-let&gt;
&lt;dtml-else&gt;
&lt;dtml-let msgstr=validateComment&gt;
&lt;dtml-if msgstr&gt;
&lt;dtml-return "showError(_.None,_,title='Data Missing',message=msgstr,action=REQUEST['URL1'] + ''/previewPosting'')"&gt;
&lt;/dtml-if&gt;
&lt;/dtml-let&gt;
&lt;/dtml-if&gt;
&lt;/dtml-unless&gt;
</pre>
                to<br />
                <pre>
&lt;dtml-unless skipvalid&gt;
&lt;dtml-let msgstr=validatePosting&gt;  
&lt;dtml-if "msgstr[1]"&gt;
&lt;dtml-return "showError(_.None,_,values=msgstr[0],title='Data Missing',
                 message=msgstr[1],action=REQUEST['URL1'] + '/previewPosting')"&gt;
&lt;/dtml-if&gt;
&lt;/dtml-let&gt;
&lt;/dtml-unless&gt;
</pre>
                </li>
                <li>Replace any occurences of  <code>&lt;dtml-var SCRIPT_NAME&gt;</code> with 
                    <code>&amp;dtml-site_url;</code>. This is likely to be present in:
                    <ul>
                        <li>site_footer</li>
                        <li>posting_html</li>
                        <li>showSearchResults</li>
                        <li>searchForm</li>
                        <li>index_html</li>
                    </ul>
                </li>
            </ul>
            <h2>Upgrading to Squishdot 1.2.1</h2>
            <ul>
                <li>Run the 1-1-0_1-2-0.py updater.</li>
                <li>in the <tt>index_html</tt> method of any Squishdot Sites, change:
                    <pre>
&lt;A href="&lt;dtml-if relurl&gt;&lt;dtml-var site_url&gt;&lt;/dtml-if&gt;&lt;dtml-var urlname url_quote&gt;"&gt;&lt;dtml-var name&gt;&lt;/A&gt;
</pre>
                to<br />
                <pre>
&lt;A href="&lt;dtml-if relurl&gt;&lt;dtml-var site_url&gt;&lt;/dtml-if&gt;&lt;dtml-var urlname&gt;"&gt;&lt;dtml-var name&gt;&lt;/A&gt;
</pre>
                </li>
                <li>In the <tt>previewPosting</tt> method, change all occurences of <br />
                    <tt>"validateComment(this(),REQUEST=REQUEST)"</tt><br />
                    to <br />
                    <tt>validateComment</tt><br />
                    (NB: no quotes)
                </li>
                <li>In the <tt>previewPosting</tt> method, change all occurences of <br />
                    <tt>"validateArticle(this(),REQUEST=REQUEST)"</tt><br />
                    to <br />
                    <tt>validateArticle</tt><br />
                    (NB: no quotes)
                </li>
                <li>Change the second line of the <tt>validateComment</tt> method 
                    so it reads as follows:<br />
                    <tt>&lt;dtml-unless "REQUEST.encoding=='Plain'"&gt;</tt>
                </li>
                <li>Change the second line of the <tt>validateArticle</tt> 
                    method so it reads as follows:<br />
                    <tt>&lt;dtml-unless "REQUEST.encoding=='Plain'"&gt;</tt>
                </li>
            </ul>
            
            <h2>Upgrading to Squishdot 1.1.0</h2>
            <ul>
                <li>Run the 1-0-0_1-1-0.py updater.</li>
                <li>In the <tt>previewPosting</tt> method, change all occurences of <br />
                    <tt>validateComment(REQUEST=REQUEST)</tt><br />
                    to <br />
                    <tt>validateComment(this(),REQUEST=REQUEST)</tt>
                </li>
                <li>In the <tt>previewPosting</tt>  method, change all occurences of<br />
                    <tt>validateArticle(REQUEST=REQUEST)</tt><br />
                    to<br />
                    <tt>validateArticle(this(),REQUEST=REQUEST)</tt>
                </li>
                <li>Insert the following lines at the start of the <tt>validateComment</tt> method:<br />
                    <pre>
&lt;dtml-unless "encoding=='Plain'"&gt;
 &lt;dtml-in "['title','author','email','body']"&gt;
  &lt;dtml-call "REQUEST.set(_['sequence-item'],html2safehtml(REQUEST.get(_['sequence-item'],'')))"&gt;
 &lt;/dtml-in&gt;
&lt;/dtml-unless&gt;
</pre></li>
                <li>Insert the following lines at the start of the 
                    <tt>validateArticle</tt> method:<br />
                    <pre>
&lt;dtml-unless "encoding=='Plain'"&gt;
 &lt;dtml-in "['title','author','email','summary','subject','dept','body']"&gt;
  &lt;dtml-call "REQUEST.set(_['sequence-item'],html2safehtml(REQUEST.get(_['sequence-item'],'')))"&gt;
 &lt;/dtml-in&gt;
&lt;/dtml-unless&gt;
</pre></li>
            </ul>
            
            <h2>Upgrading to Squishdot 1.0.0</h2>
            <ul>
                <li>Run the 0-7-x_1-0-0.py updater.</li>
                <li>Replace the contents of the <code>mail_html</code>
                    dtml method with the contents of this file 
                    <a href="mail_html_07x.txt">mail_html</a>.
                </li>
            </ul>
            
            <h2>Upgrading to Squishdot 0.7.x</h2>
            <p>There's a small change you need to make in the following 
               DTML methods of each pre-0.7.0 Squishdot Site object:</p>
            <ul>
                <li><code>posting_html</code></li>
                <li><code>previewPosting</code></li>
                <li><code>addPostingForm</code></li>
            </ul>
            <p>Whenever the expression  <code>&lt;dtml-var expr="thread[0]"&gt;</code> 
               occurs, you need to replace it with <code>&lt;dtml-var expr="getThread(0)" &gt;</code>
            </p>
            <p>If you start getting KeyErrors on thread_path, it might be worth clicking 
               on <code>Re-Catalog All Postings</code> on the <code>Options</code> manage tab.
            </p>
            
            <h2>Upgrading to Squishdot 0.6.0</h2>
            <p>Assuming you are upgrading from 0.5.0, there's nothing you need 
               to do to old Squishdot Sites!
            </p>
            
            <h2>Upgrading to Squishdot 0.5.0</h2>
            <p>Assuming you are upgrading from 0.4.1, you don't 
               <em>need</em> to do anything...
            </p>
            <p>However, if you want to use the new Plain Text and Structured Text stuff, 
                you'll need to change any exisiting Squishdot Sites you have as follows:
            </p>

            <ul>
                <li>Replace all occurence of<br />
                    <tt>&lt;dtml-if body&gt;&lt;dtml-in body&gt;&lt;dtml-var sequence-item&gt;&lt;/dtml-in body&gt;&lt;/dtml-if body&gt;</tt> (or similar such things)<br />
                    with<br />
                    <tt>&lt;dtml-var showBody&gt;</tt>
                </li>
                <li>Replace all occurence of<br />
                    <tt>&lt;dtml-if summary&gt;&lt;dtml-in summary&gt;&lt;dtml-var sequence-item&gt;&lt;/dtml-in summary&gt;&lt;/dtml-if summary&gt;</tt> (or similar such things)<br />
                    with<br />
                    <tt>&lt;dtml-var showSummary&gt;</tt>
                </li>
                <li>Add the following in the appropriate places on your
                    <code>addPostingForm</code> method:<br />
                    <pre>
    &lt;SELECT NAME="encoding"&gt;
    &lt;dtml-in "[['HTML','HTML'],['STX','Structured Text'],['Plain','Plain Text']]"&gt;
      &lt;OPTION VALUE="&lt;dtml-var "_.getitem('sequence-item',0)[0]" html_quote&gt;" 
      &lt;dtml-if "encoding==_.getitem('sequence-item',0)[0]"&gt;SELECTED&lt;/dtml-if&gt;&gt;
      &lt;dtml-var "_.getitem('sequence-item',0)[1]" html_quote&gt;
      &lt;/OPTION&gt;
    &lt;/dtml-in&gt;
    &lt;/SELECT&gt;
</pre>
                </li>
                <li>Add the following in the appropriate places on your 
                    <code>previewPosting</code> method:<br />
                    <pre>
    &lt;SELECT NAME="encoding"&gt;
     &lt;dtml-in "[['HTML','HTML'],['STX','Structured Text'],['Plain','Plain Text']]"&gt;
       &lt;OPTION VALUE="&lt;dtml-var "_.getitem('sequence-item',0)[0]" html_quote&gt;" 
       &lt;dtml-if "REQUEST.get('encoding','HTML')==_.getitem('sequence-item',0)[0]"&gt;SELECTED&lt;/dtml-if&gt;&gt;
       &lt;dtml-var "_.getitem('sequence-item',0)[1]" html_quote&gt;
       &lt;/OPTION&gt;
     &lt;/dtml-in&gt;
    &lt;/SELECT&gt;
</pre></li>
                <li>Finally, add the following to the form in the 
                    <code>showError</code> method:<br />
                    <tt>&lt;INPUT TYPE="HIDDEN" NAME="encoding" VALUE="&lt;dtml-var "REQUEST['encoding']" html_quote missing&gt;"&gt;</tt>
                </li>
            </ul>
            
            <h2>Upgrading to Squishdot 0.4.1</h2>
            <p>Assuming you are upgrading from 0.4.0, 
               please do the following for each of your Squishdot objects:
            </p>

            <ul>
                <li>Change the two calls to showError in the <code>previewPosting</code> 
                    dtml method so they start start "showError(_.None,_,title" 
                    instead of "showError(REQUEST=REQUEST,title".
                </li>
                <li>You may also wish to create a new <code>Plain</code> demo site 
                    and copy mail_html and addPostingForm to replace those in any 
                    Squishdot objects created by a pre-0.4.1 version of Squishdot.
                </li>
            </ul>
            
            <h2>Upgrading to Squishdot 0.4.0</h2>
            <p>If you are upgrading from a previous version of Squishdot to 0.4.0, 
               please do the following for each of your Squishdot objects:
            </p>

            <ul>
                <li>Rename the <code>searchResults</code> dtml method to 
                    <code>showSearchResults</code>.
                </li>
                <li>In the <code>Postings</code> management tab, click on
                    <code>Update Indexing</code>.
                </li>
                <li>
                    <em>As an alternative to the above two steps, use the 0-3-x_0-4-x.py updater</em>
                </li>
                <li>Replace the contents of the <code>mail_html</code> dtml
                    method with the contents of either of the following:
                    <ul>
                        <li><a href="plain.txt">Plain</a> text mail notification.</li>
                        <li><a href="mime.txt">MIME</a> encoded mail notifcation.</li>
                    </ul>
                </li>
            </ul>
       </td>
</tr>
<tr>
    <td colspan="2" align="center">
        <a href="http://www.zope.org/Credits" target="_top">
            <img src="/usr/lib/zope/lib/python/App/www/zope_button.jpg" width="115" height="50" border="0" alt="Powered by Zope" />
        </a>
        &nbsp;&nbsp;
        <a href="http://squishdot.org">
            <img src="/usr/lib/zope/lib/python/Products/Squishdot/squishlogo.gif" alt="Squishdot Powered" border="1" width="75" height="50" />
        </a> 
    </td>
</tr>
</table>
</body>
</html>