Fixed bug #13766: Auto-increment does not work with driver odbc_mssql [adodb]
[Packages/TYPO3.CMS.git] / typo3 / sysext / rtehtmlarea / htmlarea / plugins / FindReplace / popups / find_replace.html
1 <!DOCTYPE html
2 PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
3 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
4 <html>
5 <!--
6 /***************************************************************
7 * Copyright notice
8 *
9 * (c) 2004 Cau guanabara <caugb@ibest.com.br>
10 * (c) 2005-2008 Stanislas Rolland <typo3(arobas)sjbr.ca>
11 * All rights reserved
12 *
13 * This script is part of the TYPO3 project. The TYPO3 project is
14 * free software; you can redistribute it and/or modify
15 * it under the terms of the GNU General Public License as published by
16 * the Free Software Foundation; either version 2 of the License, or
17 * (at your option) any later version.
18 *
19 * The GNU General Public License can be found at
20 * http://www.gnu.org/copyleft/gpl.html.
21 * A copy is found in the textfile GPL.txt and important notices to the license
22 * from the author is found in LICENSE.txt distributed with these scripts.
23 *
24 *
25 * This script is distributed in the hope that it will be useful,
26 * but WITHOUT ANY WARRANTY; without even the implied warranty of
27 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
28 * GNU General Public License for more details.
29 *
30 * This script is a modified version of a script published under the htmlArea License.
31 * A copy of the htmlArea License may be found in the textfile HTMLAREA_LICENSE.txt.
32 *
33 * This copyright notice MUST APPEAR in all copies of the script!
34 ***************************************************************/
35 /*
36 * Find and Replace Plugin for TYPO3 htmlArea RTE
37 *
38 * TYPO3 SVN ID: $Id$
39 */
40 -->
41 <head>
42 <title>Find and Replace</title>
43 <meta http-equiv="Content-Style-Type" content="text/css" />
44 <script type="text/javascript" src="../fr_engine.js"></script>
45 <script type="text/javascript">
46 /*<![CDATA[*/
47 <!--
48 var dialog = window.opener.HTMLArea.Dialog.FindReplace;
49 var editor;
50 var accepted = {
51 'fr_pattern' : true,
52 'fr_replacement' : true,
53 'fr_words' : true,
54 'fr_matchcase' : true,
55 'fr_replaceall' : true
56 };
57
58 function Init() {
59 editor = dialog.plugin.editor;
60 disable("fr_undo,fr_clear,fr_hiliteall", true);
61
62 var params = dialog.arguments;
63 if (params) {
64 document.getElementById('fr_pattern').value = params.fr_pattern;
65 document.getElementById('fr_replacement').focus();
66 } else {
67 document.getElementById('fr_pattern').focus();
68 }
69 window.opener.HTMLArea._addEvent(document, "keypress", onKeyPress);
70 if (window.opener.HTMLArea.is_gecko) {
71 window.opener.HTMLArea._addEvent(window, "unload", onCancel);
72 }
73 dialog.initialize();
74 if (HTMLArea.is_ie) {
75 HTMLArea._addEvent(window, "unload", onCancel);
76 }
77 };
78 function requestReplacement() {
79 if (!document.getElementById("fr_replacement").value && document.getElementById("fr_replaceall").checked) {
80 return confirm(dialog.plugin.localize("Inform a replacement word"));
81 }
82 clearDoc();
83 }
84 function onCancel() {
85 if (dialog) {
86 clearDoc();
87 HTMLArea._removeEvent(document, "keypress", onKeyPress);
88 HTMLArea._removeEvent(window, "unload", onCancel);
89 dialog.close();
90 }
91 return false;
92 };
93 function onOK() {
94 var required = {'fr_pattern' : dialog.plugin.localize("Enter the text you want to find")};
95 for (var i in required) {
96 var el = document.getElementById(i);
97 if (!el.value) {
98 alert(required[i]);
99 el.focus();
100 return false;
101 }
102 }
103
104 var param = {};
105 for (var i in accepted) {
106 var el = document.getElementById(i);
107 param[i] = (el.type == "checkbox") ? el.checked : el.value;
108 }
109 execSearch(param);
110 return false;
111 };
112 function onEscape(ev) {
113 if (!ev) var ev = window.event;
114 if (ev.keyCode == 27) {
115 return onCancel();
116 }
117 return true;
118 };
119 function onKeyPress (ev) {
120 if (!ev) var ev = window.event;
121 switch(ev.keyCode) {
122 case 13:
123 document.getElementById('fr_go').click();
124 document.getElementById('fr_pattern').focus();
125 break;
126 case 27:
127 return onCancel();
128 }
129 return true;
130 };
131 // -->
132 /*]]>*/
133 </script>
134 </head>
135 <body class="popupwin htmlarea-find-replace" onload="Init();">
136 <div id="content">
137 <div class="title">Find and Replace</div>
138 <form action="" method="get">
139 <fieldset>
140 <div>
141 <label for="fr_pattern">Search for:</label><br />
142 <input id="fr_pattern" type="text" size="35" onFocus="this.select();">
143 </div>
144 <div>
145 <label for="fr_replacement">Replace with:</label><br />
146 <input id="fr_replacement" type="text" size="35" onFocus="this.select();">
147 </div>
148 </fieldset>
149 <fieldset>
150 <legend>Options</legend>
151 <div>
152 <input id="fr_words" type="checkbox" checked="checked" onClick="clearDoc();">
153 <label for="fr_words" class="long-label">Whole words only</label>
154 </div>
155 <div>
156 <input id="fr_matchcase" type="checkbox" onClick="clearDoc();">
157 <label for="fr_matchcase" class="long-label">Case sensitive search</label>
158 </div>
159 <div>
160 <input id="fr_replaceall" type="checkbox" onClick="requestReplacement();">
161 <label for="fr_replaceall" class="long-label">Substitute all occurrences</label>
162 </div>
163 </fieldset>
164 <fieldset>
165 <legend>Actions</legend>
166 <div>
167 <button type="button" class="long-button" id="fr_clear" onClick="clearMarks();">Clear</button>
168 </div>
169 <div>
170 <button type="button" class="long-button" id="fr_hiliteall" onClick="hiliteAll();">Highlight</button>
171 </div>
172 <div>
173 <button type="button" class="long-button" id="fr_undo" onClick="resetContents();">Undo</button>
174 </div>
175 </fieldset>
176 <div class="buttons">
177 <button type="button" id="fr_go" onclick="return onOK();">Next</button>
178 <button type="button" name="cancel" onclick="return onCancel();">Done</button>
179 </div>
180 </form>
181 </div>
182 </body>
183 </html>