forked from nuBuilder/nuBuilder
-
Notifications
You must be signed in to change notification settings - Fork 0
/
update.htm
465 lines (392 loc) · 10.7 KB
/
update.htm
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
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
<!doctype html>
<html>
<head>
<meta charset='utf-8'>
<meta name='viewport' content='width=device-width, initial-scale=1'>
<meta http-Equiv="Cache-Control" Content="no-cache" />
<meta http-Equiv="Pragma" Content="no-cache" />
<meta http-Equiv="Expires" Content="0" />
<title>nuBuilder Update</title>
<link rel="stylesheet" href="core/libs/bootstrap/bootstrap.min.css">
<link href='core/libs/fontawesome/css/fontawesome.min.css' rel='stylesheet'>
<style>*
{
margin: 0;
padding: 0
}
li{
margin: 10px 0;
}
html {
height: 100%
}
p {
color: grey
}
#heading_outside_nu
{
color: red
}
#heading {
color: #673AB7;
font-weight: normal
}
#msform {
text-align: center;
position: relative;
margin-top: 20px
}
#msform fieldset {
background: white;
border: 0 none;
border-radius: 0.5rem;
box-sizing: border-box;
width: 100%;
margin: 0;
padding-bottom: 20px;
position: relative
}
.form-card {
text-align: left
}
#msform fieldset:not(:first-of-type) {
display: none
}
#msform input,
#msform textarea {
padding: 8px 15px 8px 15px;
border: 1px solid #ccc;
border-radius: 0px;
margin-bottom: 25px;
margin-top: 2px;
width: 100%;
box-sizing: border-box;
font-family: montserrat;
color: #2C3E50;
background-color: #ECEFF1;
font-size: 16px;
letter-spacing: 1px
}
#msform input:disabled {
background: grey;
}
#msform .action-button[disabled]:hover {
background: red;
}
#msform input:focus,
#msform textarea:focus {
-moz-box-shadow: none !important;
-webkit-box-shadow: none !important;
box-shadow: none !important;
border: 1px solid #673AB7;
outline-width: 0
}
#msform .action-button {
width: 100px;
background: #673AB7;
font-weight: bold;
color: white;
border: 0 none;
border-radius: 0px;
cursor: pointer;
padding: 4px 5px;
margin: 10px 0px 10px 5px;
float: right;
font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
}
#msform .action-button:hover,
#msform .action-button:focus {
background-color: #311B92
}
#msform .action-button-previous {
width: 100px;
background: #616161;
font-weight: bold;
color: white;
border: 0 none;
border-radius: 0px;
cursor: pointer;
padding: 4px 5px;
margin: 10px 5px 10px 0px;
float: right;
font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
}
#msform .action-button-previous:hover,
#msform .action-button-previous:focus {
background-color: #000000
}
.card {
z-index: 0;
border: none;
position: relative
}
.fs-title {
font-size: 25px;
color: #673AB7;
margin-bottom: 15px;
font-weight: normal;
text-align: left
}
.purple-text {
color: #673AB7;
font-weight: normal
}
.steps {
font-size: 25px;
color: gray;
margin-bottom: 10px;
font-weight: normal;
text-align: right
}
.fieldlabels {
color: gray;
text-align: left
}
#progressbar {
margin-bottom: 30px;
overflow: hidden;
color: lightgrey
}
#progressbar .active {
color: #673AB7
}
#progressbar li {
list-style-type: none;
font-size: 15px;
width: 25%;
float: left;
position: relative;
font-weight: 400
}
#progressbar #backup:before {
font-family: FontAwesome;
content: "\f1c0"
}
#progressbar #download:before {
font-family: FontAwesome;
content: "\f0ed"
}
#progressbar #prepare:before {
font-family: FontAwesome;
content: "\f1c6"
}
#progressbar #update:before {
font-family: FontAwesome;
content: "\f058"
}
#progressbar li:before {
width: 50px;
height: 50px;
line-height: 45px;
display: block;
font-size: 20px;
color: #ffffff;
background: lightgray;
border-radius: 50%;
margin: 0 auto 10px auto;
padding: 2px
}
#progressbar li:after {
content: '';
width: 100%;
height: 2px;
background: lightgray;
position: absolute;
left: 0;
top: 25px;
z-index: -1
}
#progressbar li.active:before,
#progressbar li.active:after {
background: #673AB7
}
.progress {
height: 20px
}
.progress-bar {
background-color: #673AB7
}
.fit-image {
width: 100%;
object-fit: cover
}
</style>
<script type='text/javascript' src='core/libs/jquery/jquery-3.6.1.min.js'></script>
<script type='text/javascript' src='core/libs/bootstrap/bootstrap.bundle.min.js'></script>
<script type='text/javascript'>
$(document).ready(function() {
var p = window.frameElement;
if (p === null) {
$('#nulogo').show();
$('#heading_steps').show();
$('input[name ="next"]').prop('disabled', true);
$('#startupdateskip').prop('disabled', true);
} else {
$('#nulogo').remove();
$('#heading_outside_nu').remove();
}
var current_fs, next_fs, previous_fs; //fieldsets
var opacity;
var current = 1;
var steps = $("fieldset").length;
setProgressBar(current);
$(".next").click(function() {
if ($(this).attr('id') == 'startupdate' || $(this).attr('id') == 'startupdateskip') {
parent.nuSystemUpdate();
return;
}
current_fs = $(this).parent();
next_fs = $(this).parent().next();
//Add Class Active
$("#progressbar li").eq($("fieldset").index(next_fs)).addClass("active");
//show the next fieldset
next_fs.show();
//hide the current fieldset with style
current_fs.animate({
opacity: 0
}, {
step: function(now) {
// for making fielset appear animation
opacity = 1 - now;
current_fs.css({
'display': 'none',
'position': 'relative'
});
next_fs.css({
'opacity': opacity
});
},
duration: 500
});
setProgressBar(++current);
});
$(".previous").click(function() {
current_fs = $(this).parent();
previous_fs = $(this).parent().prev();
//Remove class active
$("#progressbar li").eq($("fieldset").index(current_fs)).removeClass("active");
//show the previous fieldset
previous_fs.show();
//hide the current fieldset with style
current_fs.animate({
opacity: 0
}, {
step: function(now) {
// for making fielset appear animation
opacity = 1 - now;
current_fs.css({
'display': 'none',
'position': 'relative'
});
previous_fs.css({
'opacity': opacity
});
},
duration: 500
});
setProgressBar(--current);
});
function setProgressBar(curStep) {
var percent = parseFloat(100 / steps) * curStep;
percent = percent.toFixed();
$(".progress-bar").css("width", percent + "%");
}
$(".submit").click(function() {
return false;
});
});
</script>
</head>
<body oncontextmenu='return false' class='snippet-body'>
<div class="container-fluid" style="width:100%">
<div class="row justify-content-center">
<div class="col-11 col-sm-9 col-md-7 col-lg-6 col-xl-5 text-center p-0 mb-2">
<div class="card px-0 pt-4 pb-0 mt-3 mb-3">
<h2 id="heading">nuBuilder Update</h2>
<center><img id="nulogo" style="display: none;" src="core/graphics/logo.png" width="171px" height="72px" alt="nuBuilder Forte"></center><br>
<p id="heading_steps">To update nuBuilder follow these steps:</p>
<p id="heading_outside_nu">Log in to nuBuilder, click the Update Button on the Database Tab of the Home Form to start the Update process.</p>
<form id="msform">
<!-- progressbar -->
<ul id="progressbar">
<li class="active" id="backup"><strong>Backup</strong></li>
<li id="download"><strong>Download</strong></li>
<li id="prepare"><strong>Prepare</strong></li>
<li id="update"><strong>Update</strong></li>
</ul>
<div class="progress">
<div class="progress-bar progress-bar-striped progress-bar-animated" role="progressbar" aria-valuemin="0" aria-valuemax="100"></div>
</div> <br>
<!-- fieldsets -->
<fieldset>
<div class="form-card">
<div class="row">
<div class="col-7">
<h2 class="fs-title">Database Backup</h2>
</div>
<div class="col-5">
<h2 class="steps">Step 1 - 4</h2>
</div>
</div>
<ul>
<li>Be sure to backup your database before doing this update.<br>You can export your nuBuilder database to a file by using phpMyAdmin or the mysqldump utility.<br>The Backup consists of a single file containing all nuBuilder tables and data (e.g. nubuilder4.sql) </li>
<li>Backup your nuBuilder files. E.g. add them to an archive 20201229_backup_nubuilder4.zip</li>
</ul>
</div> <input type="button" name="next" class="next action-button" value="Next" />
<input type="button" id="startupdateskip" style="width:240px" class="next action-button" value="Skip Wizard / Update now" />
</fieldset>
<fieldset>
<div class="form-card">
<div class="row">
<div class="col-7">
<h2 class="fs-title">Download Instructions:</h2>
</div>
<div class="col-5">
<h2 class="steps">Step 2 - 4</h2>
</div>
</div>
<ul>
<li>Pull the latest nuBuilder 4 files from either <a href="https://sourceforge.net/projects/nubuilder/files/latest/download" target="_blank">Sourceforge</a> or <a href="https://github.com/nuBuilder/nuBuilder-4.5/archive/master.zip" target="_blank">Github.</a></li>
<li>Alternatively, use a subversion client to obtain the latest files.</li>
</ul>
<ul>
</div> <input type="button" name="next" class="next action-button" value="Next" /> <input type="button" name="previous" class="previous action-button-previous" value="Previous" />
</fieldset>
<fieldset>
<div class="form-card">
<div class="row">
<div class="col-7">
<h2 class="fs-title">Delete & Unpack:</h2>
</div>
<div class="col-5">
<h2 class="steps">Step 3 - 4</h2>
</div>
<ul>
<li>Delete all files and folders in your nuBuilder folder except for nuconfig.php.</li>
<li>Extract the downloaded .zip file to your nuBuilder root folder. </li>
<ul>
</div></div> <input type="button" name="next" class="next action-button" value="Next" /> <input type="button" name="previous" class="previous action-button-previous" value="Previous" />
</fieldset>
<fieldset>
<div class="form-card">
<div class="row">
<div class="col-7">
<h2 class="fs-title">Update</h2>
</div>
<div class="col-5">
<h2 class="steps">Step 4 - 4</h2>
</div>
<ul>
<li>Now, you are ready to do the Update. If all goes well you should see a message: "You will need to log in again for the changes to take effect"</li>
<li>After updating, test your site carefully to verify there are not any issues.</li>
<li>The Github commit/change history information is valuable to see where something changed.</li>
</ul> <br>
The recommandation is to have a test environment to test changes before applying them to the production environment.
</div></div> <input type="button" id="startupdate" name="next" class="next action-button" value="Update" />
</fieldset>
</form>
</div>
</div>
</div>
</body>
</html>