UNPKG

347 kBHTMLView Raw
1<!DOCTYPE html>
2
3<html lang="en">
4<head>
5 <meta charset="utf-8">
6 <meta name="viewport" content="width=device-width">
7 <title>CrossBrowdy API documentation Global</title>
8
9 <!--[if lt IE 9]>
10 <script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
11 <![endif]-->
12 <link type="text/css" rel="stylesheet" href="styles/sunlight.default.css">
13
14 <link type="text/css" rel="stylesheet" href="styles/site.cosmo.css">
15
16</head>
17
18<body style="min-width:800px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
19
20<div class="navbar navbar-default navbar-fixed-top ">
21<div class="container">
22 <div class="navbar-header">
23 <a class="navbar-brand" href="index.html">CrossBrowdy API documentation</a>
24 <button class="navbar-toggle" type="button" data-toggle="collapse" data-target="#topNavigation">
25 <span class="icon-bar"></span>
26 <span class="icon-bar"></span>
27 <span class="icon-bar"></span>
28 </button>
29 </div>
30 <div class="navbar-collapse collapse" id="topNavigation">
31 <ul class="nav navbar-nav">
32
33 <li class="dropdown">
34 <a href="namespaces.list.html" class="dropdown-toggle" data-toggle="dropdown">Namespaces<b class="caret"></b></a>
35 <ul class="dropdown-menu inline">
36 <li><a href="CB_Arrays.html">CB_Arrays</a></li><li><a href="CB_AudioDetector.html">CB_AudioDetector</a></li><li><a href="CB_baseSymbols.html">CB_baseSymbols</a></li><li><a href="CB_Client.html">CB_Client</a></li><li><a href="CB_Collisions.html">CB_Collisions</a></li><li><a href="CB_Configuration.html">CB_Configuration</a></li><li><a href="CB_Configuration.CrossBase.html">CB_Configuration.CrossBase</a></li><li><a href="CB_Configuration.CrossBrowdy.html">CB_Configuration.CrossBrowdy</a></li><li><a href="CB_Controllers.html">CB_Controllers</a></li><li><a href="CB_Controllers_Proprietary.html">CB_Controllers_Proprietary</a></li><li><a href="CB_Controllers_Proprietary.WII.html">CB_Controllers_Proprietary.WII</a></li><li><a href="CB_Controllers_Proprietary.WII_U.html">CB_Controllers_Proprietary.WII_U</a></li><li><a href="CB_Device.html">CB_Device</a></li><li><a href="CB_Device.AmbientLight.html">CB_Device.AmbientLight</a></li><li><a href="CB_Device.Battery.html">CB_Device.Battery</a></li><li><a href="CB_Device.Location.html">CB_Device.Location</a></li><li><a href="CB_Device.Motion.html">CB_Device.Motion</a></li><li><a href="CB_Device.Orientation.html">CB_Device.Orientation</a></li><li><a href="CB_Device.Proximity.html">CB_Device.Proximity</a></li><li><a href="CB_Device.Vibration.html">CB_Device.Vibration</a></li><li><a href="CB_Elements.html">CB_Elements</a></li><li><a href="CB_Events.html">CB_Events</a></li><li><a href="CB_Keyboard.html">CB_Keyboard</a></li><li><a href="CB_Keyboard.chars.html">CB_Keyboard.chars</a></li><li><a href="CB_Keyboard.extended.html">CB_Keyboard.extended</a></li><li><a href="CB_Keyboard.keys.html">CB_Keyboard.keys</a></li><li><a href="CB_Modules.html">CB_Modules</a></li><li><a href="CB_Mouse.html">CB_Mouse</a></li><li><a href="CB_Mouse.CursorImage.html">CB_Mouse.CursorImage</a></li><li><a href="CB_Net.html">CB_Net</a></li><li><a href="CB_Net.Fetch.html">CB_Net.Fetch</a></li><li><a href="CB_Net.REST.html">CB_Net.REST</a></li><li><a href="CB_Net.Sockets.html">CB_Net.Sockets</a></li><li><a href="CB_Net.Sockets.SockJS.html">CB_Net.Sockets.SockJS</a></li><li><a href="CB_Net.XHR.html">CB_Net.XHR</a></li><li><a href="CB_Pointer.html">CB_Pointer</a></li><li><a href="CB_Screen.html">CB_Screen</a></li><li><a href="CB_Speaker.html">CB_Speaker</a></li><li><a href="CB_Touch.html">CB_Touch</a></li>
37 </ul>
38 </li>
39
40 <li class="dropdown">
41 <a href="classes.list.html" class="dropdown-toggle" data-toggle="dropdown">Classes<b class="caret"></b></a>
42 <ul class="dropdown-menu inline">
43 <li><a href="CB_AudioFile.html">CB_AudioFile</a></li><li><a href="CB_AudioFile_API.AAPI.html">CB_AudioFile_API.AAPI</a></li><li><a href="CB_AudioFile_API.ACMP.html">CB_AudioFile_API.ACMP</a></li><li><a href="CB_AudioFile_API.SM2.html">CB_AudioFile_API.SM2</a></li><li><a href="CB_AudioFile_API.WAAPI.html">CB_AudioFile_API.WAAPI</a></li><li><a href="CB_AudioFileCache.html">CB_AudioFileCache</a></li><li><a href="CB_AudioFileSprites.html">CB_AudioFileSprites</a></li><li><a href="CB_AudioFileSpritesPool.html">CB_AudioFileSpritesPool</a></li><li><a href="CB_Canvas.html">CB_Canvas</a></li><li><a href="CB_GraphicSprites.html">CB_GraphicSprites</a></li><li><a href="CB_GraphicSpritesScene.html">CB_GraphicSpritesScene</a></li>
44 </ul>
45 </li>
46
47 <li class="dropdown">
48 <a href="global.html" class="dropdown-toggle" data-toggle="dropdown">Global<b class="caret"></b></a>
49 <ul class="dropdown-menu inline">
50 <li><a href="global.html#CB_addCredits">CB_addCredits</a></li><li><a href="global.html#CB_BASE_NAME">CB_BASE_NAME</a></li><li><a href="global.html#CB_baseToBase">CB_baseToBase</a></li><li><a href="global.html#CB_baseToInt">CB_baseToInt</a></li><li><a href="global.html#CB_br2nl">CB_br2nl</a></li><li><a href="global.html#CB_brToNl">CB_brToNl</a></li><li><a href="global.html#CB_combineArraysOrObjects">CB_combineArraysOrObjects</a></li><li><a href="global.html#CB_combineAutomatically">CB_combineAutomatically</a></li><li><a href="global.html#CB_combineJSON">CB_combineJSON</a></li><li><a href="global.html#CB_combineURIParameters">CB_combineURIParameters</a></li><li><a href="global.html#CB_combineURLParameters">CB_combineURLParameters</a></li><li><a href="global.html#CB_console">CB_console</a></li><li><a href="global.html#CB_copyObject">CB_copyObject</a></li><li><a href="global.html#CB_countDecimalDigits">CB_countDecimalDigits</a></li><li><a href="global.html#CB_countDecimalPart">CB_countDecimalPart</a></li><li><a href="global.html#CB_countDecimals">CB_countDecimals</a></li><li><a href="global.html#CB_countIntegerDigits">CB_countIntegerDigits</a></li><li><a href="global.html#CB_countIntegerPart">CB_countIntegerPart</a></li><li><a href="global.html#CB_credits">CB_credits</a></li><li><a href="global.html#CB_CREDITS_DEFAULT">CB_CREDITS_DEFAULT</a></li><li><a href="global.html#CB_forceString">CB_forceString</a></li><li><a href="global.html#CB_forEach">CB_forEach</a></li><li><a href="global.html#CB_getBase64StringObject">CB_getBase64StringObject</a></li><li><a href="global.html#CB_getCookie">CB_getCookie</a></li><li><a href="global.html#CB_getDatum">CB_getDatum</a></li><li><a href="global.html#CB_getJSONPropertyValue">CB_getJSONPropertyValue</a></li><li><a href="global.html#CB_getLZStringObject">CB_getLZStringObject</a></li><li><a href="global.html#CB_getValueIndex">CB_getValueIndex</a></li><li><a href="global.html#CB_getValuePath">CB_getValuePath</a></li><li><a href="global.html#CB_includeJSFile">CB_includeJSFile</a></li><li><a href="global.html#CB_indexOf">CB_indexOf</a></li><li><a href="global.html#CB_init">CB_init</a></li><li><a href="global.html#CB_intToBase">CB_intToBase</a></li><li><a href="global.html#CB_isArray">CB_isArray</a></li><li><a href="global.html#CB_isEmail">CB_isEmail</a></li><li><a href="global.html#CB_isFileLocal">CB_isFileLocal</a></li><li><a href="global.html#CB_isString">CB_isString</a></li><li><a href="global.html#CB_lastIndexOf">CB_lastIndexOf</a></li><li><a href="global.html#CB_ltrim">CB_ltrim</a></li><li><a href="global.html#CB_NAME">CB_NAME</a></li><li><a href="global.html#CB_nl2br">CB_nl2br</a></li><li><a href="global.html#CB_nlToBr">CB_nlToBr</a></li><li><a href="global.html#CB_numberFormat">CB_numberFormat</a></li><li><a href="global.html#CB_numberOfDecimalDigits">CB_numberOfDecimalDigits</a></li><li><a href="global.html#CB_numberOfDecimals">CB_numberOfDecimals</a></li><li><a href="global.html#CB_numberOfIntegerDigits">CB_numberOfIntegerDigits</a></li><li><a href="global.html#CB_OPTIONS">CB_OPTIONS</a></li><li><a href="global.html#CB_parseJSON">CB_parseJSON</a></li><li><a href="global.html#CB_parseString">CB_parseString</a></li><li><a href="global.html#CB_regularExpressionString">CB_regularExpressionString</a></li><li><a href="global.html#CB_renderString">CB_renderString</a></li><li><a href="global.html#CB_replaceAll">CB_replaceAll</a></li><li><a href="global.html#CB_rtrim">CB_rtrim</a></li><li><a href="global.html#CB_scriptPath">CB_scriptPath</a></li><li><a href="global.html#CB_scriptPathCalculate">CB_scriptPathCalculate</a></li><li><a href="global.html#CB_setCookie">CB_setCookie</a></li><li><a href="global.html#CB_setDatum">CB_setDatum</a></li><li><a href="global.html#CB_sizeof">CB_sizeof</a></li><li><a href="global.html#CB_sizeOf">CB_sizeOf</a></li><li><a href="global.html#CB_stringifyJSON">CB_stringifyJSON</a></li><li><a href="global.html#CB_symmetricCall">CB_symmetricCall</a></li><li><a href="global.html#CB_symmetricCallClear">CB_symmetricCallClear</a></li><li><a href="global.html#CB_this">CB_this</a></li><li><a href="global.html#CB_trim">CB_trim</a></li><li><a href="global.html#CB_VERSION">CB_VERSION</a></li>
51 </ul>
52 </li>
53
54 </ul>
55
56 <div class="col-sm-3 col-md-3">
57 <form class="navbar-form" role="search">
58 <div class="input-group">
59 <input type="text" class="form-control" placeholder="Search" name="q" id="search-input">
60 <div class="input-group-btn">
61 <button class="btn btn-default" id="search-submit"><i class="glyphicon glyphicon-search"></i></button>
62 </div>
63 </div>
64 </form>
65 </div>
66
67 </div>
68
69</div>
70</div>
71
72
73<div class="container" id="toc-content" style="width:100%;">
74<div class="row" style="width:100%;">
75
76
77 <div class="col-md-8" style="width:85%;">
78
79 <div id="main">
80
81
82
83 <h1 class="page-title">Global</h1>
84
85<section>
86
87<header>
88
89 <h2>
90
91 </h2>
92
93
94</header>
95
96
97<article>
98 <div class="container-overview">
99
100
101
102
103<dl class="details">
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</dl>
140
141
142
143
144 </div>
145
146
147
148
149
150
151
152
153
154
155
156
157 <h3 class="subsection-title">Members</h3>
158
159 <dl>
160
161<hr>
162<dt class="name" id="CB_BASE_NAME">
163 <h4 id="CB_BASE_NAME"><span class="type-signature">&lt;constant> </span>CB_BASE_NAME<span class="type-signature"> :string</span></h4>
164
165
166</dt>
167<dd>
168
169 <div class="description">
170 <p>Keeps the name of the CrossBase module.</p>
171 </div>
172
173
174
175 <h5>Type:</h5>
176 <ul>
177 <li>
178
179<span class="param-type">string</span>
180
181
182
183 </li>
184 </ul>
185
186
187
188<dl class="details">
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 <dt class="tag-default method-doc-label method-doc-details-label">Default Value:</dt>
215 <dd class="tag-default">
216 <ul class="dummy">
217 <li>CrossBase</li>
218 </ul>
219 </dd>
220
221
222
223
224
225 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
226 <dd class="tag-source">
227 <ul class="dummy">
228 <li>
229 <a href="CrossBase_CrossBase.js.html">CrossBase/CrossBase.js</a>,
230 <a href="CrossBase_CrossBase.js.html#sunlight-1-line-50">line 50</a>
231 </li>
232 </ul>
233 </dd>
234
235
236
237
238
239
240
241</dl>
242
243
244
245</dd>
246
247
248
249<hr>
250<dt class="name" id="CB_CREDITS_DEFAULT">
251 <h4 id="CB_CREDITS_DEFAULT"><span class="type-signature">&lt;readonly> </span>CB_CREDITS_DEFAULT<span class="type-signature"> :string</span></h4>
252
253
254</dt>
255<dd>
256
257 <div class="description">
258 <p>Default credits.</p>
259 </div>
260
261
262
263 <h5>Type:</h5>
264 <ul>
265 <li>
266
267<span class="param-type">string</span>
268
269
270
271 </li>
272 </ul>
273
274
275
276<dl class="details">
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 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
307 <dd class="tag-source">
308 <ul class="dummy">
309 <li>
310 <a href="CrossBrowdy.js.html">CrossBrowdy.js</a>,
311 <a href="CrossBrowdy.js.html#sunlight-1-line-299">line 299</a>
312 </li>
313 </ul>
314 </dd>
315
316
317
318
319
320
321
322</dl>
323
324
325
326</dd>
327
328
329
330<hr>
331<dt class="name" id="CB_NAME">
332 <h4 id="CB_NAME"><span class="type-signature">&lt;constant> </span>CB_NAME<span class="type-signature"> :string</span></h4>
333
334
335</dt>
336<dd>
337
338 <div class="description">
339 <p>Keeps the name of the script (the main script will use this name with the &quot;.js&quot; extension). Case sensitive.</p>
340 </div>
341
342
343
344 <h5>Type:</h5>
345 <ul>
346 <li>
347
348<span class="param-type">string</span>
349
350
351
352 </li>
353 </ul>
354
355
356
357<dl class="details">
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 <dt class="tag-default method-doc-label method-doc-details-label">Default Value:</dt>
384 <dd class="tag-default">
385 <ul class="dummy">
386 <li>CrossBrowdy</li>
387 </ul>
388 </dd>
389
390
391
392
393
394 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
395 <dd class="tag-source">
396 <ul class="dummy">
397 <li>
398 <a href="CrossBrowdy.js.html">CrossBrowdy.js</a>,
399 <a href="CrossBrowdy.js.html#sunlight-1-line-18">line 18</a>
400 </li>
401 </ul>
402 </dd>
403
404
405
406
407
408
409
410</dl>
411
412
413
414</dd>
415
416
417
418<hr>
419<dt class="name" id="CB_OPTIONS">
420 <h4 id="CB_OPTIONS"><span class="type-signature">&lt;constant> </span>CB_OPTIONS<span class="type-signature"> :Object</span></h4>
421
422
423</dt>
424<dd>
425
426 <div class="description">
427 <p>Two-dimensional object defined by the user with the desired options for CrossBrowdy and its modules. The options supported are the ones used by the <a href="CB_Configuration.html"><code>CB_Configuration</code></a> object.<br> <br><br> First-level indexes should belong to the module name (or to &quot;CrossBrowdy&quot;, for general options) and second-level indexes should belong to the option name.<br> <br><br> Example:<br> <br><br> {<br> CrossBrowdy:<br> {<br> CB_console_ALLOW_ALERTS: false<br> },<br> CrossBase:<br> {<br> SLCANVAS_LOAD : true,<br> FLASHCANVAS_LOAD : true<br> }<br> }</p>
428 </div>
429
430
431
432 <h5>Type:</h5>
433 <ul>
434 <li>
435
436<span class="param-type">Object</span>
437
438
439
440 </li>
441 </ul>
442
443
444
445<dl class="details">
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471 <dt class="tag-default method-doc-label method-doc-details-label">Default Value:</dt>
472 <dd class="tag-default">
473 <ul class="dummy">
474 <li>undefined</li>
475 </ul>
476 </dd>
477
478
479
480
481
482 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
483 <dd class="tag-source">
484 <ul class="dummy">
485 <li>
486 <a href="CrossBrowdy.js.html">CrossBrowdy.js</a>,
487 <a href="CrossBrowdy.js.html#sunlight-1-line-34">line 34</a>
488 </li>
489 </ul>
490 </dd>
491
492
493
494
495
496
497
498</dl>
499
500
501
502</dd>
503
504
505
506<hr>
507<dt class="name" id="CB_scriptPath">
508 <h4 id="CB_scriptPath"><span class="type-signature">&lt;readonly> </span>CB_scriptPath<span class="type-signature"> :string</span></h4>
509
510
511</dt>
512<dd>
513
514 <div class="description">
515 <p>It will contain the CrossBrowdy path when it finally loads.</p>
516 </div>
517
518
519
520 <h5>Type:</h5>
521 <ul>
522 <li>
523
524<span class="param-type">string</span>
525
526
527
528 </li>
529 </ul>
530
531
532
533<dl class="details">
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559 <dt class="tag-default method-doc-label method-doc-details-label">Default Value:</dt>
560 <dd class="tag-default">
561 <ul class="dummy">
562 <li><a href="global.html#CB_scriptPathCalculate"><code>CB_scriptPathCalculate</code></a>();</li>
563 </ul>
564 </dd>
565
566
567
568
569
570 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
571 <dd class="tag-source">
572 <ul class="dummy">
573 <li>
574 <a href="CrossBrowdy.js.html">CrossBrowdy.js</a>,
575 <a href="CrossBrowdy.js.html#sunlight-1-line-145">line 145</a>
576 </li>
577 </ul>
578 </dd>
579
580
581
582
583
584
585
586</dl>
587
588
589
590</dd>
591
592
593
594<hr>
595<dt class="name" id="CB_this">
596 <h4 id="CB_this"><span class="type-signature">&lt;constant> </span>CB_this<span class="type-signature"> :Object</span></h4>
597
598
599</dt>
600<dd>
601
602 <div class="description">
603 <p>Keeps the CrossBrowdy &quot;this&quot; context.</p>
604 </div>
605
606
607
608 <h5>Type:</h5>
609 <ul>
610 <li>
611
612<span class="param-type">Object</span>
613
614
615
616 </li>
617 </ul>
618
619
620
621<dl class="details">
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
652 <dd class="tag-source">
653 <ul class="dummy">
654 <li>
655 <a href="CrossBrowdy.js.html">CrossBrowdy.js</a>,
656 <a href="CrossBrowdy.js.html#sunlight-1-line-32">line 32</a>
657 </li>
658 </ul>
659 </dd>
660
661
662
663
664
665
666
667</dl>
668
669
670
671</dd>
672
673
674
675<hr>
676<dt class="name" id="CB_VERSION">
677 <h4 id="CB_VERSION"><span class="type-signature">&lt;constant> </span>CB_VERSION<span class="type-signature"> :string</span></h4>
678
679
680</dt>
681<dd>
682
683 <div class="description">
684 <p>CrossBrowdy version.</p>
685 </div>
686
687
688
689 <h5>Type:</h5>
690 <ul>
691 <li>
692
693<span class="param-type">string</span>
694
695
696
697 </li>
698 </ul>
699
700
701
702<dl class="details">
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
733 <dd class="tag-source">
734 <ul class="dummy">
735 <li>
736 <a href="CrossBrowdy.js.html">CrossBrowdy.js</a>,
737 <a href="CrossBrowdy.js.html#sunlight-1-line-25">line 25</a>
738 </li>
739 </ul>
740 </dd>
741
742
743
744
745
746
747
748</dl>
749
750
751
752</dd>
753
754 </dl>
755
756
757
758 <h3 class="subsection-title">Methods</h3>
759
760 <dl>
761
762<hr>
763<dt>
764 <h4 class="name" id="CB_addCredits"><span class="type-signature"></span>CB_addCredits<span class="signature">(credits)</span><span class="type-signature"> &rarr; {string}</span></h4>
765
766
767</dt>
768<dd>
769
770
771 <div class="description">
772 <p>Attaches the given credits to the default ones (to <a href="global.html#CB_CREDITS_DEFAULT"><code>CB_CREDITS_DEFAULT</code></a>).</p>
773 </div>
774
775
776
777
778
779
780
781
782 <h5>Parameters:</h5>
783
784
785<table class="params table table-striped">
786 <thead>
787 <tr>
788
789 <th style="width:12%; min-width:110px;">Name</th>
790
791
792 <th style="width:12%; min-width:110px;">Type</th>
793
794
795
796
797
798 <th class="last" style="min-width:310px;">Description</th>
799 </tr>
800 </thead>
801
802 <tbody>
803
804
805 <tr>
806
807 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>credits</code></td>
808
809
810 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
811
812
813<span class="param-type">string</span>
814
815
816
817
818 </td>
819
820
821
822
823
824 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Path to the JS file.</p></td>
825 </tr>
826
827
828 </tbody>
829</table>
830
831
832
833
834<dl class="details">
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
865 <dd class="tag-source">
866 <ul class="dummy">
867 <li>
868 <a href="CrossBrowdy.js.html">CrossBrowdy.js</a>,
869 <a href="CrossBrowdy.js.html#sunlight-1-line-313">line 313</a>
870 </li>
871 </ul>
872 </dd>
873
874
875
876
877
878
879
880</dl>
881
882
883
884
885
886
887
888
889
890
891
892
893
894 <h5>Returns:</h5>
895
896
897<div class="param-desc">
898 <p>Returns the default credits after attaching the given ones.</p>
899</div>
900
901
902
903<dl>
904 <dt>
905 Type
906 </dt>
907 <dd>
908
909<span class="param-type">string</span>
910
911
912
913 </dd>
914</dl>
915
916
917
918
919
920</dd>
921
922
923
924<hr>
925<dt>
926 <h4 class="name" id="CB_baseToBase"><span class="type-signature"></span>CB_baseToBase<span class="signature">(number [, baseSymbolsOrigin] [, baseSymbolsDestiny] [, unsigned] [, minusSymbolOrigin] [, minusSymbolDestiny] [, prefixOrigin] [, prefixDestiny])</span><span class="type-signature"> &rarr; {string}</span></h4>
927
928
929</dt>
930<dd>
931
932
933 <div class="description">
934 <p>Converts a given number which is already in a desired base into another chosen base.<br> <br /><br> Note: Uses <a href="global.html#CB_baseToInt"><code>CB_baseToInt</code></a> and <a href="global.html#CB_intToBase"><code>CB_intToBase</code></a> internally.</p>
935 </div>
936
937
938
939
940
941
942
943
944 <h5>Parameters:</h5>
945
946
947<table class="params table table-striped">
948 <thead>
949 <tr>
950
951 <th style="width:12%; min-width:110px;">Name</th>
952
953
954 <th style="width:12%; min-width:110px;">Type</th>
955
956
957 <th style="width:12%; min-width:110px;">Argument</th>
958
959
960
961 <th style="width:12%; min-width:110px;">Default</th>
962
963
964 <th class="last" style="min-width:310px;">Description</th>
965 </tr>
966 </thead>
967
968 <tbody>
969
970
971 <tr>
972
973 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>number</code></td>
974
975
976 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
977
978
979<span class="param-type">string</span>
980
981
982
983
984 </td>
985
986
987 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
988
989
990
991
992
993 </td>
994
995
996
997 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
998
999 </td>
1000
1001
1002 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>A string containing the number which is already in the desired base and that we want to convert into the another chosen base. Used as the &quot;number&quot; parameter for calling both <a href="global.html#CB_intToBase"><code>CB_intToBase</code></a> and <a href="global.html#CB_baseToInt"><code>CB_baseToInt</code></a> functions internally.</p></td>
1003 </tr>
1004
1005
1006
1007 <tr>
1008
1009 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>baseSymbolsOrigin</code></td>
1010
1011
1012 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1013
1014
1015<span class="param-type">array</span>
1016|
1017
1018<span class="param-type">integer</span>
1019
1020
1021
1022
1023 </td>
1024
1025
1026 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1027
1028 &lt;optional><br>
1029
1030
1031
1032
1033
1034 </td>
1035
1036
1037
1038 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1039
1040 <a href="CB_baseSymbols.html#.66"><code>CB_baseSymbols.66</code></a>
1041
1042 </td>
1043
1044
1045 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Used as the &quot;baseSymbols&quot; parameter when calling the <a href="global.html#CB_baseToInt"><code>CB_baseToInt</code></a> function internally.</p></td>
1046 </tr>
1047
1048
1049
1050 <tr>
1051
1052 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>baseSymbolsDestiny</code></td>
1053
1054
1055 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1056
1057
1058<span class="param-type">array</span>
1059|
1060
1061<span class="param-type">integer</span>
1062
1063
1064
1065
1066 </td>
1067
1068
1069 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1070
1071 &lt;optional><br>
1072
1073
1074
1075
1076
1077 </td>
1078
1079
1080
1081 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1082
1083 <a href="CB_baseSymbols.html#.66"><code>CB_baseSymbols.66</code></a>
1084
1085 </td>
1086
1087
1088 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Used as the &quot;baseSymbols&quot; parameter when calling the <a href="global.html#CB_intToBase"><code>CB_intToBase</code></a> function internally.</p></td>
1089 </tr>
1090
1091
1092
1093 <tr>
1094
1095 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>unsigned</code></td>
1096
1097
1098 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1099
1100
1101<span class="param-type">boolean</span>
1102
1103
1104
1105
1106 </td>
1107
1108
1109 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1110
1111 &lt;optional><br>
1112
1113
1114
1115
1116
1117 </td>
1118
1119
1120
1121 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1122
1123 false
1124
1125 </td>
1126
1127
1128 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Determines whether to treat the input and output numbers as unsigned or not. Used as the &quot;unsigned&quot; parameter for calling both <a href="global.html#CB_intToBase"><code>CB_intToBase</code></a> and <a href="global.html#CB_baseToInt"><code>CB_baseToInt</code></a> functions internally.</p></td>
1129 </tr>
1130
1131
1132
1133 <tr>
1134
1135 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>minusSymbolOrigin</code></td>
1136
1137
1138 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1139
1140
1141<span class="param-type">string</span>
1142
1143
1144
1145
1146 </td>
1147
1148
1149 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1150
1151 &lt;optional><br>
1152
1153
1154
1155
1156
1157 </td>
1158
1159
1160
1161 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1162
1163 '-'|'0'
1164
1165 </td>
1166
1167
1168 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Used as the &quot;minusSymbol&quot; parameter when calling the <a href="global.html#CB_baseToInt"><code>CB_baseToInt</code></a> function internally.</p></td>
1169 </tr>
1170
1171
1172
1173 <tr>
1174
1175 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>minusSymbolDestiny</code></td>
1176
1177
1178 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1179
1180
1181<span class="param-type">string</span>
1182
1183
1184
1185
1186 </td>
1187
1188
1189 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1190
1191 &lt;optional><br>
1192
1193
1194
1195
1196
1197 </td>
1198
1199
1200
1201 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1202
1203 '-'|'0'
1204
1205 </td>
1206
1207
1208 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Used as the &quot;minusSymbol&quot; parameter when calling the <a href="global.html#CB_intToBase"><code>CB_intToBase</code></a> function internally.</p></td>
1209 </tr>
1210
1211
1212
1213 <tr>
1214
1215 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>prefixOrigin</code></td>
1216
1217
1218 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1219
1220
1221<span class="param-type">prefix</span>
1222
1223
1224
1225
1226 </td>
1227
1228
1229 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1230
1231 &lt;optional><br>
1232
1233
1234
1235
1236
1237 </td>
1238
1239
1240
1241 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1242
1243 '0'|'0x'|''
1244
1245 </td>
1246
1247
1248 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Used as the &quot;prefix&quot; parameter when calling the <a href="global.html#CB_baseToInt"><code>CB_baseToInt</code></a> function internally.</p></td>
1249 </tr>
1250
1251
1252
1253 <tr>
1254
1255 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>prefixDestiny</code></td>
1256
1257
1258 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1259
1260
1261<span class="param-type">prefix</span>
1262
1263
1264
1265
1266 </td>
1267
1268
1269 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1270
1271 &lt;optional><br>
1272
1273
1274
1275
1276
1277 </td>
1278
1279
1280
1281 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1282
1283 '0'|'0x'|''
1284
1285 </td>
1286
1287
1288 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Used as the &quot;prefix&quot; parameter when calling the <a href="global.html#CB_intToBase"><code>CB_intToBase</code></a> function internally.</p></td>
1289 </tr>
1290
1291
1292 </tbody>
1293</table>
1294
1295
1296
1297
1298<dl class="details">
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
1329 <dd class="tag-source">
1330 <ul class="dummy">
1331 <li>
1332 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
1333 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-1421">line 1421</a>
1334 </li>
1335 </ul>
1336 </dd>
1337
1338
1339
1340
1341
1342
1343
1344 <dt class="tag-todo method-doc-label method-doc-details-label">To Do:</dt>
1345 <dd class="tag-todo">
1346 <ul>
1347 <li>Think about accepting a decimal symbol to separate decimals and support float numbers.</li>
1348 </ul>
1349 </dd>
1350
1351</dl>
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365 <h5>Returns:</h5>
1366
1367
1368<div class="param-desc">
1369 <p>Returns the returning value of the internal call to the <a href="global.html#CB_intToBase"><code>CB_intToBase</code></a> function.</p>
1370</div>
1371
1372
1373
1374<dl>
1375 <dt>
1376 Type
1377 </dt>
1378 <dd>
1379
1380<span class="param-type">string</span>
1381
1382
1383
1384 </dd>
1385</dl>
1386
1387
1388
1389
1390
1391</dd>
1392
1393
1394
1395<hr>
1396<dt>
1397 <h4 class="name" id="CB_baseToInt"><span class="type-signature"></span>CB_baseToInt<span class="signature">(number [, baseSymbols] [, unsigned] [, minusSymbol] [, prefix])</span><span class="type-signature"> &rarr; {integer}</span></h4>
1398
1399
1400</dt>
1401<dd>
1402
1403
1404 <div class="description">
1405 <p>Converts a given number which is already in a desired base into an integer (decimal base).<br> <br /><br> Note: It can return wrong values when the value exceeds the maximum allowed by a number in the client's JavaScript engine. It can also depend on the &quot;baseSymbols&quot; used.</p>
1406 </div>
1407
1408
1409
1410
1411
1412
1413
1414
1415 <h5>Parameters:</h5>
1416
1417
1418<table class="params table table-striped">
1419 <thead>
1420 <tr>
1421
1422 <th style="width:12%; min-width:110px;">Name</th>
1423
1424
1425 <th style="width:12%; min-width:110px;">Type</th>
1426
1427
1428 <th style="width:12%; min-width:110px;">Argument</th>
1429
1430
1431
1432 <th style="width:12%; min-width:110px;">Default</th>
1433
1434
1435 <th class="last" style="min-width:310px;">Description</th>
1436 </tr>
1437 </thead>
1438
1439 <tbody>
1440
1441
1442 <tr>
1443
1444 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>number</code></td>
1445
1446
1447 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1448
1449
1450<span class="param-type">string</span>
1451
1452
1453
1454
1455 </td>
1456
1457
1458 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1459
1460
1461
1462
1463
1464 </td>
1465
1466
1467
1468 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1469
1470 </td>
1471
1472
1473 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>A string containing the number which is already in the desired base and that we want to convert to an integer.</p></td>
1474 </tr>
1475
1476
1477
1478 <tr>
1479
1480 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>baseSymbols</code></td>
1481
1482
1483 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1484
1485
1486<span class="param-type">array</span>
1487|
1488
1489<span class="param-type">integer</span>
1490
1491
1492
1493
1494 </td>
1495
1496
1497 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1498
1499 &lt;optional><br>
1500
1501
1502
1503
1504
1505 </td>
1506
1507
1508
1509 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1510
1511 <a href="CB_baseSymbols.html#.66"><code>CB_baseSymbols.66</code></a>
1512
1513 </td>
1514
1515
1516 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Array with the desired symbols, using only one per index (their value will correspond to their index). The base (radix) will be the total number of indexes. It should be the base which is already being used by the given number. If an integer greater or equal than 2 is provided, it will try to use it as an index of the <a href="CB_baseSymbols.html"><code>CB_baseSymbols</code></a> object and use it if found or use it as a parameter to call the <a href="CB_baseSymbols.html#.get"><code>CB_baseSymbols.get</code></a> function otherwise. If not provided or the integer is lower than 2, it will use base 66 (defined in the <a href="CB_baseSymbols.html#._66"><code>CB_baseSymbols._66</code></a> property of the <a href="CB_baseSymbols.html"><code>CB_baseSymbols</code></a> object). It is recommended not to exceed 4096 (or even lower, depending on the client, although some clients could support up to 63988 or even more). The properties of the <a href="CB_baseSymbols.html"><code>CB_baseSymbols</code></a> object or the <a href="CB_baseSymbols.html#.get"><code>CB_baseSymbols.get</code></a> function can be used for this parameter.</p></td>
1517 </tr>
1518
1519
1520
1521 <tr>
1522
1523 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>unsigned</code></td>
1524
1525
1526 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1527
1528
1529<span class="param-type">boolean</span>
1530
1531
1532
1533
1534 </td>
1535
1536
1537 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1538
1539 &lt;optional><br>
1540
1541
1542
1543
1544
1545 </td>
1546
1547
1548
1549 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1550
1551 false
1552
1553 </td>
1554
1555
1556 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Determines whether to treat the input and output numbers as unsigned or not.</p></td>
1557 </tr>
1558
1559
1560
1561 <tr>
1562
1563 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>minusSymbol</code></td>
1564
1565
1566 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1567
1568
1569<span class="param-type">string</span>
1570
1571
1572
1573
1574 </td>
1575
1576
1577 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1578
1579 &lt;optional><br>
1580
1581
1582
1583
1584
1585 </td>
1586
1587
1588
1589 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1590
1591 '-'|'0'
1592
1593 </td>
1594
1595
1596 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Determines the minus symbol or string for the input, to mark negative numbers. If not provided, it will be '-' for bases equal or lower than 16 (hexadecimal) or '0' (zero character) otherwise. This parameter is ignored if the &quot;unsigned&quot; parameter is set to true.</p></td>
1597 </tr>
1598
1599
1600
1601 <tr>
1602
1603 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>prefix</code></td>
1604
1605
1606 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1607
1608
1609<span class="param-type">prefix</span>
1610
1611
1612
1613
1614 </td>
1615
1616
1617 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1618
1619 &lt;optional><br>
1620
1621
1622
1623
1624
1625 </td>
1626
1627
1628
1629 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1630
1631 '0'|'0x'|''
1632
1633 </td>
1634
1635
1636 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Determines the prefix for the input. If not provided, it will be '0' (zero character) for base 8 (octal), '0x' for base 16 (hexadecimal) or nothing (empty string) for all the others. Use an empty string to avoid using anything.</p></td>
1637 </tr>
1638
1639
1640 </tbody>
1641</table>
1642
1643
1644
1645
1646<dl class="details">
1647
1648
1649
1650
1651
1652
1653
1654
1655
1656
1657
1658
1659
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674
1675
1676 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
1677 <dd class="tag-source">
1678 <ul class="dummy">
1679 <li>
1680 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
1681 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-1349">line 1349</a>
1682 </li>
1683 </ul>
1684 </dd>
1685
1686
1687
1688
1689
1690
1691
1692 <dt class="tag-todo method-doc-label method-doc-details-label">To Do:</dt>
1693 <dd class="tag-todo">
1694 <ul>
1695 <li>Think about allowing to return a string, for bigger numbers (to exceed the limit for integers). Internally, it would need to perform operations comparisons, multiplications with strings, etc.</li>
1696
1697 <li>Think about allowing to specify the base for the integer.</li>
1698
1699 <li>Think about accepting a decimal symbol to separate decimals and support float numbers.</li>
1700 </ul>
1701 </dd>
1702
1703</dl>
1704
1705
1706
1707
1708
1709
1710
1711
1712
1713
1714
1715
1716
1717 <h5>Returns:</h5>
1718
1719
1720<div class="param-desc">
1721 <p>Returns the integer number in decimal base.</p>
1722</div>
1723
1724
1725
1726<dl>
1727 <dt>
1728 Type
1729 </dt>
1730 <dd>
1731
1732<span class="param-type">integer</span>
1733
1734
1735
1736 </dd>
1737</dl>
1738
1739
1740
1741
1742
1743</dd>
1744
1745
1746
1747<hr>
1748<dt>
1749 <h4 class="name" id="CB_br2nl"><span class="type-signature"></span>CB_br2nl<span class="signature">(string)</span><span class="type-signature"> &rarr; {string}</span></h4>
1750
1751
1752</dt>
1753<dd>
1754
1755
1756 <div class="description">
1757 <p>Changes &lt;br /&gt;'s, &lt;br/&gt;'s and &lt;br&gt;'s for new lines (\n) in a given string.</p>
1758 </div>
1759
1760
1761
1762
1763
1764
1765
1766
1767 <h5>Parameters:</h5>
1768
1769
1770<table class="params table table-striped">
1771 <thead>
1772 <tr>
1773
1774 <th style="width:12%; min-width:110px;">Name</th>
1775
1776
1777 <th style="width:12%; min-width:110px;">Type</th>
1778
1779
1780
1781
1782
1783 <th class="last" style="min-width:310px;">Description</th>
1784 </tr>
1785 </thead>
1786
1787 <tbody>
1788
1789
1790 <tr>
1791
1792 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>string</code></td>
1793
1794
1795 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
1796
1797
1798<span class="param-type">string</span>
1799
1800
1801
1802
1803 </td>
1804
1805
1806
1807
1808
1809 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The string we want to modify.</p></td>
1810 </tr>
1811
1812
1813 </tbody>
1814</table>
1815
1816
1817
1818
1819<dl class="details">
1820
1821
1822
1823
1824
1825
1826
1827
1828
1829
1830
1831
1832
1833
1834
1835
1836
1837
1838
1839
1840
1841
1842
1843
1844
1845
1846
1847
1848
1849 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
1850 <dd class="tag-source">
1851 <ul class="dummy">
1852 <li>
1853 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
1854 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-442">line 442</a>
1855 </li>
1856 </ul>
1857 </dd>
1858
1859
1860
1861
1862
1863
1864
1865</dl>
1866
1867
1868
1869
1870
1871
1872
1873
1874
1875
1876
1877
1878
1879 <h5>Returns:</h5>
1880
1881
1882<div class="param-desc">
1883 <p>Returns the string with all the occurrences replaced or an empty string if the element given was not a string.</p>
1884</div>
1885
1886
1887
1888<dl>
1889 <dt>
1890 Type
1891 </dt>
1892 <dd>
1893
1894<span class="param-type">string</span>
1895
1896
1897
1898 </dd>
1899</dl>
1900
1901
1902
1903
1904
1905</dd>
1906
1907
1908
1909<hr>
1910<dt>
1911 <h4 class="name" id="CB_brToNl"><span class="type-signature"></span>CB_brToNl<span class="signature">()</span><span class="type-signature"></span></h4>
1912
1913
1914</dt>
1915<dd>
1916
1917
1918 <div class="description">
1919 <p>Alias for <a href="global.html#CB_br2nl"><code>CB_br2nl</code></a>.</p>
1920 </div>
1921
1922
1923
1924
1925
1926
1927
1928
1929
1930
1931<dl class="details">
1932
1933
1934
1935
1936
1937
1938
1939
1940
1941
1942
1943
1944
1945
1946
1947
1948
1949
1950
1951
1952
1953
1954
1955
1956
1957
1958
1959
1960
1961 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
1962 <dd class="tag-source">
1963 <ul class="dummy">
1964 <li>
1965 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
1966 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-431">line 431</a>
1967 </li>
1968 </ul>
1969 </dd>
1970
1971
1972
1973
1974
1975 <dt class="tag-see method-doc-label method-doc-details-label">See:</dt>
1976 <dd class="tag-see">
1977 <ul>
1978 <li><a href="global.html#CB_br2nl"><code>CB_br2nl</code></a></li>
1979 </ul>
1980 </dd>
1981
1982
1983
1984</dl>
1985
1986
1987
1988
1989
1990
1991
1992
1993
1994
1995
1996
1997
1998
1999
2000</dd>
2001
2002
2003
2004<hr>
2005<dt>
2006 <h4 class="name" id="CB_combineArraysOrObjects"><span class="type-signature"></span>CB_combineArraysOrObjects<span class="signature">( [arrayOrObjectA] [, arrayOrObjectB], avoidDuplicatedValuesInArray [, modifyArrayOrObjectA])</span><span class="type-signature"> &rarr; {array|Object}</span></h4>
2007
2008
2009</dt>
2010<dd>
2011
2012
2013 <div class="description">
2014 <p>Returns a combined array or object from two arrays or objects. Using the following rules:<br> <br /><br> If they both are arrays (numeric indexes), it will keep all elements (attaching the elements of the second array after the elements of the first one).<br> <br /><br> Otherwise, if either of them is not an array (it should be an associative array which is an object in JavaScript), it will merge the elements (overwritting those whose index is the same and keeping the ones from the second array/object):</p>
2015 </div>
2016
2017
2018
2019
2020
2021
2022
2023
2024 <h5>Parameters:</h5>
2025
2026
2027<table class="params table table-striped">
2028 <thead>
2029 <tr>
2030
2031 <th style="width:12%; min-width:110px;">Name</th>
2032
2033
2034 <th style="width:12%; min-width:110px;">Type</th>
2035
2036
2037 <th style="width:12%; min-width:110px;">Argument</th>
2038
2039
2040
2041 <th style="width:12%; min-width:110px;">Default</th>
2042
2043
2044 <th class="last" style="min-width:310px;">Description</th>
2045 </tr>
2046 </thead>
2047
2048 <tbody>
2049
2050
2051 <tr>
2052
2053 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>arrayOrObjectA</code></td>
2054
2055
2056 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
2057
2058
2059<span class="param-type">array</span>
2060|
2061
2062<span class="param-type">Object</span>
2063|
2064
2065<span class="param-type">string</span>
2066|
2067
2068<span class="param-type">null</span>
2069|
2070
2071<span class="param-type">undefined</span>
2072
2073
2074
2075
2076 </td>
2077
2078
2079 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
2080
2081 &lt;optional><br>
2082
2083
2084
2085
2086
2087 </td>
2088
2089
2090
2091 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
2092
2093 []|{}
2094
2095 </td>
2096
2097
2098 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>One of the arrays (numeric indexes) or associative arrays (object) that we want to combine. If a string is provided, it will try to convert it into a new object (the string should be a JSON-valid string). It can be optional if &quot;arrayOrObjectB&quot; is a valid value and neither null nor undefined. If not provided but the &quot;arrayOrObjectB&quot; is provided, it will be a new empty array if the &quot;arrayOrObjectB&quot; is an array or it will be an empty object otherwise.</p></td>
2099 </tr>
2100
2101
2102
2103 <tr>
2104
2105 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>arrayOrObjectB</code></td>
2106
2107
2108 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
2109
2110
2111<span class="param-type">array</span>
2112|
2113
2114<span class="param-type">Object</span>
2115|
2116
2117<span class="param-type">string</span>
2118|
2119
2120<span class="param-type">null</span>
2121|
2122
2123<span class="param-type">undefined</span>
2124
2125
2126
2127
2128 </td>
2129
2130
2131 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
2132
2133 &lt;optional><br>
2134
2135
2136
2137
2138
2139 </td>
2140
2141
2142
2143 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
2144
2145 []|{}
2146
2147 </td>
2148
2149
2150 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>One of the arrays (numeric indexes) or associative arrays (object) that we want to combine. If a string is provided, it will try to convert it into a new object (the string should be a JSON-valid string). It can be optional if &quot;arrayOrObjectA&quot; is a valid value and neither null nor undefined. If not provided but the &quot;arrayOrObjectA&quot; is provided, it will be a new empty array if the &quot;arrayOrObjectA&quot; is an array or it will be an empty object otherwise.</p></td>
2151 </tr>
2152
2153
2154
2155 <tr>
2156
2157 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>avoidDuplicatedValuesInArray</code></td>
2158
2159
2160 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
2161
2162
2163<span class="param-type">boolean</span>
2164
2165
2166
2167
2168 </td>
2169
2170
2171 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
2172
2173
2174
2175
2176
2177 </td>
2178
2179
2180
2181 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
2182
2183 </td>
2184
2185
2186 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Tells whether to avoid or allow items with duplicated values in the returned array or not. Only applies when both arrays to combine are numeric arrays.</p></td>
2187 </tr>
2188
2189
2190
2191 <tr>
2192
2193 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>modifyArrayOrObjectA</code></td>
2194
2195
2196 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
2197
2198
2199<span class="param-type">boolean</span>
2200
2201
2202
2203
2204 </td>
2205
2206
2207 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
2208
2209 &lt;optional><br>
2210
2211
2212
2213
2214
2215 </td>
2216
2217
2218
2219 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
2220
2221 false
2222
2223 </td>
2224
2225
2226 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Parameter that will be used in the case that <a href="global.html#CB_combineJSON"><code>CB_combineJSON</code></a> or <a href="global.html#CB_combineArraysOrObjects"><code>CB_combineArraysOrObjects</code></a> is called. If set to true, it will modify the original &quot;arrayOrObjectA&quot; array or object.</p></td>
2227 </tr>
2228
2229
2230 </tbody>
2231</table>
2232
2233
2234
2235
2236<dl class="details">
2237
2238
2239
2240
2241
2242
2243
2244
2245
2246
2247
2248
2249
2250
2251
2252
2253
2254
2255
2256
2257
2258
2259
2260
2261
2262
2263
2264
2265
2266 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
2267 <dd class="tag-source">
2268 <ul class="dummy">
2269 <li>
2270 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
2271 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-1007">line 1007</a>
2272 </li>
2273 </ul>
2274 </dd>
2275
2276
2277
2278
2279
2280
2281
2282</dl>
2283
2284
2285
2286
2287
2288
2289
2290
2291
2292
2293
2294
2295
2296 <h5>Returns:</h5>
2297
2298
2299
2300
2301<dl>
2302 <dt>
2303 Type
2304 </dt>
2305 <dd>
2306
2307<span class="param-type">array</span>
2308|
2309
2310<span class="param-type">Object</span>
2311
2312
2313
2314 </dd>
2315</dl>
2316
2317
2318
2319
2320
2321</dd>
2322
2323
2324
2325<hr>
2326<dt>
2327 <h4 class="name" id="CB_combineAutomatically"><span class="type-signature"></span>CB_combineAutomatically<span class="signature">( [a] [, b] [, avoidDuplicatedValuesInArray] [, modifyArrayOrObjectA])</span><span class="type-signature"> &rarr; {*}</span></h4>
2328
2329
2330</dt>
2331<dd>
2332
2333
2334 <div class="description">
2335 <p>Tries to combine two given values guessing the best way to do it and returns their combination. Using the following rules:<br> <br /><br> If both values are either undefined or null, returns null.<br> <br /><br> Otherwise, if both values are boolean, returns the AND operation for the two of them (a &amp;&amp; b).<br> <br /><br> Otherwise, if either of the two is a string (not empty) and is not JSON valid, combines them as URL (GET) parameters using <a href="global.html#CB_combineURIParameters"><code>CB_combineURIParameters</code></a>.<br> <br /><br> Otherwise, if either of them is JSON valid, combines them as JSON using <a href="global.html#CB_combineJSON"><code>CB_combineJSON</code></a> (passing the received avoidDuplicatedValuesInArray value as a parameter).<br> <br /><br> Otherwise, combines them as arrays or objects using <a href="global.html#CB_combineArraysOrObjects"><code>CB_combineArraysOrObjects</code></a> (passing the received &quot;avoidDuplicatedValuesInArray&quot; value as a parameter).</p>
2336 </div>
2337
2338
2339
2340
2341
2342
2343
2344
2345 <h5>Parameters:</h5>
2346
2347
2348<table class="params table table-striped">
2349 <thead>
2350 <tr>
2351
2352 <th style="width:12%; min-width:110px;">Name</th>
2353
2354
2355 <th style="width:12%; min-width:110px;">Type</th>
2356
2357
2358 <th style="width:12%; min-width:110px;">Argument</th>
2359
2360
2361
2362 <th style="width:12%; min-width:110px;">Default</th>
2363
2364
2365 <th class="last" style="min-width:310px;">Description</th>
2366 </tr>
2367 </thead>
2368
2369 <tbody>
2370
2371
2372 <tr>
2373
2374 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>a</code></td>
2375
2376
2377 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
2378
2379
2380<span class="param-type">*</span>
2381
2382
2383
2384
2385 </td>
2386
2387
2388 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
2389
2390 &lt;optional><br>
2391
2392
2393
2394
2395
2396 </td>
2397
2398
2399
2400 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
2401
2402 null|[]|{}
2403
2404 </td>
2405
2406
2407 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>First value. It can be optional if &quot;b&quot; is a valid value, defined and not null.</p></td>
2408 </tr>
2409
2410
2411
2412 <tr>
2413
2414 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>b</code></td>
2415
2416
2417 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
2418
2419
2420<span class="param-type">*</span>
2421
2422
2423
2424
2425 </td>
2426
2427
2428 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
2429
2430 &lt;optional><br>
2431
2432
2433
2434
2435
2436 </td>
2437
2438
2439
2440 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
2441
2442 null|[]|{}
2443
2444 </td>
2445
2446
2447 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Second value. It can be optional if &quot;a&quot; is a valid value, defined and not null.</p></td>
2448 </tr>
2449
2450
2451
2452 <tr>
2453
2454 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>avoidDuplicatedValuesInArray</code></td>
2455
2456
2457 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
2458
2459
2460<span class="param-type">boolean</span>
2461
2462
2463
2464
2465 </td>
2466
2467
2468 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
2469
2470 &lt;optional><br>
2471
2472
2473
2474
2475
2476 </td>
2477
2478
2479
2480 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
2481
2482 false
2483
2484 </td>
2485
2486
2487 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Parameter that will be used in the case that <a href="global.html#CB_combineJSON"><code>CB_combineJSON</code></a> or <a href="global.html#CB_combineArraysOrObjects"><code>CB_combineArraysOrObjects</code></a> is called.</p></td>
2488 </tr>
2489
2490
2491
2492 <tr>
2493
2494 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>modifyArrayOrObjectA</code></td>
2495
2496
2497 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
2498
2499
2500<span class="param-type">boolean</span>
2501
2502
2503
2504
2505 </td>
2506
2507
2508 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
2509
2510 &lt;optional><br>
2511
2512
2513
2514
2515
2516 </td>
2517
2518
2519
2520 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
2521
2522 false
2523
2524 </td>
2525
2526
2527 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Parameter that will be used in the case that <a href="global.html#CB_combineJSON"><code>CB_combineJSON</code></a> or <a href="global.html#CB_combineArraysOrObjects"><code>CB_combineArraysOrObjects</code></a> is called. If set to true, it will modify the original &quot;a&quot; array or object.</p></td>
2528 </tr>
2529
2530
2531 </tbody>
2532</table>
2533
2534
2535
2536
2537<dl class="details">
2538
2539
2540
2541
2542
2543
2544
2545
2546
2547
2548
2549
2550
2551
2552
2553
2554
2555
2556
2557
2558
2559
2560
2561
2562
2563
2564
2565
2566
2567 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
2568 <dd class="tag-source">
2569 <ul class="dummy">
2570 <li>
2571 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
2572 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-952">line 952</a>
2573 </li>
2574 </ul>
2575 </dd>
2576
2577
2578
2579
2580
2581
2582
2583</dl>
2584
2585
2586
2587
2588
2589
2590
2591
2592
2593
2594
2595
2596
2597 <h5>Returns:</h5>
2598
2599
2600
2601
2602<dl>
2603 <dt>
2604 Type
2605 </dt>
2606 <dd>
2607
2608<span class="param-type">*</span>
2609
2610
2611
2612 </dd>
2613</dl>
2614
2615
2616
2617
2618
2619</dd>
2620
2621
2622
2623<hr>
2624<dt>
2625 <h4 class="name" id="CB_combineJSON"><span class="type-signature"></span>CB_combineJSON<span class="signature">()</span><span class="type-signature"></span></h4>
2626
2627
2628</dt>
2629<dd>
2630
2631
2632 <div class="description">
2633 <p>Alias for <a href="global.html#CB_combineArraysOrObjects"><code>CB_combineArraysOrObjects</code></a>.</p>
2634 </div>
2635
2636
2637
2638
2639
2640
2641
2642
2643
2644
2645<dl class="details">
2646
2647
2648
2649
2650
2651
2652
2653
2654
2655
2656
2657
2658
2659
2660
2661
2662
2663
2664
2665
2666
2667
2668
2669
2670
2671
2672
2673
2674
2675 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
2676 <dd class="tag-source">
2677 <ul class="dummy">
2678 <li>
2679 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
2680 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-1089">line 1089</a>
2681 </li>
2682 </ul>
2683 </dd>
2684
2685
2686
2687
2688
2689 <dt class="tag-see method-doc-label method-doc-details-label">See:</dt>
2690 <dd class="tag-see">
2691 <ul>
2692 <li><a href="global.html#CB_combineArraysOrObjects"><code>CB_combineArraysOrObjects</code></a></li>
2693 </ul>
2694 </dd>
2695
2696
2697
2698</dl>
2699
2700
2701
2702
2703
2704
2705
2706
2707
2708
2709
2710
2711
2712
2713
2714</dd>
2715
2716
2717
2718<hr>
2719<dt>
2720 <h4 class="name" id="CB_combineURIParameters"><span class="type-signature"></span>CB_combineURIParameters<span class="signature">(parametersA, parametersB)</span><span class="type-signature"> &rarr; {string}</span></h4>
2721
2722
2723</dt>
2724<dd>
2725
2726
2727 <div class="description">
2728 <p>Combines two strings as URL (GET) parameters. If either &quot;parametersA&quot; or &quot;parametersB&quot; is not a string, internally it will use the native <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/JSON/stringify">JSON.stringify</a> method if available or otherwise it will use <a href="https://bestiejs.github.io/json3/">JSON 3</a> instead.</p>
2729 </div>
2730
2731
2732
2733
2734
2735
2736
2737
2738 <h5>Parameters:</h5>
2739
2740
2741<table class="params table table-striped">
2742 <thead>
2743 <tr>
2744
2745 <th style="width:12%; min-width:110px;">Name</th>
2746
2747
2748 <th style="width:12%; min-width:110px;">Type</th>
2749
2750
2751
2752
2753
2754 <th class="last" style="min-width:310px;">Description</th>
2755 </tr>
2756 </thead>
2757
2758 <tbody>
2759
2760
2761 <tr>
2762
2763 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>parametersA</code></td>
2764
2765
2766 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
2767
2768
2769<span class="param-type">string</span>
2770
2771
2772
2773
2774 </td>
2775
2776
2777
2778
2779
2780 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>String with the desired parameter or parameters. It can be optional if &quot;parametersB&quot; is a valid string. It will trim any &quot;&amp;&quot; and &quot;?&quot; character at the beginning and at the end, and finally use &quot;&amp;&quot; to concatenate the two strings (if needed).</p></td>
2781 </tr>
2782
2783
2784
2785 <tr>
2786
2787 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>parametersB</code></td>
2788
2789
2790 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
2791
2792
2793<span class="param-type">string</span>
2794
2795
2796
2797
2798 </td>
2799
2800
2801
2802
2803
2804 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>String with the desired parameter or parameters. It can be optional if &quot;parametersA&quot; is a valid string. It will trim any &quot;&amp;&quot; and &quot;?&quot; character at the beginning and at the end, and finally use &quot;&amp;&quot; to concatenate the two strings (if needed).</p></td>
2805 </tr>
2806
2807
2808 </tbody>
2809</table>
2810
2811
2812
2813
2814<dl class="details">
2815
2816
2817
2818
2819
2820
2821
2822
2823
2824
2825
2826
2827
2828
2829
2830
2831
2832
2833
2834
2835
2836
2837
2838
2839
2840
2841
2842
2843
2844 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
2845 <dd class="tag-source">
2846 <ul class="dummy">
2847 <li>
2848 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
2849 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-981">line 981</a>
2850 </li>
2851 </ul>
2852 </dd>
2853
2854
2855
2856
2857
2858
2859
2860</dl>
2861
2862
2863
2864
2865
2866
2867
2868
2869
2870
2871
2872
2873
2874 <h5>Returns:</h5>
2875
2876
2877<div class="param-desc">
2878 <p>For example, if parametersA is &quot;parameter1=value1&amp;parameter2=value2&quot; and parametersB is &quot;parameter3=value3&amp;what=ever&quot; then it will return &quot;parameter1=value1&amp;parameter2=value2&amp;parameter3=value3&amp;what=ever&quot;.</p>
2879</div>
2880
2881
2882
2883<dl>
2884 <dt>
2885 Type
2886 </dt>
2887 <dd>
2888
2889<span class="param-type">string</span>
2890
2891
2892
2893 </dd>
2894</dl>
2895
2896
2897
2898
2899
2900</dd>
2901
2902
2903
2904<hr>
2905<dt>
2906 <h4 class="name" id="CB_combineURLParameters"><span class="type-signature"></span>CB_combineURLParameters<span class="signature">()</span><span class="type-signature"></span></h4>
2907
2908
2909</dt>
2910<dd>
2911
2912
2913 <div class="description">
2914 <p>Alias for <a href="global.html#CB_combineURIParameters"><code>CB_combineURIParameters</code></a>.</p>
2915 </div>
2916
2917
2918
2919
2920
2921
2922
2923
2924
2925
2926<dl class="details">
2927
2928
2929
2930
2931
2932
2933
2934
2935
2936
2937
2938
2939
2940
2941
2942
2943
2944
2945
2946
2947
2948
2949
2950
2951
2952
2953
2954
2955
2956 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
2957 <dd class="tag-source">
2958 <ul class="dummy">
2959 <li>
2960 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
2961 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-969">line 969</a>
2962 </li>
2963 </ul>
2964 </dd>
2965
2966
2967
2968
2969
2970 <dt class="tag-see method-doc-label method-doc-details-label">See:</dt>
2971 <dd class="tag-see">
2972 <ul>
2973 <li><a href="global.html#CB_combineURIParameters"><code>CB_combineURIParameters</code></a></li>
2974 </ul>
2975 </dd>
2976
2977
2978
2979</dl>
2980
2981
2982
2983
2984
2985
2986
2987
2988
2989
2990
2991
2992
2993
2994
2995</dd>
2996
2997
2998
2999<hr>
3000<dt>
3001 <h4 class="name" id="CB_console"><span class="type-signature"></span>CB_console<span class="signature">(message)</span><span class="type-signature"></span></h4>
3002
3003
3004</dt>
3005<dd>
3006
3007
3008 <div class="description">
3009 <p>Alias for the &quot;console&quot; function which fallbacks to a DOM element with &quot;CB_console&quot; id (its CSS &quot;style&quot; attribute will be modified if needed, which means that its &quot;display&quot; property will be set to &quot;block&quot; if it is &quot;none&quot; and its &quot;visibility&quot; property to &quot;visible&quot; regardless its previous value) or even to an alert when it is not available (&quot;alert&quot; will only be used as a fallback in the case that the <code>CB_console_ALLOW_ALERTS</code> parameter is set to true).</p>
3010 </div>
3011
3012
3013
3014
3015
3016
3017
3018
3019 <h5>Parameters:</h5>
3020
3021
3022<table class="params table table-striped">
3023 <thead>
3024 <tr>
3025
3026 <th style="width:12%; min-width:110px;">Name</th>
3027
3028
3029 <th style="width:12%; min-width:110px;">Type</th>
3030
3031
3032
3033
3034
3035 <th class="last" style="min-width:310px;">Description</th>
3036 </tr>
3037 </thead>
3038
3039 <tbody>
3040
3041
3042 <tr>
3043
3044 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>message</code></td>
3045
3046
3047 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
3048
3049
3050<span class="param-type">string</span>
3051
3052
3053
3054
3055 </td>
3056
3057
3058
3059
3060
3061 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Message to display</p></td>
3062 </tr>
3063
3064
3065 </tbody>
3066</table>
3067
3068
3069
3070
3071<dl class="details">
3072
3073
3074
3075
3076
3077
3078
3079
3080
3081
3082
3083
3084
3085
3086
3087
3088
3089
3090
3091
3092
3093
3094
3095
3096
3097
3098
3099
3100
3101 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
3102 <dd class="tag-source">
3103 <ul class="dummy">
3104 <li>
3105 <a href="CrossBrowdy.js.html">CrossBrowdy.js</a>,
3106 <a href="CrossBrowdy.js.html#sunlight-1-line-325">line 325</a>
3107 </li>
3108 </ul>
3109 </dd>
3110
3111
3112
3113
3114
3115
3116
3117 <dt class="tag-todo method-doc-label method-doc-details-label">To Do:</dt>
3118 <dd class="tag-todo">
3119 <ul>
3120 <li>When "console" is not available and it gets polyfilled, allow more parameters (use "arguments").</li>
3121 </ul>
3122 </dd>
3123
3124</dl>
3125
3126
3127
3128
3129
3130
3131
3132
3133
3134
3135
3136
3137
3138
3139
3140</dd>
3141
3142
3143
3144<hr>
3145<dt>
3146 <h4 class="name" id="CB_copyObject"><span class="type-signature"></span>CB_copyObject<span class="signature">(element [, onlyOwn])</span><span class="type-signature"> &rarr; {object}</span></h4>
3147
3148
3149</dt>
3150<dd>
3151
3152
3153 <div class="description">
3154 <p>Returns an object copied from the given one.</p>
3155 </div>
3156
3157
3158
3159
3160
3161
3162
3163
3164 <h5>Parameters:</h5>
3165
3166
3167<table class="params table table-striped">
3168 <thead>
3169 <tr>
3170
3171 <th style="width:12%; min-width:110px;">Name</th>
3172
3173
3174 <th style="width:12%; min-width:110px;">Type</th>
3175
3176
3177 <th style="width:12%; min-width:110px;">Argument</th>
3178
3179
3180
3181 <th style="width:12%; min-width:110px;">Default</th>
3182
3183
3184 <th class="last" style="min-width:310px;">Description</th>
3185 </tr>
3186 </thead>
3187
3188 <tbody>
3189
3190
3191 <tr>
3192
3193 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>element</code></td>
3194
3195
3196 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
3197
3198
3199<span class="param-type">object</span>
3200
3201
3202
3203
3204 </td>
3205
3206
3207 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
3208
3209
3210
3211
3212
3213 </td>
3214
3215
3216
3217 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
3218
3219 </td>
3220
3221
3222 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The element whose properties and values we want to copy. It should be an object.</p></td>
3223 </tr>
3224
3225
3226
3227 <tr>
3228
3229 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>onlyOwn</code></td>
3230
3231
3232 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
3233
3234
3235<span class="param-type">boolean</span>
3236
3237
3238
3239
3240 </td>
3241
3242
3243 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
3244
3245 &lt;optional><br>
3246
3247
3248
3249
3250
3251 </td>
3252
3253
3254
3255 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
3256
3257 false
3258
3259 </td>
3260
3261
3262 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>If the &quot;element&quot; given is not an object, this parameter will be ignored. Otherwise, if it is set to true, it will only have into account the properties which the object has as their own property and have not been inherited (using the <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/hasOwnProperty">Object.hasOwnProperty</a> method).</p></td>
3263 </tr>
3264
3265
3266 </tbody>
3267</table>
3268
3269
3270
3271
3272<dl class="details">
3273
3274
3275
3276
3277
3278
3279
3280
3281
3282
3283
3284
3285
3286
3287
3288
3289
3290
3291
3292
3293
3294
3295
3296
3297
3298
3299
3300
3301
3302 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
3303 <dd class="tag-source">
3304 <ul class="dummy">
3305 <li>
3306 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
3307 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-837">line 837</a>
3308 </li>
3309 </ul>
3310 </dd>
3311
3312
3313
3314
3315
3316
3317
3318</dl>
3319
3320
3321
3322
3323
3324
3325
3326
3327
3328
3329
3330
3331
3332 <h5>Returns:</h5>
3333
3334
3335<div class="param-desc">
3336 <p>Returns an object copied from the given one. Returns an empty object if the given &quot;element&quot; was not an object.</p>
3337</div>
3338
3339
3340
3341<dl>
3342 <dt>
3343 Type
3344 </dt>
3345 <dd>
3346
3347<span class="param-type">object</span>
3348
3349
3350
3351 </dd>
3352</dl>
3353
3354
3355
3356
3357
3358</dd>
3359
3360
3361
3362<hr>
3363<dt>
3364 <h4 class="name" id="CB_countDecimalDigits"><span class="type-signature"></span>CB_countDecimalDigits<span class="signature">()</span><span class="type-signature"></span></h4>
3365
3366
3367</dt>
3368<dd>
3369
3370
3371 <div class="description">
3372 <p>Alias for <a href="global.html#CB_countDecimalPart"><code>CB_countDecimalPart</code></a>.</p>
3373 </div>
3374
3375
3376
3377
3378
3379
3380
3381
3382
3383
3384<dl class="details">
3385
3386
3387
3388
3389
3390
3391
3392
3393
3394
3395
3396
3397
3398
3399
3400
3401
3402
3403
3404
3405
3406
3407
3408
3409
3410
3411
3412
3413
3414 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
3415 <dd class="tag-source">
3416 <ul class="dummy">
3417 <li>
3418 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
3419 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-598">line 598</a>
3420 </li>
3421 </ul>
3422 </dd>
3423
3424
3425
3426
3427
3428 <dt class="tag-see method-doc-label method-doc-details-label">See:</dt>
3429 <dd class="tag-see">
3430 <ul>
3431 <li><a href="global.html#CB_countDecimalPart"><code>CB_countDecimalPart</code></a></li>
3432 </ul>
3433 </dd>
3434
3435
3436
3437</dl>
3438
3439
3440
3441
3442
3443
3444
3445
3446
3447
3448
3449
3450
3451
3452
3453</dd>
3454
3455
3456
3457<hr>
3458<dt>
3459 <h4 class="name" id="CB_countDecimalPart"><span class="type-signature"></span>CB_countDecimalPart<span class="signature">(number)</span><span class="type-signature"> &rarr; {integer}</span></h4>
3460
3461
3462</dt>
3463<dd>
3464
3465
3466 <div class="description">
3467 <p>Returns the number of decimals of the given number. It also works with numbers in exponential notation (as for example '1e-13' which would be 0.0000000000001).</p>
3468 </div>
3469
3470
3471
3472
3473
3474
3475
3476
3477 <h5>Parameters:</h5>
3478
3479
3480<table class="params table table-striped">
3481 <thead>
3482 <tr>
3483
3484 <th style="width:12%; min-width:110px;">Name</th>
3485
3486
3487 <th style="width:12%; min-width:110px;">Type</th>
3488
3489
3490
3491
3492
3493 <th class="last" style="min-width:310px;">Description</th>
3494 </tr>
3495 </thead>
3496
3497 <tbody>
3498
3499
3500 <tr>
3501
3502 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>number</code></td>
3503
3504
3505 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
3506
3507
3508<span class="param-type">integer</span>
3509|
3510
3511<span class="param-type">float</span>
3512|
3513
3514<span class="param-type">string</span>
3515
3516
3517
3518
3519 </td>
3520
3521
3522
3523
3524
3525 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The number whose decimals we want to count. It can be a string.</p></td>
3526 </tr>
3527
3528
3529 </tbody>
3530</table>
3531
3532
3533
3534
3535<dl class="details">
3536
3537
3538
3539
3540
3541
3542
3543
3544
3545
3546
3547
3548
3549
3550
3551
3552
3553
3554
3555
3556
3557
3558
3559
3560
3561
3562
3563
3564
3565 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
3566 <dd class="tag-source">
3567 <ul class="dummy">
3568 <li>
3569 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
3570 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-619">line 619</a>
3571 </li>
3572 </ul>
3573 </dd>
3574
3575
3576
3577
3578
3579
3580
3581</dl>
3582
3583
3584
3585
3586
3587
3588
3589
3590
3591
3592
3593
3594
3595 <h5>Returns:</h5>
3596
3597
3598<div class="param-desc">
3599 <p>Returns zero in the case a non-valid number has been provided. Otherwise, it returns the number of decimals counted.</p>
3600</div>
3601
3602
3603
3604<dl>
3605 <dt>
3606 Type
3607 </dt>
3608 <dd>
3609
3610<span class="param-type">integer</span>
3611
3612
3613
3614 </dd>
3615</dl>
3616
3617
3618
3619
3620
3621</dd>
3622
3623
3624
3625<hr>
3626<dt>
3627 <h4 class="name" id="CB_countDecimals"><span class="type-signature"></span>CB_countDecimals<span class="signature">()</span><span class="type-signature"></span></h4>
3628
3629
3630</dt>
3631<dd>
3632
3633
3634 <div class="description">
3635 <p>Alias for <a href="global.html#CB_countDecimalPart"><code>CB_countDecimalPart</code></a>.</p>
3636 </div>
3637
3638
3639
3640
3641
3642
3643
3644
3645
3646
3647<dl class="details">
3648
3649
3650
3651
3652
3653
3654
3655
3656
3657
3658
3659
3660
3661
3662
3663
3664
3665
3666
3667
3668
3669
3670
3671
3672
3673
3674
3675
3676
3677 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
3678 <dd class="tag-source">
3679 <ul class="dummy">
3680 <li>
3681 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
3682 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-593">line 593</a>
3683 </li>
3684 </ul>
3685 </dd>
3686
3687
3688
3689
3690
3691 <dt class="tag-see method-doc-label method-doc-details-label">See:</dt>
3692 <dd class="tag-see">
3693 <ul>
3694 <li><a href="global.html#CB_countDecimalPart"><code>CB_countDecimalPart</code></a></li>
3695 </ul>
3696 </dd>
3697
3698
3699
3700</dl>
3701
3702
3703
3704
3705
3706
3707
3708
3709
3710
3711
3712
3713
3714
3715
3716</dd>
3717
3718
3719
3720<hr>
3721<dt>
3722 <h4 class="name" id="CB_countIntegerDigits"><span class="type-signature"></span>CB_countIntegerDigits<span class="signature">()</span><span class="type-signature"></span></h4>
3723
3724
3725</dt>
3726<dd>
3727
3728
3729 <div class="description">
3730 <p>Alias for <a href="global.html#CB_countIntegerPart"><code>CB_countIntegerPart</code></a>.</p>
3731 </div>
3732
3733
3734
3735
3736
3737
3738
3739
3740
3741
3742<dl class="details">
3743
3744
3745
3746
3747
3748
3749
3750
3751
3752
3753
3754
3755
3756
3757
3758
3759
3760
3761
3762
3763
3764
3765
3766
3767
3768
3769
3770
3771
3772 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
3773 <dd class="tag-source">
3774 <ul class="dummy">
3775 <li>
3776 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
3777 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-644">line 644</a>
3778 </li>
3779 </ul>
3780 </dd>
3781
3782
3783
3784
3785
3786 <dt class="tag-see method-doc-label method-doc-details-label">See:</dt>
3787 <dd class="tag-see">
3788 <ul>
3789 <li><a href="global.html#CB_countIntegerPart"><code>CB_countIntegerPart</code></a></li>
3790 </ul>
3791 </dd>
3792
3793
3794
3795</dl>
3796
3797
3798
3799
3800
3801
3802
3803
3804
3805
3806
3807
3808
3809
3810
3811</dd>
3812
3813
3814
3815<hr>
3816<dt>
3817 <h4 class="name" id="CB_countIntegerPart"><span class="type-signature"></span>CB_countIntegerPart<span class="signature">(number)</span><span class="type-signature"> &rarr; {integer}</span></h4>
3818
3819
3820</dt>
3821<dd>
3822
3823
3824 <div class="description">
3825 <p>Returns the number of integer digits (the number of digits that belong to the integer part) of the given number. It also works with numbers in exponential notation (as for example '1e-13' which would be 0.0000000000001).</p>
3826 </div>
3827
3828
3829
3830
3831
3832
3833
3834
3835 <h5>Parameters:</h5>
3836
3837
3838<table class="params table table-striped">
3839 <thead>
3840 <tr>
3841
3842 <th style="width:12%; min-width:110px;">Name</th>
3843
3844
3845 <th style="width:12%; min-width:110px;">Type</th>
3846
3847
3848
3849
3850
3851 <th class="last" style="min-width:310px;">Description</th>
3852 </tr>
3853 </thead>
3854
3855 <tbody>
3856
3857
3858 <tr>
3859
3860 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>number</code></td>
3861
3862
3863 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
3864
3865
3866<span class="param-type">integer</span>
3867|
3868
3869<span class="param-type">float</span>
3870|
3871
3872<span class="param-type">string</span>
3873
3874
3875
3876
3877 </td>
3878
3879
3880
3881
3882
3883 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The number whose integer digits (the digits that belong to the integer part) we want to count. It can be a string.</p></td>
3884 </tr>
3885
3886
3887 </tbody>
3888</table>
3889
3890
3891
3892
3893<dl class="details">
3894
3895
3896
3897
3898
3899
3900
3901
3902
3903
3904
3905
3906
3907
3908
3909
3910
3911
3912
3913
3914
3915
3916
3917
3918
3919
3920
3921
3922
3923 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
3924 <dd class="tag-source">
3925 <ul class="dummy">
3926 <li>
3927 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
3928 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-655">line 655</a>
3929 </li>
3930 </ul>
3931 </dd>
3932
3933
3934
3935
3936
3937
3938
3939</dl>
3940
3941
3942
3943
3944
3945
3946
3947
3948
3949
3950
3951
3952
3953 <h5>Returns:</h5>
3954
3955
3956<div class="param-desc">
3957 <p>Returns zero in the case a non-valid number has been provided. Otherwise, it returns the number of integer digits (the number of digits that belong to the integer part) counted.</p>
3958</div>
3959
3960
3961
3962<dl>
3963 <dt>
3964 Type
3965 </dt>
3966 <dd>
3967
3968<span class="param-type">integer</span>
3969
3970
3971
3972 </dd>
3973</dl>
3974
3975
3976
3977
3978
3979</dd>
3980
3981
3982
3983<hr>
3984<dt>
3985 <h4 class="name" id="CB_credits"><span class="type-signature"></span>CB_credits<span class="signature">( [credits] [, html] [, showPrefix])</span><span class="type-signature"> &rarr; {string}</span></h4>
3986
3987
3988</dt>
3989<dd>
3990
3991
3992 <div class="description">
3993 <p>Returns the credits with the desired format.</p>
3994 </div>
3995
3996
3997
3998
3999
4000
4001
4002
4003 <h5>Parameters:</h5>
4004
4005
4006<table class="params table table-striped">
4007 <thead>
4008 <tr>
4009
4010 <th style="width:12%; min-width:110px;">Name</th>
4011
4012
4013 <th style="width:12%; min-width:110px;">Type</th>
4014
4015
4016 <th style="width:12%; min-width:110px;">Argument</th>
4017
4018
4019
4020 <th style="width:12%; min-width:110px;">Default</th>
4021
4022
4023 <th class="last" style="min-width:310px;">Description</th>
4024 </tr>
4025 </thead>
4026
4027 <tbody>
4028
4029
4030 <tr>
4031
4032 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>credits</code></td>
4033
4034
4035 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
4036
4037
4038<span class="param-type">string</span>
4039
4040
4041
4042
4043 </td>
4044
4045
4046 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
4047
4048 &lt;optional><br>
4049
4050
4051
4052
4053
4054 </td>
4055
4056
4057
4058 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
4059
4060 <a href="global.html#CB_CREDITS_DEFAULT"><code>CB_CREDITS_DEFAULT</code></a>
4061
4062 </td>
4063
4064
4065 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Desired credits to be shown.</p></td>
4066 </tr>
4067
4068
4069
4070 <tr>
4071
4072 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>html</code></td>
4073
4074
4075 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
4076
4077
4078<span class="param-type">boolean</span>
4079
4080
4081
4082
4083 </td>
4084
4085
4086 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
4087
4088 &lt;optional><br>
4089
4090
4091
4092
4093
4094 </td>
4095
4096
4097
4098 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
4099
4100 true
4101
4102 </td>
4103
4104
4105 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Strips all HTML tags (if any) when it is false.</p></td>
4106 </tr>
4107
4108
4109
4110 <tr>
4111
4112 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>showPrefix</code></td>
4113
4114
4115 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
4116
4117
4118<span class="param-type">boolean</span>
4119
4120
4121
4122
4123 </td>
4124
4125
4126 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
4127
4128 &lt;optional><br>
4129
4130
4131
4132
4133
4134 </td>
4135
4136
4137
4138 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
4139
4140 true
4141
4142 </td>
4143
4144
4145 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Defines whether to show the &quot;[CB]&quot; prefix for every line or not (it will remove all &quot;[CB]&quot; occurrences if it is false).</p></td>
4146 </tr>
4147
4148
4149 </tbody>
4150</table>
4151
4152
4153
4154
4155<dl class="details">
4156
4157
4158
4159
4160
4161
4162
4163
4164
4165
4166
4167
4168
4169
4170
4171
4172
4173
4174
4175
4176
4177
4178
4179
4180
4181
4182
4183
4184
4185 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
4186 <dd class="tag-source">
4187 <ul class="dummy">
4188 <li>
4189 <a href="CrossBrowdy.js.html">CrossBrowdy.js</a>,
4190 <a href="CrossBrowdy.js.html#sunlight-1-line-1122">line 1122</a>
4191 </li>
4192 </ul>
4193 </dd>
4194
4195
4196
4197
4198
4199
4200
4201</dl>
4202
4203
4204
4205
4206
4207
4208
4209
4210
4211
4212
4213
4214
4215 <h5>Returns:</h5>
4216
4217
4218
4219
4220<dl>
4221 <dt>
4222 Type
4223 </dt>
4224 <dd>
4225
4226<span class="param-type">string</span>
4227
4228
4229
4230 </dd>
4231</dl>
4232
4233
4234
4235
4236
4237</dd>
4238
4239
4240
4241<hr>
4242<dt>
4243 <h4 class="name" id="CB_forceString"><span class="type-signature"></span>CB_forceString<span class="signature">(element)</span><span class="type-signature"> &rarr; {string}</span></h4>
4244
4245
4246</dt>
4247<dd>
4248
4249
4250 <div class="description">
4251 <p>Returns back the given element if it is a string or an empty string otherwise.</p>
4252 </div>
4253
4254
4255
4256
4257
4258
4259
4260
4261 <h5>Parameters:</h5>
4262
4263
4264<table class="params table table-striped">
4265 <thead>
4266 <tr>
4267
4268 <th style="width:12%; min-width:110px;">Name</th>
4269
4270
4271 <th style="width:12%; min-width:110px;">Type</th>
4272
4273
4274
4275
4276
4277 <th class="last" style="min-width:310px;">Description</th>
4278 </tr>
4279 </thead>
4280
4281 <tbody>
4282
4283
4284 <tr>
4285
4286 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>element</code></td>
4287
4288
4289 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
4290
4291
4292<span class="param-type">*</span>
4293
4294
4295
4296
4297 </td>
4298
4299
4300
4301
4302
4303 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The element that will be checked.</p></td>
4304 </tr>
4305
4306
4307 </tbody>
4308</table>
4309
4310
4311
4312
4313<dl class="details">
4314
4315
4316
4317
4318
4319
4320
4321
4322
4323
4324
4325
4326
4327
4328
4329
4330
4331
4332
4333
4334
4335
4336
4337
4338
4339
4340
4341
4342
4343 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
4344 <dd class="tag-source">
4345 <ul class="dummy">
4346 <li>
4347 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
4348 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-238">line 238</a>
4349 </li>
4350 </ul>
4351 </dd>
4352
4353
4354
4355
4356
4357
4358
4359</dl>
4360
4361
4362
4363
4364
4365
4366
4367
4368
4369
4370
4371
4372
4373 <h5>Returns:</h5>
4374
4375
4376
4377
4378<dl>
4379 <dt>
4380 Type
4381 </dt>
4382 <dd>
4383
4384<span class="param-type">string</span>
4385
4386
4387
4388 </dd>
4389</dl>
4390
4391
4392
4393
4394
4395</dd>
4396
4397
4398
4399<hr>
4400<dt>
4401 <h4 class="name" id="CB_forEach"><span class="type-signature"></span>CB_forEach<span class="signature">(array, callback [, thisArg] [, extendedDOM])</span><span class="type-signature"> &rarr; {array|undefined}</span></h4>
4402
4403
4404</dt>
4405<dd>
4406
4407
4408 <div class="description">
4409 <p>Implementation of the <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/forEach">Array.forEach</a> method for browsers that do not support it natively.<br> <br><br> Executes a function for each element of a given array.</p>
4410 </div>
4411
4412
4413
4414
4415
4416
4417
4418
4419 <h5>Parameters:</h5>
4420
4421
4422<table class="params table table-striped">
4423 <thead>
4424 <tr>
4425
4426 <th style="width:12%; min-width:110px;">Name</th>
4427
4428
4429 <th style="width:12%; min-width:110px;">Type</th>
4430
4431
4432 <th style="width:12%; min-width:110px;">Argument</th>
4433
4434
4435
4436 <th style="width:12%; min-width:110px;">Default</th>
4437
4438
4439 <th class="last" style="min-width:310px;">Description</th>
4440 </tr>
4441 </thead>
4442
4443 <tbody>
4444
4445
4446 <tr>
4447
4448 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>array</code></td>
4449
4450
4451 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
4452
4453
4454<span class="param-type">array</span>
4455
4456
4457
4458
4459 </td>
4460
4461
4462 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
4463
4464
4465
4466
4467
4468 </td>
4469
4470
4471
4472 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
4473
4474 </td>
4475
4476
4477 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Desired array.</p></td>
4478 </tr>
4479
4480
4481
4482 <tr>
4483
4484 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>callback</code></td>
4485
4486
4487 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
4488
4489
4490<span class="param-type">function</span>
4491
4492
4493
4494
4495 </td>
4496
4497
4498 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
4499
4500
4501
4502
4503
4504 </td>
4505
4506
4507
4508 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
4509
4510 </td>
4511
4512
4513 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Function that will be executed for each element of the given array. Following the same rules as the native <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/forEach">Array.forEach</a> method, it will receive three arguments: currentValue, currentIndex and the array given.</p></td>
4514 </tr>
4515
4516
4517
4518 <tr>
4519
4520 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>thisArg</code></td>
4521
4522
4523 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
4524
4525
4526<span class="param-type">*</span>
4527
4528
4529
4530
4531 </td>
4532
4533
4534 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
4535
4536 &lt;optional><br>
4537
4538
4539
4540
4541
4542 </td>
4543
4544
4545
4546 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
4547
4548 </td>
4549
4550
4551 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Value that will be passed as &quot;this&quot; every time the function is called.</p></td>
4552 </tr>
4553
4554
4555
4556 <tr>
4557
4558 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>extendedDOM</code></td>
4559
4560
4561 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
4562
4563
4564<span class="param-type">boolean</span>
4565
4566
4567
4568
4569 </td>
4570
4571
4572 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
4573
4574 &lt;optional><br>
4575
4576
4577
4578
4579
4580 </td>
4581
4582
4583
4584 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
4585
4586 false
4587
4588 </td>
4589
4590
4591 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Defines whether the function is being called by a native function which was extended. Internal usage recommended only.</p></td>
4592 </tr>
4593
4594
4595 </tbody>
4596</table>
4597
4598
4599
4600
4601<dl class="details">
4602
4603
4604
4605
4606
4607
4608
4609
4610
4611
4612
4613
4614
4615
4616
4617
4618
4619
4620
4621
4622
4623
4624
4625
4626
4627
4628
4629
4630
4631 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
4632 <dd class="tag-source">
4633 <ul class="dummy">
4634 <li>
4635 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
4636 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-136">line 136</a>
4637 </li>
4638 </ul>
4639 </dd>
4640
4641
4642
4643
4644
4645
4646
4647</dl>
4648
4649
4650
4651
4652
4653
4654
4655
4656
4657
4658
4659
4660
4661 <h5>Returns:</h5>
4662
4663
4664<div class="param-desc">
4665 <p>If the &quot;extendedDOM&quot; parameter is set to false, returns the given &quot;array&quot; again. Otherwise, returns undefined.</p>
4666</div>
4667
4668
4669
4670<dl>
4671 <dt>
4672 Type
4673 </dt>
4674 <dd>
4675
4676<span class="param-type">array</span>
4677|
4678
4679<span class="param-type">undefined</span>
4680
4681
4682
4683 </dd>
4684</dl>
4685
4686
4687
4688
4689
4690</dd>
4691
4692
4693
4694<hr>
4695<dt>
4696 <h4 class="name" id="CB_getBase64StringObject"><span class="type-signature"></span>CB_getBase64StringObject<span class="signature">()</span><span class="type-signature"> &rarr; {Object}</span></h4>
4697
4698
4699</dt>
4700<dd>
4701
4702
4703 <div class="description">
4704 <p>Returns the &quot;Base64String&quot; object (used by the base64-string library included in <a href="http://pieroxy.net/blog/pages/lz-string/index.html">lz-string</a>), if any. Useful for compressing/decompressing base64 code.</p>
4705 </div>
4706
4707
4708
4709
4710
4711
4712
4713
4714
4715
4716<dl class="details">
4717
4718
4719
4720
4721
4722
4723
4724
4725
4726
4727
4728
4729
4730
4731
4732
4733
4734
4735
4736
4737
4738
4739
4740
4741
4742
4743
4744
4745
4746 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
4747 <dd class="tag-source">
4748 <ul class="dummy">
4749 <li>
4750 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
4751 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-1495">line 1495</a>
4752 </li>
4753 </ul>
4754 </dd>
4755
4756
4757
4758
4759
4760
4761
4762</dl>
4763
4764
4765
4766
4767
4768
4769
4770
4771
4772
4773
4774
4775
4776 <h5>Returns:</h5>
4777
4778
4779<div class="param-desc">
4780 <p>Returns the &quot;Base64String&quot; object (used by the base64-string library included in <a href="http://pieroxy.net/blog/pages/lz-string/index.html">lz-string</a>) if available or null otherwise.</p>
4781</div>
4782
4783
4784
4785<dl>
4786 <dt>
4787 Type
4788 </dt>
4789 <dd>
4790
4791<span class="param-type">Object</span>
4792
4793
4794
4795 </dd>
4796</dl>
4797
4798
4799
4800
4801
4802</dd>
4803
4804
4805
4806<hr>
4807<dt>
4808 <h4 class="name" id="CB_getCookie"><span class="type-signature"></span>CB_getCookie<span class="signature">(index)</span><span class="type-signature"> &rarr; {string|null}</span></h4>
4809
4810
4811</dt>
4812<dd>
4813
4814
4815 <div class="description">
4816 <p>Returns, from its index, a previous stored cookie.</p>
4817 </div>
4818
4819
4820
4821
4822
4823
4824
4825
4826 <h5>Parameters:</h5>
4827
4828
4829<table class="params table table-striped">
4830 <thead>
4831 <tr>
4832
4833 <th style="width:12%; min-width:110px;">Name</th>
4834
4835
4836 <th style="width:12%; min-width:110px;">Type</th>
4837
4838
4839
4840
4841
4842 <th class="last" style="min-width:310px;">Description</th>
4843 </tr>
4844 </thead>
4845
4846 <tbody>
4847
4848
4849 <tr>
4850
4851 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>index</code></td>
4852
4853
4854 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
4855
4856
4857<span class="param-type">string</span>
4858
4859
4860
4861
4862 </td>
4863
4864
4865
4866
4867
4868 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The index whose value we want to retrieve.</p></td>
4869 </tr>
4870
4871
4872 </tbody>
4873</table>
4874
4875
4876
4877
4878<dl class="details">
4879
4880
4881
4882
4883
4884
4885
4886
4887
4888
4889
4890
4891
4892
4893
4894
4895
4896
4897
4898
4899
4900
4901
4902
4903
4904
4905
4906
4907
4908 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
4909 <dd class="tag-source">
4910 <ul class="dummy">
4911 <li>
4912 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
4913 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-809">line 809</a>
4914 </li>
4915 </ul>
4916 </dd>
4917
4918
4919
4920
4921
4922
4923
4924</dl>
4925
4926
4927
4928
4929
4930
4931
4932
4933
4934
4935
4936
4937
4938 <h5>Returns:</h5>
4939
4940
4941<div class="param-desc">
4942 <p>Returns null when the value cannot be found.</p>
4943</div>
4944
4945
4946
4947<dl>
4948 <dt>
4949 Type
4950 </dt>
4951 <dd>
4952
4953<span class="param-type">string</span>
4954|
4955
4956<span class="param-type">null</span>
4957
4958
4959
4960 </dd>
4961</dl>
4962
4963
4964
4965
4966
4967</dd>
4968
4969
4970
4971<hr>
4972<dt>
4973 <h4 class="name" id="CB_getDatum"><span class="type-signature"></span>CB_getDatum<span class="signature">(index [, forceCookie] [, unescapeIndex])</span><span class="type-signature"> &rarr; {string|null}</span></h4>
4974
4975
4976</dt>
4977<dd>
4978
4979
4980 <div class="description">
4981 <p>Gets, from its index, a previous value stored. It will try to get it using <a href="https://developer.mozilla.org/en-US/docs/Web/API/Web_Storage_API">Web Storage API</a> (<a href="https://developer.mozilla.org/en-US/docs/Web/API/Window/localStorage">localStorage</a>). It can use <a href="https://github.com/mortzdk/localStorage">localStorage</a> as a fallback or cookies instead.</p>
4982 </div>
4983
4984
4985
4986
4987
4988
4989
4990
4991 <h5>Parameters:</h5>
4992
4993
4994<table class="params table table-striped">
4995 <thead>
4996 <tr>
4997
4998 <th style="width:12%; min-width:110px;">Name</th>
4999
5000
5001 <th style="width:12%; min-width:110px;">Type</th>
5002
5003
5004 <th style="width:12%; min-width:110px;">Argument</th>
5005
5006
5007
5008 <th style="width:12%; min-width:110px;">Default</th>
5009
5010
5011 <th class="last" style="min-width:310px;">Description</th>
5012 </tr>
5013 </thead>
5014
5015 <tbody>
5016
5017
5018 <tr>
5019
5020 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>index</code></td>
5021
5022
5023 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
5024
5025
5026<span class="param-type">string</span>
5027
5028
5029
5030
5031 </td>
5032
5033
5034 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
5035
5036
5037
5038
5039
5040 </td>
5041
5042
5043
5044 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
5045
5046 </td>
5047
5048
5049 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The index whose value we want to retrieve.</p></td>
5050 </tr>
5051
5052
5053
5054 <tr>
5055
5056 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>forceCookie</code></td>
5057
5058
5059 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
5060
5061
5062<span class="param-type">boolean</span>
5063
5064
5065
5066
5067 </td>
5068
5069
5070 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
5071
5072 &lt;optional><br>
5073
5074
5075
5076
5077
5078 </td>
5079
5080
5081
5082 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
5083
5084 false
5085
5086 </td>
5087
5088
5089 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Forces to use cookies instead of <a href="https://developer.mozilla.org/en-US/docs/Web/API/Web_Storage_API">Web Storage API</a> (<a href="https://developer.mozilla.org/en-US/docs/Web/API/Window/localStorage">localStorage</a>).</p></td>
5090 </tr>
5091
5092
5093
5094 <tr>
5095
5096 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>unescapeIndex</code></td>
5097
5098
5099 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
5100
5101
5102<span class="param-type">boolean</span>
5103
5104
5105
5106
5107 </td>
5108
5109
5110 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
5111
5112 &lt;optional><br>
5113
5114
5115
5116
5117
5118 </td>
5119
5120
5121
5122 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
5123
5124 false
5125
5126 </td>
5127
5128
5129 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Applies the unescape function to the value before returning it. Only applies when cookies are used.</p></td>
5130 </tr>
5131
5132
5133 </tbody>
5134</table>
5135
5136
5137
5138
5139<dl class="details">
5140
5141
5142
5143
5144
5145
5146
5147
5148
5149
5150
5151
5152
5153
5154
5155
5156
5157
5158
5159
5160
5161
5162
5163
5164
5165
5166
5167
5168
5169 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
5170 <dd class="tag-source">
5171 <ul class="dummy">
5172 <li>
5173 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
5174 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-778">line 778</a>
5175 </li>
5176 </ul>
5177 </dd>
5178
5179
5180
5181
5182
5183
5184
5185</dl>
5186
5187
5188
5189
5190
5191
5192
5193
5194
5195
5196
5197
5198
5199 <h5>Returns:</h5>
5200
5201
5202<div class="param-desc">
5203 <p>Returns null when the value cannot be found.</p>
5204</div>
5205
5206
5207
5208<dl>
5209 <dt>
5210 Type
5211 </dt>
5212 <dd>
5213
5214<span class="param-type">string</span>
5215|
5216
5217<span class="param-type">null</span>
5218
5219
5220
5221 </dd>
5222</dl>
5223
5224
5225
5226
5227
5228</dd>
5229
5230
5231
5232<hr>
5233<dt>
5234 <h4 class="name" id="CB_getJSONPropertyValue"><span class="type-signature"></span>CB_getJSONPropertyValue<span class="signature">(JSONObject, property [, returnValueOnFail])</span><span class="type-signature"> &rarr; {*}</span></h4>
5235
5236
5237</dt>
5238<dd>
5239
5240
5241 <div class="description">
5242 <p>Gets the value of a desired property of a given JSON object. Uses the <a href="global.html#CB_getValueIndex"><code>CB_getValueIndex</code></a> function internally.</p>
5243 </div>
5244
5245
5246
5247
5248
5249
5250
5251
5252 <h5>Parameters:</h5>
5253
5254
5255<table class="params table table-striped">
5256 <thead>
5257 <tr>
5258
5259 <th style="width:12%; min-width:110px;">Name</th>
5260
5261
5262 <th style="width:12%; min-width:110px;">Type</th>
5263
5264
5265 <th style="width:12%; min-width:110px;">Argument</th>
5266
5267
5268
5269
5270 <th class="last" style="min-width:310px;">Description</th>
5271 </tr>
5272 </thead>
5273
5274 <tbody>
5275
5276
5277 <tr>
5278
5279 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>JSONObject</code></td>
5280
5281
5282 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
5283
5284
5285<span class="param-type">Object</span>
5286|
5287
5288<span class="param-type">string</span>
5289
5290
5291
5292
5293 </td>
5294
5295
5296 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
5297
5298
5299
5300
5301
5302 </td>
5303
5304
5305
5306
5307 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The JSON object from which we want to get the value. If it is a string, it will try to parse it to create a real object from it. Used as the &quot;object&quot; parameter when calling the <a href="global.html#CB_getValueIndex"><code>CB_getValueIndex</code></a> function internally.</p></td>
5308 </tr>
5309
5310
5311
5312 <tr>
5313
5314 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>property</code></td>
5315
5316
5317 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
5318
5319
5320<span class="param-type">string</span>
5321
5322
5323
5324
5325 </td>
5326
5327
5328 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
5329
5330
5331
5332
5333
5334 </td>
5335
5336
5337
5338
5339 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The property whose value we want to retrieve. If not provided, the given object will be returned again. Used as the &quot;index&quot; parameter when calling the <a href="global.html#CB_getValueIndex"><code>CB_getValueIndex</code></a> function internally.</p></td>
5340 </tr>
5341
5342
5343
5344 <tr>
5345
5346 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>returnValueOnFail</code></td>
5347
5348
5349 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
5350
5351
5352<span class="param-type">*</span>
5353
5354
5355
5356
5357 </td>
5358
5359
5360 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
5361
5362 &lt;optional><br>
5363
5364
5365
5366
5367
5368 </td>
5369
5370
5371
5372
5373 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The value we want it to return in the case it cannot be parsed. If not provided, undefined will be returned. Used as the &quot;returnValueOnFail&quot; parameter when calling the <a href="global.html#CB_getValueIndex"><code>CB_getValueIndex</code></a> function internally.</p></td>
5374 </tr>
5375
5376
5377 </tbody>
5378</table>
5379
5380
5381
5382
5383<dl class="details">
5384
5385
5386
5387
5388
5389
5390
5391
5392
5393
5394
5395
5396
5397
5398
5399
5400
5401
5402
5403
5404
5405
5406
5407
5408
5409
5410
5411
5412
5413 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
5414 <dd class="tag-source">
5415 <ul class="dummy">
5416 <li>
5417 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
5418 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-857">line 857</a>
5419 </li>
5420 </ul>
5421 </dd>
5422
5423
5424
5425
5426
5427
5428
5429</dl>
5430
5431
5432
5433
5434
5435
5436
5437
5438
5439
5440
5441
5442
5443 <h5>Returns:</h5>
5444
5445
5446<div class="param-desc">
5447 <p>Returns the given &quot;JSONObject&quot; again (after trying to parse it if it was a string, if possible) if the &quot;property&quot; value was not given. Returns the value from the given object which belongs to the desired property or the value of &quot;returnValueOnFail&quot; otherwise if it cannot be found.</p>
5448</div>
5449
5450
5451
5452<dl>
5453 <dt>
5454 Type
5455 </dt>
5456 <dd>
5457
5458<span class="param-type">*</span>
5459
5460
5461
5462 </dd>
5463</dl>
5464
5465
5466
5467
5468
5469</dd>
5470
5471
5472
5473<hr>
5474<dt>
5475 <h4 class="name" id="CB_getLZStringObject"><span class="type-signature"></span>CB_getLZStringObject<span class="signature">()</span><span class="type-signature"> &rarr; {Object}</span></h4>
5476
5477
5478</dt>
5479<dd>
5480
5481
5482 <div class="description">
5483 <p>Returns the &quot;LZString&quot; object (used by the <a href="http://pieroxy.net/blog/pages/lz-string/index.html">lz-string</a> library), if any. Useful for compressing/decompressing strings.</p>
5484 </div>
5485
5486
5487
5488
5489
5490
5491
5492
5493
5494
5495<dl class="details">
5496
5497
5498
5499
5500
5501
5502
5503
5504
5505
5506
5507
5508
5509
5510
5511
5512
5513
5514
5515
5516
5517
5518
5519
5520
5521
5522
5523
5524
5525 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
5526 <dd class="tag-source">
5527 <ul class="dummy">
5528 <li>
5529 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
5530 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-1484">line 1484</a>
5531 </li>
5532 </ul>
5533 </dd>
5534
5535
5536
5537
5538
5539
5540
5541</dl>
5542
5543
5544
5545
5546
5547
5548
5549
5550
5551
5552
5553
5554
5555 <h5>Returns:</h5>
5556
5557
5558<div class="param-desc">
5559 <p>Returns the &quot;LZString&quot; object (used by the <a href="http://pieroxy.net/blog/pages/lz-string/index.html">lz-string</a> library) if available or null otherwise.</p>
5560</div>
5561
5562
5563
5564<dl>
5565 <dt>
5566 Type
5567 </dt>
5568 <dd>
5569
5570<span class="param-type">Object</span>
5571
5572
5573
5574 </dd>
5575</dl>
5576
5577
5578
5579
5580
5581</dd>
5582
5583
5584
5585<hr>
5586<dt>
5587 <h4 class="name" id="CB_getValueIndex"><span class="type-signature"></span>CB_getValueIndex<span class="signature">(object, index [, returnValueOnFail])</span><span class="type-signature"> &rarr; {*}</span></h4>
5588
5589
5590</dt>
5591<dd>
5592
5593
5594 <div class="description">
5595 <p>Gets the value from a given object which belongs to the desired index or returns the value of &quot;returnValueOnFail&quot; if it cannot be found.</p>
5596 </div>
5597
5598
5599
5600
5601
5602
5603
5604
5605 <h5>Parameters:</h5>
5606
5607
5608<table class="params table table-striped">
5609 <thead>
5610 <tr>
5611
5612 <th style="width:12%; min-width:110px;">Name</th>
5613
5614
5615 <th style="width:12%; min-width:110px;">Type</th>
5616
5617
5618 <th style="width:12%; min-width:110px;">Argument</th>
5619
5620
5621
5622
5623 <th class="last" style="min-width:310px;">Description</th>
5624 </tr>
5625 </thead>
5626
5627 <tbody>
5628
5629
5630 <tr>
5631
5632 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>object</code></td>
5633
5634
5635 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
5636
5637
5638<span class="param-type">Object</span>
5639
5640
5641
5642
5643 </td>
5644
5645
5646 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
5647
5648
5649
5650
5651
5652 </td>
5653
5654
5655
5656
5657 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The object from which we want to get the value.</p></td>
5658 </tr>
5659
5660
5661
5662 <tr>
5663
5664 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>index</code></td>
5665
5666
5667 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
5668
5669
5670<span class="param-type">string</span>
5671
5672
5673
5674
5675 </td>
5676
5677
5678 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
5679
5680
5681
5682
5683
5684 </td>
5685
5686
5687
5688
5689 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The index whose value we want to retrieve.</p></td>
5690 </tr>
5691
5692
5693
5694 <tr>
5695
5696 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>returnValueOnFail</code></td>
5697
5698
5699 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
5700
5701
5702<span class="param-type">*</span>
5703
5704
5705
5706
5707 </td>
5708
5709
5710 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
5711
5712 &lt;optional><br>
5713
5714
5715
5716
5717
5718 </td>
5719
5720
5721
5722
5723 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The value we want it to return in the case that the property cannot be found. If not provided, undefined will be returned.</p></td>
5724 </tr>
5725
5726
5727 </tbody>
5728</table>
5729
5730
5731
5732
5733<dl class="details">
5734
5735
5736
5737
5738
5739
5740
5741
5742
5743
5744
5745
5746
5747
5748
5749
5750
5751
5752
5753
5754
5755
5756
5757
5758
5759
5760
5761
5762
5763 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
5764 <dd class="tag-source">
5765 <ul class="dummy">
5766 <li>
5767 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
5768 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-823">line 823</a>
5769 </li>
5770 </ul>
5771 </dd>
5772
5773
5774
5775
5776
5777
5778
5779</dl>
5780
5781
5782
5783
5784
5785
5786
5787
5788
5789
5790
5791
5792
5793 <h5>Returns:</h5>
5794
5795
5796<div class="param-desc">
5797 <p>Returns the value from a given object which belongs to the desired index or the value of &quot;returnValueOnFail&quot; otherwise if it cannot be found.</p>
5798</div>
5799
5800
5801
5802<dl>
5803 <dt>
5804 Type
5805 </dt>
5806 <dd>
5807
5808<span class="param-type">*</span>
5809
5810
5811
5812 </dd>
5813</dl>
5814
5815
5816
5817
5818
5819</dd>
5820
5821
5822
5823<hr>
5824<dt>
5825 <h4 class="name" id="CB_getValuePath"><span class="type-signature"></span>CB_getValuePath<span class="signature">(object, path [, splitString])</span><span class="type-signature"> &rarr; {*}</span></h4>
5826
5827
5828</dt>
5829<dd>
5830
5831
5832 <div class="description">
5833 <p>Returns the value of a desired path in an object or an empty string if it cannot be found.</p>
5834 </div>
5835
5836
5837
5838
5839
5840
5841
5842
5843 <h5>Parameters:</h5>
5844
5845
5846<table class="params table table-striped">
5847 <thead>
5848 <tr>
5849
5850 <th style="width:12%; min-width:110px;">Name</th>
5851
5852
5853 <th style="width:12%; min-width:110px;">Type</th>
5854
5855
5856 <th style="width:12%; min-width:110px;">Argument</th>
5857
5858
5859
5860 <th style="width:12%; min-width:110px;">Default</th>
5861
5862
5863 <th class="last" style="min-width:310px;">Description</th>
5864 </tr>
5865 </thead>
5866
5867 <tbody>
5868
5869
5870 <tr>
5871
5872 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>object</code></td>
5873
5874
5875 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
5876
5877
5878<span class="param-type">Object</span>
5879
5880
5881
5882
5883 </td>
5884
5885
5886 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
5887
5888
5889
5890
5891
5892 </td>
5893
5894
5895
5896 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
5897
5898 </td>
5899
5900
5901 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The object where we want to find the path.</p></td>
5902 </tr>
5903
5904
5905
5906 <tr>
5907
5908 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>path</code></td>
5909
5910
5911 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
5912
5913
5914<span class="param-type">string</span>
5915
5916
5917
5918
5919 </td>
5920
5921
5922 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
5923
5924
5925
5926
5927
5928 </td>
5929
5930
5931
5932 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
5933
5934 </td>
5935
5936
5937 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The path that will be search in the given object to retrieve the value. It should use the string defined in the &quot;splitString&quot; parameter to separate items. If it is empty or not provided, it will just return the given &quot;object&quot; again.</p></td>
5938 </tr>
5939
5940
5941
5942 <tr>
5943
5944 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>splitString</code></td>
5945
5946
5947 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
5948
5949
5950<span class="param-type">string</span>
5951
5952
5953
5954
5955 </td>
5956
5957
5958 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
5959
5960 &lt;optional><br>
5961
5962
5963
5964
5965
5966 </td>
5967
5968
5969
5970 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
5971
5972 "."
5973
5974 </td>
5975
5976
5977 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The string that will be used to separate one item from another one. By default, it will be a dot (&quot;.&quot;) so, for example, a given &quot;path&quot; with a value of &quot;hello.world&quot; will indicate the &quot;object.hello.world&quot; path.</p></td>
5978 </tr>
5979
5980
5981 </tbody>
5982</table>
5983
5984
5985
5986
5987<dl class="details">
5988
5989
5990
5991
5992
5993
5994
5995
5996
5997
5998
5999
6000
6001
6002
6003
6004
6005
6006
6007
6008
6009
6010
6011
6012
6013
6014
6015
6016
6017 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
6018 <dd class="tag-source">
6019 <ul class="dummy">
6020 <li>
6021 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
6022 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-684">line 684</a>
6023 </li>
6024 </ul>
6025 </dd>
6026
6027
6028
6029
6030
6031
6032
6033</dl>
6034
6035
6036
6037
6038
6039
6040
6041
6042
6043
6044
6045
6046
6047 <h5>Returns:</h5>
6048
6049
6050<div class="param-desc">
6051 <p>Returns the value of a desired path in an object or an empty string if it cannot be found. If the &quot;path&quot; parameter is empty or not provided, it will just return the given &quot;object&quot; again.</p>
6052</div>
6053
6054
6055
6056<dl>
6057 <dt>
6058 Type
6059 </dt>
6060 <dd>
6061
6062<span class="param-type">*</span>
6063
6064
6065
6066 </dd>
6067</dl>
6068
6069
6070
6071
6072
6073</dd>
6074
6075
6076
6077<hr>
6078<dt>
6079 <h4 class="name" id="CB_includeJSFile"><span class="type-signature"></span>CB_includeJSFile<span class="signature">(filepath [, callbackOk] [, callbackError] [, timeoutMs] [, asynchronously] [, fileId] [, fileRequires] [, notMandatory])</span><span class="type-signature"> &rarr; {Object|null|false}</span></h4>
6080
6081
6082</dt>
6083<dd>
6084
6085
6086 <div class="description">
6087 <p>Includes a JavaScript file to the current document.</p>
6088 </div>
6089
6090
6091
6092
6093
6094
6095
6096
6097 <h5>Parameters:</h5>
6098
6099
6100<table class="params table table-striped">
6101 <thead>
6102 <tr>
6103
6104 <th style="width:12%; min-width:110px;">Name</th>
6105
6106
6107 <th style="width:12%; min-width:110px;">Type</th>
6108
6109
6110 <th style="width:12%; min-width:110px;">Argument</th>
6111
6112
6113
6114 <th style="width:12%; min-width:110px;">Default</th>
6115
6116
6117 <th class="last" style="min-width:310px;">Description</th>
6118 </tr>
6119 </thead>
6120
6121 <tbody>
6122
6123
6124 <tr>
6125
6126 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>filepath</code></td>
6127
6128
6129 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6130
6131
6132<span class="param-type">string</span>
6133
6134
6135
6136
6137 </td>
6138
6139
6140 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6141
6142
6143
6144
6145
6146 </td>
6147
6148
6149
6150 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6151
6152 </td>
6153
6154
6155 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Path to the JS file.</p></td>
6156 </tr>
6157
6158
6159
6160 <tr>
6161
6162 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>callbackOk</code></td>
6163
6164
6165 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6166
6167
6168<span class="param-type"><a href="global.html#CB_includeJSFile_CALLBACK">CB_includeJSFile_CALLBACK</a></span>
6169
6170
6171
6172
6173 </td>
6174
6175
6176 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6177
6178 &lt;optional><br>
6179
6180
6181
6182
6183
6184 </td>
6185
6186
6187
6188 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6189
6190 </td>
6191
6192
6193 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Callback for when the file is included successfully.</p></td>
6194 </tr>
6195
6196
6197
6198 <tr>
6199
6200 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>callbackError</code></td>
6201
6202
6203 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6204
6205
6206<span class="param-type"><a href="global.html#CB_includeJSFile_CALLBACK">CB_includeJSFile_CALLBACK</a></span>
6207
6208
6209
6210
6211 </td>
6212
6213
6214 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6215
6216 &lt;optional><br>
6217
6218
6219
6220
6221
6222 </td>
6223
6224
6225
6226 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6227
6228 </td>
6229
6230
6231 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Callback for when there is any error including the file or it cannot be included after the defined timeout.</p></td>
6232 </tr>
6233
6234
6235
6236 <tr>
6237
6238 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>timeoutMs</code></td>
6239
6240
6241 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6242
6243
6244<span class="param-type">integer</span>
6245
6246
6247
6248
6249 </td>
6250
6251
6252 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6253
6254 &lt;optional><br>
6255
6256
6257
6258
6259
6260 </td>
6261
6262
6263
6264 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6265
6266 <a href="CB_Configuration.CrossBrowdy.html#.CB_includeJSFile_TIMEOUT_MS_DEFAULT"><code>CB_Configuration.CrossBrowdy.CB_includeJSFile_TIMEOUT_MS_DEFAULT</code></a>
6267
6268 </td>
6269
6270
6271 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Timeout in milliseconds to consider that the inclusion of the file has failed.</p></td>
6272 </tr>
6273
6274
6275
6276 <tr>
6277
6278 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>asynchronously</code></td>
6279
6280
6281 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6282
6283
6284<span class="param-type">boolean</span>
6285
6286
6287
6288
6289 </td>
6290
6291
6292 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6293
6294 &lt;optional><br>
6295
6296
6297
6298
6299
6300 </td>
6301
6302
6303
6304 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6305
6306 true
6307
6308 </td>
6309
6310
6311 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Defines whether to load the file asynchronously or not.</p></td>
6312 </tr>
6313
6314
6315
6316 <tr>
6317
6318 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>fileId</code></td>
6319
6320
6321 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6322
6323
6324<span class="param-type">string</span>
6325
6326
6327
6328
6329 </td>
6330
6331
6332 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6333
6334 &lt;optional><br>
6335
6336
6337
6338
6339
6340 </td>
6341
6342
6343
6344 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6345
6346 </td>
6347
6348
6349 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Internal usage recommended only.</p></td>
6350 </tr>
6351
6352
6353
6354 <tr>
6355
6356 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>fileRequires</code></td>
6357
6358
6359 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6360
6361
6362<span class="param-type">array</span>
6363
6364
6365
6366
6367 </td>
6368
6369
6370 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6371
6372 &lt;optional><br>
6373
6374
6375
6376
6377
6378 </td>
6379
6380
6381
6382 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6383
6384 </td>
6385
6386
6387 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Internal usage recommended only.</p></td>
6388 </tr>
6389
6390
6391
6392 <tr>
6393
6394 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>notMandatory</code></td>
6395
6396
6397 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6398
6399
6400<span class="param-type">boolean</span>
6401
6402
6403
6404
6405 </td>
6406
6407
6408 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6409
6410 &lt;optional><br>
6411
6412
6413
6414
6415
6416 </td>
6417
6418
6419
6420 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6421
6422 false
6423
6424 </td>
6425
6426
6427 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Internal usage recommended only.</p></td>
6428 </tr>
6429
6430
6431 </tbody>
6432</table>
6433
6434
6435
6436
6437<dl class="details">
6438
6439
6440
6441
6442
6443
6444
6445
6446
6447
6448
6449
6450
6451
6452
6453
6454
6455
6456
6457
6458
6459
6460
6461
6462
6463
6464
6465
6466
6467 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
6468 <dd class="tag-source">
6469 <ul class="dummy">
6470 <li>
6471 <a href="CrossBrowdy.js.html">CrossBrowdy.js</a>,
6472 <a href="CrossBrowdy.js.html#sunlight-1-line-383">line 383</a>
6473 </li>
6474 </ul>
6475 </dd>
6476
6477
6478
6479
6480
6481
6482
6483</dl>
6484
6485
6486
6487
6488
6489
6490
6491
6492
6493
6494
6495
6496
6497 <h5>Returns:</h5>
6498
6499
6500<div class="param-desc">
6501 <p>Returns null when the script file cannot be loaded yet as some required file has still not been loaded. Returns false when neither the 'HEAD' tag nor the document body can be found. Otherwise, returns an object whose two properties are 'scriptElement' (with the <a href="https://developer.mozilla.org/en-US/docs/Web/HTML/Element/script">SCRIPT</a> element just created) and 'timeoutFailure' (with the <a href="https://developer.mozilla.org/en-US/docs/Web/API/WindowOrWorkerGlobalScope/setTimeout">setTimeout</a> ID created to check whether the file cannot be loaded after the given time).</p>
6502</div>
6503
6504
6505
6506<dl>
6507 <dt>
6508 Type
6509 </dt>
6510 <dd>
6511
6512<span class="param-type">Object</span>
6513|
6514
6515<span class="param-type">null</span>
6516|
6517
6518<span class="param-type">false</span>
6519
6520
6521
6522 </dd>
6523</dl>
6524
6525
6526
6527
6528
6529</dd>
6530
6531
6532
6533<hr>
6534<dt>
6535 <h4 class="name" id="CB_indexOf"><span class="type-signature"></span>CB_indexOf<span class="signature">(array, searchElement [, fromIndex] [, extendedDOM])</span><span class="type-signature"> &rarr; {integer}</span></h4>
6536
6537
6538</dt>
6539<dd>
6540
6541
6542 <div class="description">
6543 <p>Implementation of <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/indexOf">Array.indexOf</a> method for arrays in browsers that do not support it natively.<br> <br><br> Returns the first index of a given element that exists in an array (starting from a certain index if desired) or -1 if not found.</p>
6544 </div>
6545
6546
6547
6548
6549
6550
6551
6552
6553 <h5>Parameters:</h5>
6554
6555
6556<table class="params table table-striped">
6557 <thead>
6558 <tr>
6559
6560 <th style="width:12%; min-width:110px;">Name</th>
6561
6562
6563 <th style="width:12%; min-width:110px;">Type</th>
6564
6565
6566 <th style="width:12%; min-width:110px;">Argument</th>
6567
6568
6569
6570 <th style="width:12%; min-width:110px;">Default</th>
6571
6572
6573 <th class="last" style="min-width:310px;">Description</th>
6574 </tr>
6575 </thead>
6576
6577 <tbody>
6578
6579
6580 <tr>
6581
6582 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>array</code></td>
6583
6584
6585 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6586
6587
6588<span class="param-type">array</span>
6589
6590
6591
6592
6593 </td>
6594
6595
6596 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6597
6598
6599
6600
6601
6602 </td>
6603
6604
6605
6606 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6607
6608 </td>
6609
6610
6611 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Desired array.</p></td>
6612 </tr>
6613
6614
6615
6616 <tr>
6617
6618 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>searchElement</code></td>
6619
6620
6621 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6622
6623
6624<span class="param-type">*</span>
6625
6626
6627
6628
6629 </td>
6630
6631
6632 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6633
6634
6635
6636
6637
6638 </td>
6639
6640
6641
6642 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6643
6644 </td>
6645
6646
6647 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Element we want to search. Note that it is type sensitive.</p></td>
6648 </tr>
6649
6650
6651
6652 <tr>
6653
6654 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>fromIndex</code></td>
6655
6656
6657 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6658
6659
6660<span class="param-type">integer</span>
6661
6662
6663
6664
6665 </td>
6666
6667
6668 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6669
6670 &lt;optional><br>
6671
6672
6673
6674
6675
6676 </td>
6677
6678
6679
6680 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6681
6682 0
6683
6684 </td>
6685
6686
6687 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>First index of the given array where the search will start.</p></td>
6688 </tr>
6689
6690
6691
6692 <tr>
6693
6694 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>extendedDOM</code></td>
6695
6696
6697 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6698
6699
6700<span class="param-type">boolean</span>
6701
6702
6703
6704
6705 </td>
6706
6707
6708 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6709
6710 &lt;optional><br>
6711
6712
6713
6714
6715
6716 </td>
6717
6718
6719
6720 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6721
6722 false
6723
6724 </td>
6725
6726
6727 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Defines whether the function is being called by a native function which was extended. Internal usage recommended only.</p></td>
6728 </tr>
6729
6730
6731 </tbody>
6732</table>
6733
6734
6735
6736
6737<dl class="details">
6738
6739
6740
6741
6742
6743
6744
6745
6746
6747
6748
6749
6750
6751
6752
6753
6754
6755
6756
6757
6758
6759
6760
6761
6762
6763
6764
6765
6766
6767 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
6768 <dd class="tag-source">
6769 <ul class="dummy">
6770 <li>
6771 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
6772 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-87">line 87</a>
6773 </li>
6774 </ul>
6775 </dd>
6776
6777
6778
6779
6780
6781
6782
6783</dl>
6784
6785
6786
6787
6788
6789
6790
6791
6792
6793
6794
6795
6796
6797 <h5>Returns:</h5>
6798
6799
6800
6801
6802<dl>
6803 <dt>
6804 Type
6805 </dt>
6806 <dd>
6807
6808<span class="param-type">integer</span>
6809
6810
6811
6812 </dd>
6813</dl>
6814
6815
6816
6817
6818
6819</dd>
6820
6821
6822
6823<hr>
6824<dt>
6825 <h4 class="name" id="CB_init"><span class="type-signature"></span>CB_init<span class="signature">( [mainFunction] [, scriptPath] [, onErrorLoadingFile] [, showSplashScreen])</span><span class="type-signature"></span></h4>
6826
6827
6828</dt>
6829<dd>
6830
6831
6832 <div class="description">
6833 <p>Starts CrossBrowdy.</p>
6834 </div>
6835
6836
6837
6838
6839
6840
6841
6842
6843 <h5>Parameters:</h5>
6844
6845
6846<table class="params table table-striped">
6847 <thead>
6848 <tr>
6849
6850 <th style="width:12%; min-width:110px;">Name</th>
6851
6852
6853 <th style="width:12%; min-width:110px;">Type</th>
6854
6855
6856 <th style="width:12%; min-width:110px;">Argument</th>
6857
6858
6859
6860 <th style="width:12%; min-width:110px;">Default</th>
6861
6862
6863 <th class="last" style="min-width:310px;">Description</th>
6864 </tr>
6865 </thead>
6866
6867 <tbody>
6868
6869
6870 <tr>
6871
6872 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>mainFunction</code></td>
6873
6874
6875 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6876
6877
6878<span class="param-type"><a href="global.html#CB_init_CALLBACK">CB_init_CALLBACK</a></span>
6879
6880
6881
6882
6883 </td>
6884
6885
6886 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6887
6888 &lt;optional><br>
6889
6890
6891
6892
6893
6894 </td>
6895
6896
6897
6898 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6899
6900 </td>
6901
6902
6903 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Callback for when CrossBrowdy is loaded successfully. Recommended.</p></td>
6904 </tr>
6905
6906
6907
6908 <tr>
6909
6910 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>scriptPath</code></td>
6911
6912
6913 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6914
6915
6916<span class="param-type">string</span>
6917
6918
6919
6920
6921 </td>
6922
6923
6924 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6925
6926 &lt;optional><br>
6927
6928
6929
6930
6931
6932 </td>
6933
6934
6935
6936 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6937
6938 <a href="global.html#CB_scriptPathCalculate"><code>CB_scriptPathCalculate</code></a>()
6939
6940 </td>
6941
6942
6943 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Path where the main script is located. If not provided (it is undefined or null), it will try to calculate it calling the <a href="global.html#CB_scriptPathCalculate"><code>CB_scriptPathCalculate</code></a> function internally.</p></td>
6944 </tr>
6945
6946
6947
6948 <tr>
6949
6950 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>onErrorLoadingFile</code></td>
6951
6952
6953 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6954
6955
6956<span class="param-type"><a href="global.html#CB_includeRequiredFileErrorCallback">CB_includeRequiredFileErrorCallback</a></span>
6957
6958
6959
6960
6961 </td>
6962
6963
6964 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6965
6966 &lt;optional><br>
6967
6968
6969
6970
6971
6972 </td>
6973
6974
6975
6976 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6977
6978 </td>
6979
6980
6981 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Function to call when any of the required files fails to load (because of an error or because its timeout was fired). It could be called more than once, for each file which failed loading. If a function is provided, it will be stored in the global 'CB_initOnErrorLoadingFile' variable.</p></td>
6982 </tr>
6983
6984
6985
6986 <tr>
6987
6988 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>showSplashScreen</code></td>
6989
6990
6991 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
6992
6993
6994<span class="param-type">boolean</span>
6995
6996
6997
6998
6999 </td>
7000
7001
7002 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
7003
7004 &lt;optional><br>
7005
7006
7007
7008
7009
7010 </td>
7011
7012
7013
7014 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
7015
7016 <a href="CB_Configuration.CrossBrowdy.html#.SHOW_SPLASH_SCREEN_DEFAULT"><code>CB_Configuration.CrossBrowdy.SHOW_SPLASH_SCREEN_DEFAULT</code></a>
7017
7018 </td>
7019
7020
7021 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Defines whether to show the splash screen or not.</p></td>
7022 </tr>
7023
7024
7025 </tbody>
7026</table>
7027
7028
7029
7030
7031<dl class="details">
7032
7033
7034
7035
7036
7037
7038
7039
7040
7041
7042
7043
7044
7045
7046
7047
7048
7049
7050
7051
7052
7053
7054
7055
7056
7057
7058
7059
7060
7061 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
7062 <dd class="tag-source">
7063 <ul class="dummy">
7064 <li>
7065 <a href="CrossBrowdy.js.html">CrossBrowdy.js</a>,
7066 <a href="CrossBrowdy.js.html#sunlight-1-line-1048">line 1048</a>
7067 </li>
7068 </ul>
7069 </dd>
7070
7071
7072
7073
7074
7075
7076
7077</dl>
7078
7079
7080
7081
7082
7083
7084
7085
7086
7087
7088
7089
7090
7091
7092
7093</dd>
7094
7095
7096
7097<hr>
7098<dt>
7099 <h4 class="name" id="CB_intToBase"><span class="type-signature"></span>CB_intToBase<span class="signature">(number [, baseSymbols] [, unsigned] [, minusSymbol] [, prefix])</span><span class="type-signature"> &rarr; {string}</span></h4>
7100
7101
7102</dt>
7103<dd>
7104
7105
7106 <div class="description">
7107 <p>Converts a given integer into a desired base.</p>
7108 </div>
7109
7110
7111
7112
7113
7114
7115
7116
7117 <h5>Parameters:</h5>
7118
7119
7120<table class="params table table-striped">
7121 <thead>
7122 <tr>
7123
7124 <th style="width:12%; min-width:110px;">Name</th>
7125
7126
7127 <th style="width:12%; min-width:110px;">Type</th>
7128
7129
7130 <th style="width:12%; min-width:110px;">Argument</th>
7131
7132
7133
7134 <th style="width:12%; min-width:110px;">Default</th>
7135
7136
7137 <th class="last" style="min-width:310px;">Description</th>
7138 </tr>
7139 </thead>
7140
7141 <tbody>
7142
7143
7144 <tr>
7145
7146 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>number</code></td>
7147
7148
7149 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
7150
7151
7152<span class="param-type">integer</span>
7153|
7154
7155<span class="param-type">string</span>
7156
7157
7158
7159
7160 </td>
7161
7162
7163 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
7164
7165
7166
7167
7168
7169 </td>
7170
7171
7172
7173 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
7174
7175 </td>
7176
7177
7178 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The integer that we want to convert to the desired base. For bigger numbers (up to 999999999999999934464 or even lower, depending on the client and the &quot;baseSymbols&quot; used), it is recommended to use a string which will allow to accept a slightly bigger number (up to 999999999999999999999999 or lower, depending on the client and the &quot;baseSymbols&quot; used). Really big numbers will not be codified properly even when passed as a string due to the limitations of JavaScript engines and maximum number allowed to be stored in a variable.</p></td>
7179 </tr>
7180
7181
7182
7183 <tr>
7184
7185 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>baseSymbols</code></td>
7186
7187
7188 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
7189
7190
7191<span class="param-type">array</span>
7192|
7193
7194<span class="param-type">integer</span>
7195
7196
7197
7198
7199 </td>
7200
7201
7202 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
7203
7204 &lt;optional><br>
7205
7206
7207
7208
7209
7210 </td>
7211
7212
7213
7214 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
7215
7216 <a href="CB_baseSymbols.html#.66"><code>CB_baseSymbols.66</code></a>
7217
7218 </td>
7219
7220
7221 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Array with the desired symbols, using only one per index (their value will correspond to their index). The base (radix) will be the total number of indexes. If an integer greater or equal than 2 is provided, it will try to use it as an index of the <a href="CB_baseSymbols.html"><code>CB_baseSymbols</code></a> object and use it if found or use it as a parameter to call the <a href="CB_baseSymbols.html#.get"><code>CB_baseSymbols.get</code></a> function otherwise. If not provided or the integer is lower than 2, it will use base 66 (defined in the <a href="CB_baseSymbols.html#._66"><code>CB_baseSymbols._66</code></a> property of the <a href="CB_baseSymbols.html"><code>CB_baseSymbols</code></a> object). It is recommended not to exceed 4096 (or even lower, depending on the client, although some clients could support up to 63988 or even more). The properties of the <a href="CB_baseSymbols.html"><code>CB_baseSymbols</code></a> object or the <a href="CB_baseSymbols.html#.get"><code>CB_baseSymbols.get</code></a> function can be used for this parameter.</p></td>
7222 </tr>
7223
7224
7225
7226 <tr>
7227
7228 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>unsigned</code></td>
7229
7230
7231 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
7232
7233
7234<span class="param-type">boolean</span>
7235
7236
7237
7238
7239 </td>
7240
7241
7242 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
7243
7244 &lt;optional><br>
7245
7246
7247
7248
7249
7250 </td>
7251
7252
7253
7254 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
7255
7256 false
7257
7258 </td>
7259
7260
7261 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Determines whether to treat the input and output numbers as unsigned or not.</p></td>
7262 </tr>
7263
7264
7265
7266 <tr>
7267
7268 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>minusSymbol</code></td>
7269
7270
7271 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
7272
7273
7274<span class="param-type">string</span>
7275
7276
7277
7278
7279 </td>
7280
7281
7282 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
7283
7284 &lt;optional><br>
7285
7286
7287
7288
7289
7290 </td>
7291
7292
7293
7294 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
7295
7296 '-'|'0'
7297
7298 </td>
7299
7300
7301 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Determines the minus symbol or string for the output, to mark negative numbers. If not provided, it will be '-' for bases equal or lower than 16 (hexadecimal) or '0' (zero character) otherwise. This parameter is ignored if the &quot;unsigned&quot; parameter is set to true.</p></td>
7302 </tr>
7303
7304
7305
7306 <tr>
7307
7308 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>prefix</code></td>
7309
7310
7311 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
7312
7313
7314<span class="param-type">prefix</span>
7315
7316
7317
7318
7319 </td>
7320
7321
7322 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
7323
7324 &lt;optional><br>
7325
7326
7327
7328
7329
7330 </td>
7331
7332
7333
7334 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
7335
7336 '0'|'0x'|''
7337
7338 </td>
7339
7340
7341 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Determines the prefix for the output. If not provided, it will be '0' (zero character) for base 8 (octal), '0x' for base 16 (hexadecimal) or nothing (empty string) for all the others. Use an empty string to avoid using anything.</p></td>
7342 </tr>
7343
7344
7345 </tbody>
7346</table>
7347
7348
7349
7350
7351<dl class="details">
7352
7353
7354
7355
7356
7357
7358
7359
7360
7361
7362
7363
7364
7365
7366
7367
7368
7369
7370
7371
7372
7373
7374
7375
7376
7377
7378
7379
7380
7381 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
7382 <dd class="tag-source">
7383 <ul class="dummy">
7384 <li>
7385 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
7386 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-1288">line 1288</a>
7387 </li>
7388 </ul>
7389 </dd>
7390
7391
7392
7393
7394
7395
7396
7397 <dt class="tag-todo method-doc-label method-doc-details-label">To Do:</dt>
7398 <dd class="tag-todo">
7399 <ul>
7400 <li>Think about allowing the "number" parameter to be a very long string, for bigger numbers (to exceed the limit for integers). Internally, it would need to perform operations comparisons, divisions, remainder calculation with strings, etc.</li>
7401
7402 <li>Think about allowing to specify the base for the integer (now it is 16 if it begins with "0x", 8 if it begins with "0" and it is not a string or 10 otherwise, and newer clients can support '0b' for binaries, '0o' for octals, ).</li>
7403
7404 <li>Think about accepting a decimal symbol to separate decimals and support float numbers.</li>
7405 </ul>
7406 </dd>
7407
7408</dl>
7409
7410
7411
7412
7413
7414
7415
7416
7417
7418
7419
7420
7421
7422 <h5>Returns:</h5>
7423
7424
7425<div class="param-desc">
7426 <p>Returns an empty string in the case that the given number cannot be parsed as an integer. Otherwise, returns the given number in the desired base as a string.</p>
7427</div>
7428
7429
7430
7431<dl>
7432 <dt>
7433 Type
7434 </dt>
7435 <dd>
7436
7437<span class="param-type">string</span>
7438
7439
7440
7441 </dd>
7442</dl>
7443
7444
7445
7446
7447
7448</dd>
7449
7450
7451
7452<hr>
7453<dt>
7454 <h4 class="name" id="CB_isArray"><span class="type-signature"></span>CB_isArray<span class="signature">(element [, extendedDOM])</span><span class="type-signature"> &rarr; {boolean}</span></h4>
7455
7456
7457</dt>
7458<dd>
7459
7460
7461 <div class="description">
7462 <p>Implementation of <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/isArray">Array.isArray</a> method for browsers that do not support it natively.<br> <br><br> Returns whether a given element is an array or not.</p>
7463 </div>
7464
7465
7466
7467
7468
7469
7470
7471
7472 <h5>Parameters:</h5>
7473
7474
7475<table class="params table table-striped">
7476 <thead>
7477 <tr>
7478
7479 <th style="width:12%; min-width:110px;">Name</th>
7480
7481
7482 <th style="width:12%; min-width:110px;">Type</th>
7483
7484
7485 <th style="width:12%; min-width:110px;">Argument</th>
7486
7487
7488
7489 <th style="width:12%; min-width:110px;">Default</th>
7490
7491
7492 <th class="last" style="min-width:310px;">Description</th>
7493 </tr>
7494 </thead>
7495
7496 <tbody>
7497
7498
7499 <tr>
7500
7501 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>element</code></td>
7502
7503
7504 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
7505
7506
7507<span class="param-type">*</span>
7508
7509
7510
7511
7512 </td>
7513
7514
7515 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
7516
7517
7518
7519
7520
7521 </td>
7522
7523
7524
7525 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
7526
7527 </td>
7528
7529
7530 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The element we want to check.</p></td>
7531 </tr>
7532
7533
7534
7535 <tr>
7536
7537 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>extendedDOM</code></td>
7538
7539
7540 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
7541
7542
7543<span class="param-type">boolean</span>
7544
7545
7546
7547
7548 </td>
7549
7550
7551 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
7552
7553 &lt;optional><br>
7554
7555
7556
7557
7558
7559 </td>
7560
7561
7562
7563 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
7564
7565 false
7566
7567 </td>
7568
7569
7570 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Defines whether the function is being called by a native function which was extended. Internal usage recommended only.</p></td>
7571 </tr>
7572
7573
7574 </tbody>
7575</table>
7576
7577
7578
7579
7580<dl class="details">
7581
7582
7583
7584
7585
7586
7587
7588
7589
7590
7591
7592
7593
7594
7595
7596
7597
7598
7599
7600
7601
7602
7603
7604
7605
7606
7607
7608
7609
7610 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
7611 <dd class="tag-source">
7612 <ul class="dummy">
7613 <li>
7614 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
7615 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-172">line 172</a>
7616 </li>
7617 </ul>
7618 </dd>
7619
7620
7621
7622
7623
7624
7625
7626 <dt class="tag-todo method-doc-label method-doc-details-label">To Do:</dt>
7627 <dd class="tag-todo">
7628 <ul>
7629 <li>Think about a parameter to check whether the given array is a typed array (for example, 'Uint8Array') or not.</li>
7630 </ul>
7631 </dd>
7632
7633</dl>
7634
7635
7636
7637
7638
7639
7640
7641
7642
7643
7644
7645
7646
7647 <h5>Returns:</h5>
7648
7649
7650
7651
7652<dl>
7653 <dt>
7654 Type
7655 </dt>
7656 <dd>
7657
7658<span class="param-type">boolean</span>
7659
7660
7661
7662 </dd>
7663</dl>
7664
7665
7666
7667
7668
7669</dd>
7670
7671
7672
7673<hr>
7674<dt>
7675 <h4 class="name" id="CB_isEmail"><span class="type-signature"></span>CB_isEmail<span class="signature">(email)</span><span class="type-signature"> &rarr; {boolean}</span></h4>
7676
7677
7678</dt>
7679<dd>
7680
7681
7682 <div class="description">
7683 <p>Tells whether a given email is valid or not. Not really precise.</p>
7684 </div>
7685
7686
7687
7688
7689
7690
7691
7692
7693 <h5>Parameters:</h5>
7694
7695
7696<table class="params table table-striped">
7697 <thead>
7698 <tr>
7699
7700 <th style="width:12%; min-width:110px;">Name</th>
7701
7702
7703 <th style="width:12%; min-width:110px;">Type</th>
7704
7705
7706
7707
7708
7709 <th class="last" style="min-width:310px;">Description</th>
7710 </tr>
7711 </thead>
7712
7713 <tbody>
7714
7715
7716 <tr>
7717
7718 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>email</code></td>
7719
7720
7721 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
7722
7723
7724<span class="param-type">string</span>
7725
7726
7727
7728
7729 </td>
7730
7731
7732
7733
7734
7735 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Possible email that we want to validate.</p></td>
7736 </tr>
7737
7738
7739 </tbody>
7740</table>
7741
7742
7743
7744
7745<dl class="details">
7746
7747
7748
7749
7750
7751
7752
7753
7754
7755
7756
7757
7758
7759
7760
7761
7762
7763
7764
7765
7766
7767
7768
7769
7770
7771
7772
7773
7774
7775 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
7776 <dd class="tag-source">
7777 <ul class="dummy">
7778 <li>
7779 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
7780 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-552">line 552</a>
7781 </li>
7782 </ul>
7783 </dd>
7784
7785
7786
7787
7788
7789
7790
7791</dl>
7792
7793
7794
7795
7796
7797
7798
7799
7800
7801
7802
7803
7804
7805 <h5>Returns:</h5>
7806
7807
7808
7809
7810<dl>
7811 <dt>
7812 Type
7813 </dt>
7814 <dd>
7815
7816<span class="param-type">boolean</span>
7817
7818
7819
7820 </dd>
7821</dl>
7822
7823
7824
7825
7826
7827</dd>
7828
7829
7830
7831<hr>
7832<dt>
7833 <h4 class="name" id="CB_isFileLocal"><span class="type-signature"></span>CB_isFileLocal<span class="signature">(filePath)</span><span class="type-signature"> &rarr; {boolean}</span></h4>
7834
7835
7836</dt>
7837<dd>
7838
7839
7840 <div class="description">
7841 <p>Tries to guess whether a given file path (absolute or relative) is a local address or not. It will be assumed as local if the path<br> uses the &quot;file:&quot; protocol or the current script is running locally and the path does not use the &quot;http:&quot;, &quot;https:&quot; or &quot;ftp:&quot; protocols.</p>
7842 </div>
7843
7844
7845
7846
7847
7848
7849
7850
7851 <h5>Parameters:</h5>
7852
7853
7854<table class="params table table-striped">
7855 <thead>
7856 <tr>
7857
7858 <th style="width:12%; min-width:110px;">Name</th>
7859
7860
7861 <th style="width:12%; min-width:110px;">Type</th>
7862
7863
7864
7865
7866
7867 <th class="last" style="min-width:310px;">Description</th>
7868 </tr>
7869 </thead>
7870
7871 <tbody>
7872
7873
7874 <tr>
7875
7876 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>filePath</code></td>
7877
7878
7879 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
7880
7881
7882<span class="param-type">string</span>
7883
7884
7885
7886
7887 </td>
7888
7889
7890
7891
7892
7893 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The file path we want to check.</p></td>
7894 </tr>
7895
7896
7897 </tbody>
7898</table>
7899
7900
7901
7902
7903<dl class="details">
7904
7905
7906
7907
7908
7909
7910
7911
7912
7913
7914
7915
7916
7917
7918
7919
7920
7921
7922
7923
7924
7925
7926
7927
7928
7929
7930
7931
7932
7933 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
7934 <dd class="tag-source">
7935 <ul class="dummy">
7936 <li>
7937 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
7938 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-466">line 466</a>
7939 </li>
7940 </ul>
7941 </dd>
7942
7943
7944
7945
7946
7947
7948
7949</dl>
7950
7951
7952
7953
7954
7955
7956
7957
7958
7959
7960
7961
7962
7963 <h5>Returns:</h5>
7964
7965
7966<div class="param-desc">
7967 <p>Returns whether the given file path is a local address or not.</p>
7968</div>
7969
7970
7971
7972<dl>
7973 <dt>
7974 Type
7975 </dt>
7976 <dd>
7977
7978<span class="param-type">boolean</span>
7979
7980
7981
7982 </dd>
7983</dl>
7984
7985
7986
7987
7988
7989</dd>
7990
7991
7992
7993<hr>
7994<dt>
7995 <h4 class="name" id="CB_isString"><span class="type-signature"></span>CB_isString<span class="signature">(element)</span><span class="type-signature"> &rarr; {boolean}</span></h4>
7996
7997
7998</dt>
7999<dd>
8000
8001
8002 <div class="description">
8003 <p>Returns whether a given element is a string or not.</p>
8004 </div>
8005
8006
8007
8008
8009
8010
8011
8012
8013 <h5>Parameters:</h5>
8014
8015
8016<table class="params table table-striped">
8017 <thead>
8018 <tr>
8019
8020 <th style="width:12%; min-width:110px;">Name</th>
8021
8022
8023 <th style="width:12%; min-width:110px;">Type</th>
8024
8025
8026
8027
8028
8029 <th class="last" style="min-width:310px;">Description</th>
8030 </tr>
8031 </thead>
8032
8033 <tbody>
8034
8035
8036 <tr>
8037
8038 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>element</code></td>
8039
8040
8041 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
8042
8043
8044<span class="param-type">*</span>
8045
8046
8047
8048
8049 </td>
8050
8051
8052
8053
8054
8055 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The element we want to check.</p></td>
8056 </tr>
8057
8058
8059 </tbody>
8060</table>
8061
8062
8063
8064
8065<dl class="details">
8066
8067
8068
8069
8070
8071
8072
8073
8074
8075
8076
8077
8078
8079
8080
8081
8082
8083
8084
8085
8086
8087
8088
8089
8090
8091
8092
8093
8094
8095 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
8096 <dd class="tag-source">
8097 <ul class="dummy">
8098 <li>
8099 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
8100 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-226">line 226</a>
8101 </li>
8102 </ul>
8103 </dd>
8104
8105
8106
8107
8108
8109
8110
8111</dl>
8112
8113
8114
8115
8116
8117
8118
8119
8120
8121
8122
8123
8124
8125 <h5>Returns:</h5>
8126
8127
8128
8129
8130<dl>
8131 <dt>
8132 Type
8133 </dt>
8134 <dd>
8135
8136<span class="param-type">boolean</span>
8137
8138
8139
8140 </dd>
8141</dl>
8142
8143
8144
8145
8146
8147</dd>
8148
8149
8150
8151<hr>
8152<dt>
8153 <h4 class="name" id="CB_lastIndexOf"><span class="type-signature"></span>CB_lastIndexOf<span class="signature">(array, searchElement [, fromIndex] [, extendedDOM])</span><span class="type-signature"> &rarr; {integer}</span></h4>
8154
8155
8156</dt>
8157<dd>
8158
8159
8160 <div class="description">
8161 <p>Implementation of <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/lastIndexOf">Array.lastIndexOf</a> method for browsers that do not support it natively.<br> <br><br> Returns the last index of a given element that exists in an array (starting from a certain index if desired) or -1 if not found.</p>
8162 </div>
8163
8164
8165
8166
8167
8168
8169
8170
8171 <h5>Parameters:</h5>
8172
8173
8174<table class="params table table-striped">
8175 <thead>
8176 <tr>
8177
8178 <th style="width:12%; min-width:110px;">Name</th>
8179
8180
8181 <th style="width:12%; min-width:110px;">Type</th>
8182
8183
8184 <th style="width:12%; min-width:110px;">Argument</th>
8185
8186
8187
8188 <th style="width:12%; min-width:110px;">Default</th>
8189
8190
8191 <th class="last" style="min-width:310px;">Description</th>
8192 </tr>
8193 </thead>
8194
8195 <tbody>
8196
8197
8198 <tr>
8199
8200 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>array</code></td>
8201
8202
8203 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
8204
8205
8206<span class="param-type">array</span>
8207
8208
8209
8210
8211 </td>
8212
8213
8214 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
8215
8216
8217
8218
8219
8220 </td>
8221
8222
8223
8224 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
8225
8226 </td>
8227
8228
8229 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Desired array.</p></td>
8230 </tr>
8231
8232
8233
8234 <tr>
8235
8236 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>searchElement</code></td>
8237
8238
8239 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
8240
8241
8242<span class="param-type">*</span>
8243
8244
8245
8246
8247 </td>
8248
8249
8250 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
8251
8252
8253
8254
8255
8256 </td>
8257
8258
8259
8260 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
8261
8262 </td>
8263
8264
8265 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Element we want to search. Note that it is type sensitive.</p></td>
8266 </tr>
8267
8268
8269
8270 <tr>
8271
8272 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>fromIndex</code></td>
8273
8274
8275 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
8276
8277
8278<span class="param-type">integer</span>
8279
8280
8281
8282
8283 </td>
8284
8285
8286 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
8287
8288 &lt;optional><br>
8289
8290
8291
8292
8293
8294 </td>
8295
8296
8297
8298 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
8299
8300 array.length - 1
8301
8302 </td>
8303
8304
8305 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>First index of the given array where the search will start.</p></td>
8306 </tr>
8307
8308
8309
8310 <tr>
8311
8312 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>extendedDOM</code></td>
8313
8314
8315 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
8316
8317
8318<span class="param-type">boolean</span>
8319
8320
8321
8322
8323 </td>
8324
8325
8326 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
8327
8328 &lt;optional><br>
8329
8330
8331
8332
8333
8334 </td>
8335
8336
8337
8338 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
8339
8340 false
8341
8342 </td>
8343
8344
8345 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Defines whether the function is being called by a native function which was extended. Internal usage recommended only.</p></td>
8346 </tr>
8347
8348
8349 </tbody>
8350</table>
8351
8352
8353
8354
8355<dl class="details">
8356
8357
8358
8359
8360
8361
8362
8363
8364
8365
8366
8367
8368
8369
8370
8371
8372
8373
8374
8375
8376
8377
8378
8379
8380
8381
8382
8383
8384
8385 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
8386 <dd class="tag-source">
8387 <ul class="dummy">
8388 <li>
8389 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
8390 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-38">line 38</a>
8391 </li>
8392 </ul>
8393 </dd>
8394
8395
8396
8397
8398
8399
8400
8401 <dt class="tag-todo method-doc-label method-doc-details-label">To Do:</dt>
8402 <dd class="tag-todo">
8403 <ul>
8404 <li>Implement the "fromIndex" in the polyfill.</li>
8405 </ul>
8406 </dd>
8407
8408</dl>
8409
8410
8411
8412
8413
8414
8415
8416
8417
8418
8419
8420
8421
8422 <h5>Returns:</h5>
8423
8424
8425
8426
8427<dl>
8428 <dt>
8429 Type
8430 </dt>
8431 <dd>
8432
8433<span class="param-type">integer</span>
8434
8435
8436
8437 </dd>
8438</dl>
8439
8440
8441
8442
8443
8444</dd>
8445
8446
8447
8448<hr>
8449<dt>
8450 <h4 class="name" id="CB_ltrim"><span class="type-signature"></span>CB_ltrim<span class="signature">(element [, undesiredStrings])</span><span class="type-signature"> &rarr; {string|array}</span></h4>
8451
8452
8453</dt>
8454<dd>
8455
8456
8457 <div class="description">
8458 <p>Trims the left side of a given string or array of strings (modifying the given array), taking off the desired strings or otherwise trimming spaces, tabs (&quot;\t&quot;), new lines (&quot;\n&quot;) and carriage returns (&quot;\r&quot;). Case sensitive.</p>
8459 </div>
8460
8461
8462
8463
8464
8465
8466
8467
8468 <h5>Parameters:</h5>
8469
8470
8471<table class="params table table-striped">
8472 <thead>
8473 <tr>
8474
8475 <th style="width:12%; min-width:110px;">Name</th>
8476
8477
8478 <th style="width:12%; min-width:110px;">Type</th>
8479
8480
8481 <th style="width:12%; min-width:110px;">Argument</th>
8482
8483
8484
8485 <th style="width:12%; min-width:110px;">Default</th>
8486
8487
8488 <th class="last" style="min-width:310px;">Description</th>
8489 </tr>
8490 </thead>
8491
8492 <tbody>
8493
8494
8495 <tr>
8496
8497 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>element</code></td>
8498
8499
8500 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
8501
8502
8503<span class="param-type">string</span>
8504|
8505
8506<span class="param-type">array</span>
8507
8508
8509
8510
8511 </td>
8512
8513
8514 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
8515
8516
8517
8518
8519
8520 </td>
8521
8522
8523
8524 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
8525
8526 </td>
8527
8528
8529 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The element that will be trimmed. It should be either a string or an array of strings.</p></td>
8530 </tr>
8531
8532
8533
8534 <tr>
8535
8536 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>undesiredStrings</code></td>
8537
8538
8539 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
8540
8541
8542<span class="param-type">string</span>
8543|
8544
8545<span class="param-type">array</span>
8546
8547
8548
8549
8550 </td>
8551
8552
8553 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
8554
8555 &lt;optional><br>
8556
8557
8558
8559
8560
8561 </td>
8562
8563
8564
8565 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
8566
8567 [ " ", "\n", "\r", "\t" ]
8568
8569 </td>
8570
8571
8572 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>String or an array with the strings that we want to trim off the given element.</p></td>
8573 </tr>
8574
8575
8576 </tbody>
8577</table>
8578
8579
8580
8581
8582<dl class="details">
8583
8584
8585
8586
8587
8588
8589
8590
8591
8592
8593
8594
8595
8596
8597
8598
8599
8600
8601
8602
8603
8604
8605
8606
8607
8608
8609
8610
8611
8612 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
8613 <dd class="tag-source">
8614 <ul class="dummy">
8615 <li>
8616 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
8617 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-362">line 362</a>
8618 </li>
8619 </ul>
8620 </dd>
8621
8622
8623
8624
8625
8626
8627
8628 <dt class="tag-todo method-doc-label method-doc-details-label">To Do:</dt>
8629 <dd class="tag-todo">
8630 <ul>
8631 <li>Accept a "recursive" parameter (boolean) to affect multiple levels (array of arrays of strings, etc.).</li>
8632
8633 <li>Consider accepting objects instead of arrays in the "element" parameter.</li>
8634
8635 <li>Think about optimizing (using a counter for the number of occurrences in the loop and trim all the occurrences when finished).</li>
8636 </ul>
8637 </dd>
8638
8639</dl>
8640
8641
8642
8643
8644
8645
8646
8647
8648
8649
8650
8651
8652
8653 <h5>Returns:</h5>
8654
8655
8656<div class="param-desc">
8657 <p>Returns the given element again if it was an string, a number (it will be casted to a string) or an array of strings, trimmed if it has been possible. If it was another type, returns an empty string.</p>
8658</div>
8659
8660
8661
8662<dl>
8663 <dt>
8664 Type
8665 </dt>
8666 <dd>
8667
8668<span class="param-type">string</span>
8669|
8670
8671<span class="param-type">array</span>
8672
8673
8674
8675 </dd>
8676</dl>
8677
8678
8679
8680
8681
8682</dd>
8683
8684
8685
8686<hr>
8687<dt>
8688 <h4 class="name" id="CB_nl2br"><span class="type-signature"></span>CB_nl2br<span class="signature">(string)</span><span class="type-signature"> &rarr; {string}</span></h4>
8689
8690
8691</dt>
8692<dd>
8693
8694
8695 <div class="description">
8696 <p>Changes new lines (\n) for &lt;br /&gt;'s in a given string.</p>
8697 </div>
8698
8699
8700
8701
8702
8703
8704
8705
8706 <h5>Parameters:</h5>
8707
8708
8709<table class="params table table-striped">
8710 <thead>
8711 <tr>
8712
8713 <th style="width:12%; min-width:110px;">Name</th>
8714
8715
8716 <th style="width:12%; min-width:110px;">Type</th>
8717
8718
8719
8720
8721
8722 <th class="last" style="min-width:310px;">Description</th>
8723 </tr>
8724 </thead>
8725
8726 <tbody>
8727
8728
8729 <tr>
8730
8731 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>string</code></td>
8732
8733
8734 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
8735
8736
8737<span class="param-type">string</span>
8738
8739
8740
8741
8742 </td>
8743
8744
8745
8746
8747
8748 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The string we want to modify.</p></td>
8749 </tr>
8750
8751
8752 </tbody>
8753</table>
8754
8755
8756
8757
8758<dl class="details">
8759
8760
8761
8762
8763
8764
8765
8766
8767
8768
8769
8770
8771
8772
8773
8774
8775
8776
8777
8778
8779
8780
8781
8782
8783
8784
8785
8786
8787
8788 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
8789 <dd class="tag-source">
8790 <ul class="dummy">
8791 <li>
8792 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
8793 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-416">line 416</a>
8794 </li>
8795 </ul>
8796 </dd>
8797
8798
8799
8800
8801
8802
8803
8804</dl>
8805
8806
8807
8808
8809
8810
8811
8812
8813
8814
8815
8816
8817
8818 <h5>Returns:</h5>
8819
8820
8821<div class="param-desc">
8822 <p>Returns the string with all the occurrences replaced or an empty string if the element given was not a string.</p>
8823</div>
8824
8825
8826
8827<dl>
8828 <dt>
8829 Type
8830 </dt>
8831 <dd>
8832
8833<span class="param-type">string</span>
8834
8835
8836
8837 </dd>
8838</dl>
8839
8840
8841
8842
8843
8844</dd>
8845
8846
8847
8848<hr>
8849<dt>
8850 <h4 class="name" id="CB_nlToBr"><span class="type-signature"></span>CB_nlToBr<span class="signature">()</span><span class="type-signature"></span></h4>
8851
8852
8853</dt>
8854<dd>
8855
8856
8857 <div class="description">
8858 <p>Alias for <a href="global.html#CB_nl2br"><code>CB_nl2br</code></a>.</p>
8859 </div>
8860
8861
8862
8863
8864
8865
8866
8867
8868
8869
8870<dl class="details">
8871
8872
8873
8874
8875
8876
8877
8878
8879
8880
8881
8882
8883
8884
8885
8886
8887
8888
8889
8890
8891
8892
8893
8894
8895
8896
8897
8898
8899
8900 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
8901 <dd class="tag-source">
8902 <ul class="dummy">
8903 <li>
8904 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
8905 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-405">line 405</a>
8906 </li>
8907 </ul>
8908 </dd>
8909
8910
8911
8912
8913
8914 <dt class="tag-see method-doc-label method-doc-details-label">See:</dt>
8915 <dd class="tag-see">
8916 <ul>
8917 <li><a href="global.html#CB_nl2br"><code>CB_nl2br</code></a></li>
8918 </ul>
8919 </dd>
8920
8921
8922
8923</dl>
8924
8925
8926
8927
8928
8929
8930
8931
8932
8933
8934
8935
8936
8937
8938
8939</dd>
8940
8941
8942
8943<hr>
8944<dt>
8945 <h4 class="name" id="CB_numberFormat"><span class="type-signature"></span>CB_numberFormat<span class="signature">(number [, decimals] [, stringify])</span><span class="type-signature"> &rarr; {integer|float|string}</span></h4>
8946
8947
8948</dt>
8949<dd>
8950
8951
8952 <div class="description">
8953 <p>Returns the given number with the desired decimals and make it a string if we want to (so it will be able to have trailing zeros). Uses decimal numeral system only. It will perform ceiling round automatically if needed.</p>
8954 </div>
8955
8956
8957
8958
8959
8960
8961
8962
8963 <h5>Parameters:</h5>
8964
8965
8966<table class="params table table-striped">
8967 <thead>
8968 <tr>
8969
8970 <th style="width:12%; min-width:110px;">Name</th>
8971
8972
8973 <th style="width:12%; min-width:110px;">Type</th>
8974
8975
8976 <th style="width:12%; min-width:110px;">Argument</th>
8977
8978
8979
8980 <th style="width:12%; min-width:110px;">Default</th>
8981
8982
8983 <th class="last" style="min-width:310px;">Description</th>
8984 </tr>
8985 </thead>
8986
8987 <tbody>
8988
8989
8990 <tr>
8991
8992 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>number</code></td>
8993
8994
8995 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
8996
8997
8998<span class="param-type">integer</span>
8999|
9000
9001<span class="param-type">float</span>
9002|
9003
9004<span class="param-type">string</span>
9005
9006
9007
9008
9009 </td>
9010
9011
9012 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
9013
9014
9015
9016
9017
9018 </td>
9019
9020
9021
9022 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
9023
9024 </td>
9025
9026
9027 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The number that we want to format. It can be a string.</p></td>
9028 </tr>
9029
9030
9031
9032 <tr>
9033
9034 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>decimals</code></td>
9035
9036
9037 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
9038
9039
9040<span class="param-type">integer</span>
9041
9042
9043
9044
9045 </td>
9046
9047
9048 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
9049
9050 &lt;optional><br>
9051
9052
9053
9054
9055
9056 </td>
9057
9058
9059
9060 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
9061
9062 2
9063
9064 </td>
9065
9066
9067 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The number of decimals we want to allow.</p></td>
9068 </tr>
9069
9070
9071
9072 <tr>
9073
9074 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>stringify</code></td>
9075
9076
9077 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
9078
9079
9080<span class="param-type">boolean</span>
9081
9082
9083
9084
9085 </td>
9086
9087
9088 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
9089
9090 &lt;optional><br>
9091
9092
9093
9094
9095
9096 </td>
9097
9098
9099
9100 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
9101
9102 false
9103
9104 </td>
9105
9106
9107 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Set to true if we want it to return a string (filled with trailing zeros to reach the desired number of decimals).</p></td>
9108 </tr>
9109
9110
9111 </tbody>
9112</table>
9113
9114
9115
9116
9117<dl class="details">
9118
9119
9120
9121
9122
9123
9124
9125
9126
9127
9128
9129
9130
9131
9132
9133
9134
9135
9136
9137
9138
9139
9140
9141
9142
9143
9144
9145
9146
9147 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
9148 <dd class="tag-source">
9149 <ul class="dummy">
9150 <li>
9151 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
9152 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-567">line 567</a>
9153 </li>
9154 </ul>
9155 </dd>
9156
9157
9158
9159
9160
9161
9162
9163 <dt class="tag-todo method-doc-label method-doc-details-label">To Do:</dt>
9164 <dd class="tag-todo">
9165 <ul>
9166 <li>Allow to define a minimum length for the integer part of the "number" parameter, so it will fill with leading zeros if needed (when "stringify" is set to true). Think about allowing to define a maximum too.</li>
9167 </ul>
9168 </dd>
9169
9170</dl>
9171
9172
9173
9174
9175
9176
9177
9178
9179
9180
9181
9182
9183
9184 <h5>Returns:</h5>
9185
9186
9187<div class="param-desc">
9188 <p>Returns zero in the case a non-valid number has been provided.</p>
9189</div>
9190
9191
9192
9193<dl>
9194 <dt>
9195 Type
9196 </dt>
9197 <dd>
9198
9199<span class="param-type">integer</span>
9200|
9201
9202<span class="param-type">float</span>
9203|
9204
9205<span class="param-type">string</span>
9206
9207
9208
9209 </dd>
9210</dl>
9211
9212
9213
9214
9215
9216</dd>
9217
9218
9219
9220<hr>
9221<dt>
9222 <h4 class="name" id="CB_numberOfDecimalDigits"><span class="type-signature"></span>CB_numberOfDecimalDigits<span class="signature">()</span><span class="type-signature"></span></h4>
9223
9224
9225</dt>
9226<dd>
9227
9228
9229 <div class="description">
9230 <p>Alias for <a href="global.html#CB_countDecimalPart"><code>CB_countDecimalPart</code></a>.</p>
9231 </div>
9232
9233
9234
9235
9236
9237
9238
9239
9240
9241
9242<dl class="details">
9243
9244
9245
9246
9247
9248
9249
9250
9251
9252
9253
9254
9255
9256
9257
9258
9259
9260
9261
9262
9263
9264
9265
9266
9267
9268
9269
9270
9271
9272 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
9273 <dd class="tag-source">
9274 <ul class="dummy">
9275 <li>
9276 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
9277 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-608">line 608</a>
9278 </li>
9279 </ul>
9280 </dd>
9281
9282
9283
9284
9285
9286 <dt class="tag-see method-doc-label method-doc-details-label">See:</dt>
9287 <dd class="tag-see">
9288 <ul>
9289 <li><a href="global.html#CB_countDecimalPart"><code>CB_countDecimalPart</code></a></li>
9290 </ul>
9291 </dd>
9292
9293
9294
9295</dl>
9296
9297
9298
9299
9300
9301
9302
9303
9304
9305
9306
9307
9308
9309
9310
9311</dd>
9312
9313
9314
9315<hr>
9316<dt>
9317 <h4 class="name" id="CB_numberOfDecimals"><span class="type-signature"></span>CB_numberOfDecimals<span class="signature">()</span><span class="type-signature"></span></h4>
9318
9319
9320</dt>
9321<dd>
9322
9323
9324 <div class="description">
9325 <p>Alias for <a href="global.html#CB_countDecimalPart"><code>CB_countDecimalPart</code></a>.</p>
9326 </div>
9327
9328
9329
9330
9331
9332
9333
9334
9335
9336
9337<dl class="details">
9338
9339
9340
9341
9342
9343
9344
9345
9346
9347
9348
9349
9350
9351
9352
9353
9354
9355
9356
9357
9358
9359
9360
9361
9362
9363
9364
9365
9366
9367 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
9368 <dd class="tag-source">
9369 <ul class="dummy">
9370 <li>
9371 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
9372 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-603">line 603</a>
9373 </li>
9374 </ul>
9375 </dd>
9376
9377
9378
9379
9380
9381 <dt class="tag-see method-doc-label method-doc-details-label">See:</dt>
9382 <dd class="tag-see">
9383 <ul>
9384 <li><a href="global.html#CB_countDecimalPart"><code>CB_countDecimalPart</code></a></li>
9385 </ul>
9386 </dd>
9387
9388
9389
9390</dl>
9391
9392
9393
9394
9395
9396
9397
9398
9399
9400
9401
9402
9403
9404
9405
9406</dd>
9407
9408
9409
9410<hr>
9411<dt>
9412 <h4 class="name" id="CB_numberOfIntegerDigits"><span class="type-signature"></span>CB_numberOfIntegerDigits<span class="signature">()</span><span class="type-signature"></span></h4>
9413
9414
9415</dt>
9416<dd>
9417
9418
9419 <div class="description">
9420 <p>Alias for <a href="global.html#CB_countIntegerPart"><code>CB_countIntegerPart</code></a>.</p>
9421 </div>
9422
9423
9424
9425
9426
9427
9428
9429
9430
9431
9432<dl class="details">
9433
9434
9435
9436
9437
9438
9439
9440
9441
9442
9443
9444
9445
9446
9447
9448
9449
9450
9451
9452
9453
9454
9455
9456
9457
9458
9459
9460
9461
9462 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
9463 <dd class="tag-source">
9464 <ul class="dummy">
9465 <li>
9466 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
9467 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-639">line 639</a>
9468 </li>
9469 </ul>
9470 </dd>
9471
9472
9473
9474
9475
9476 <dt class="tag-see method-doc-label method-doc-details-label">See:</dt>
9477 <dd class="tag-see">
9478 <ul>
9479 <li><a href="global.html#CB_countIntegerPart"><code>CB_countIntegerPart</code></a></li>
9480 </ul>
9481 </dd>
9482
9483
9484
9485</dl>
9486
9487
9488
9489
9490
9491
9492
9493
9494
9495
9496
9497
9498
9499
9500
9501</dd>
9502
9503
9504
9505<hr>
9506<dt>
9507 <h4 class="name" id="CB_parseJSON"><span class="type-signature"></span>CB_parseJSON<span class="signature">(objectString [, reviver] [, returnValueOnFail] [, acceptUndefinedOrNull] [, onError])</span><span class="type-signature"> &rarr; {*}</span></h4>
9508
9509
9510</dt>
9511<dd>
9512
9513
9514 <div class="description">
9515 <p>Tries to parse a given string to convert it into a JSON object. Internally it will use the native <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/JSON/parse">JSON.parse</a> method or otherwise use <a href="https://bestiejs.github.io/json3/">JSON 3</a> instead.</p>
9516 </div>
9517
9518
9519
9520
9521
9522
9523
9524
9525 <h5>Parameters:</h5>
9526
9527
9528<table class="params table table-striped">
9529 <thead>
9530 <tr>
9531
9532 <th style="width:12%; min-width:110px;">Name</th>
9533
9534
9535 <th style="width:12%; min-width:110px;">Type</th>
9536
9537
9538 <th style="width:12%; min-width:110px;">Argument</th>
9539
9540
9541
9542 <th style="width:12%; min-width:110px;">Default</th>
9543
9544
9545 <th class="last" style="min-width:310px;">Description</th>
9546 </tr>
9547 </thead>
9548
9549 <tbody>
9550
9551
9552 <tr>
9553
9554 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>objectString</code></td>
9555
9556
9557 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
9558
9559
9560<span class="param-type">string</span>
9561
9562
9563
9564
9565 </td>
9566
9567
9568 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
9569
9570
9571
9572
9573
9574 </td>
9575
9576
9577
9578 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
9579
9580 </td>
9581
9582
9583 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The JSON object we want to parse, in string format. First parameter when calling the <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/JSON/parse">JSON.parse</a> method (or equivalent)</p></td>
9584 </tr>
9585
9586
9587
9588 <tr>
9589
9590 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>reviver</code></td>
9591
9592
9593 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
9594
9595
9596<span class="param-type">function</span>
9597
9598
9599
9600
9601 </td>
9602
9603
9604 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
9605
9606 &lt;optional><br>
9607
9608
9609
9610
9611
9612 </td>
9613
9614
9615
9616 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
9617
9618 </td>
9619
9620
9621 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Second parameter when calling the <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/JSON/parse">JSON.parse</a> method (or equivalent).</p></td>
9622 </tr>
9623
9624
9625
9626 <tr>
9627
9628 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>returnValueOnFail</code></td>
9629
9630
9631 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
9632
9633
9634<span class="param-type">*</span>
9635
9636
9637
9638
9639 </td>
9640
9641
9642 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
9643
9644 &lt;optional><br>
9645
9646
9647
9648
9649
9650 </td>
9651
9652
9653
9654 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
9655
9656 </td>
9657
9658
9659 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The value we want it to return in the case it cannot be parsed. If not provided, undefined will be returned.</p></td>
9660 </tr>
9661
9662
9663
9664 <tr>
9665
9666 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>acceptUndefinedOrNull</code></td>
9667
9668
9669 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
9670
9671
9672<span class="param-type">boolean</span>
9673
9674
9675
9676
9677 </td>
9678
9679
9680 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
9681
9682 &lt;optional><br>
9683
9684
9685
9686
9687
9688 </td>
9689
9690
9691
9692 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
9693
9694 false
9695
9696 </td>
9697
9698
9699 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>If it is set to true and the given objectString is undefined or null, an empty object ({}) will be used as the objectString.</p></td>
9700 </tr>
9701
9702
9703
9704 <tr>
9705
9706 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>onError</code></td>
9707
9708
9709 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
9710
9711
9712<span class="param-type">function</span>
9713
9714
9715
9716
9717 </td>
9718
9719
9720 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
9721
9722 &lt;optional><br>
9723
9724
9725
9726
9727
9728 </td>
9729
9730
9731
9732 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
9733
9734 </td>
9735
9736
9737 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Callback which will be called if it failed to be parsed (it will receive the &quot;objectString&quot; as the unique parameter).</p></td>
9738 </tr>
9739
9740
9741 </tbody>
9742</table>
9743
9744
9745
9746
9747<dl class="details">
9748
9749
9750
9751
9752
9753
9754
9755
9756
9757
9758
9759
9760
9761
9762
9763
9764
9765
9766
9767
9768
9769
9770
9771
9772
9773
9774
9775
9776
9777 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
9778 <dd class="tag-source">
9779 <ul class="dummy">
9780 <li>
9781 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
9782 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-889">line 889</a>
9783 </li>
9784 </ul>
9785 </dd>
9786
9787
9788
9789
9790
9791
9792
9793</dl>
9794
9795
9796
9797
9798
9799
9800
9801
9802
9803
9804
9805
9806
9807 <h5>Returns:</h5>
9808
9809
9810<div class="param-desc">
9811 <p>Returns the object parsed from the given string or the value of &quot;returnValueOnFail&quot; otherwise (which will be undefined if not provided).</p>
9812</div>
9813
9814
9815
9816<dl>
9817 <dt>
9818 Type
9819 </dt>
9820 <dd>
9821
9822<span class="param-type">*</span>
9823
9824
9825
9826 </dd>
9827</dl>
9828
9829
9830
9831
9832
9833</dd>
9834
9835
9836
9837<hr>
9838<dt>
9839 <h4 class="name" id="CB_parseString"><span class="type-signature"></span>CB_parseString<span class="signature">(element)</span><span class="type-signature"> &rarr; {string}</span></h4>
9840
9841
9842</dt>
9843<dd>
9844
9845
9846 <div class="description">
9847 <p>Returns back the given element as a string if it could be parsed or an empty string otherwise.</p>
9848 </div>
9849
9850
9851
9852
9853
9854
9855
9856
9857 <h5>Parameters:</h5>
9858
9859
9860<table class="params table table-striped">
9861 <thead>
9862 <tr>
9863
9864 <th style="width:12%; min-width:110px;">Name</th>
9865
9866
9867 <th style="width:12%; min-width:110px;">Type</th>
9868
9869
9870
9871
9872
9873 <th class="last" style="min-width:310px;">Description</th>
9874 </tr>
9875 </thead>
9876
9877 <tbody>
9878
9879
9880 <tr>
9881
9882 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>element</code></td>
9883
9884
9885 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
9886
9887
9888<span class="param-type">*</span>
9889
9890
9891
9892
9893 </td>
9894
9895
9896
9897
9898
9899 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The element that will be checked.</p></td>
9900 </tr>
9901
9902
9903 </tbody>
9904</table>
9905
9906
9907
9908
9909<dl class="details">
9910
9911
9912
9913
9914
9915
9916
9917
9918
9919
9920
9921
9922
9923
9924
9925
9926
9927
9928
9929
9930
9931
9932
9933
9934
9935
9936
9937
9938
9939 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
9940 <dd class="tag-source">
9941 <ul class="dummy">
9942 <li>
9943 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
9944 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-251">line 251</a>
9945 </li>
9946 </ul>
9947 </dd>
9948
9949
9950
9951
9952
9953
9954
9955</dl>
9956
9957
9958
9959
9960
9961
9962
9963
9964
9965
9966
9967
9968
9969 <h5>Returns:</h5>
9970
9971
9972
9973
9974<dl>
9975 <dt>
9976 Type
9977 </dt>
9978 <dd>
9979
9980<span class="param-type">string</span>
9981
9982
9983
9984 </dd>
9985</dl>
9986
9987
9988
9989
9990
9991</dd>
9992
9993
9994
9995<hr>
9996<dt>
9997 <h4 class="name" id="CB_regularExpressionString"><span class="type-signature"></span>CB_regularExpressionString<span class="signature">(string [, allOccurrences] [, caseInsensitive])</span><span class="type-signature"> &rarr; {RegExp}</span></h4>
9998
9999
10000</dt>
10001<dd>
10002
10003
10004 <div class="description">
10005 <p>Returns a desired regular expression (escaping the string) using the native JavaScript's <a href="https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/RegExp">RegExp</a> from a given string.</p>
10006 </div>
10007
10008
10009
10010
10011
10012
10013
10014
10015 <h5>Parameters:</h5>
10016
10017
10018<table class="params table table-striped">
10019 <thead>
10020 <tr>
10021
10022 <th style="width:12%; min-width:110px;">Name</th>
10023
10024
10025 <th style="width:12%; min-width:110px;">Type</th>
10026
10027
10028 <th style="width:12%; min-width:110px;">Argument</th>
10029
10030
10031
10032 <th style="width:12%; min-width:110px;">Default</th>
10033
10034
10035 <th class="last" style="min-width:310px;">Description</th>
10036 </tr>
10037 </thead>
10038
10039 <tbody>
10040
10041
10042 <tr>
10043
10044 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>string</code></td>
10045
10046
10047 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10048
10049
10050<span class="param-type">string</span>
10051
10052
10053
10054
10055 </td>
10056
10057
10058 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10059
10060
10061
10062
10063
10064 </td>
10065
10066
10067
10068 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10069
10070 </td>
10071
10072
10073 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The string (not a regular expression) that we want to use (special characters will be escaped).</p></td>
10074 </tr>
10075
10076
10077
10078 <tr>
10079
10080 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>allOccurrences</code></td>
10081
10082
10083 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10084
10085
10086<span class="param-type">boolean</span>
10087
10088
10089
10090
10091 </td>
10092
10093
10094 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10095
10096 &lt;optional><br>
10097
10098
10099
10100
10101
10102 </td>
10103
10104
10105
10106 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10107
10108 false
10109
10110 </td>
10111
10112
10113 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Defines whether we want the regular expression returned to match all occurrences of the given string or only first found.</p></td>
10114 </tr>
10115
10116
10117
10118 <tr>
10119
10120 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>caseInsensitive</code></td>
10121
10122
10123 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10124
10125
10126<span class="param-type">boolean</span>
10127
10128
10129
10130
10131 </td>
10132
10133
10134 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10135
10136 &lt;optional><br>
10137
10138
10139
10140
10141
10142 </td>
10143
10144
10145
10146 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10147
10148 false
10149
10150 </td>
10151
10152
10153 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Defines whether we want the regular expression returned to be case insensitive or not.</p></td>
10154 </tr>
10155
10156
10157 </tbody>
10158</table>
10159
10160
10161
10162
10163<dl class="details">
10164
10165
10166
10167
10168
10169
10170
10171
10172
10173
10174
10175
10176
10177
10178
10179
10180
10181
10182
10183
10184
10185
10186
10187
10188
10189
10190
10191
10192
10193 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
10194 <dd class="tag-source">
10195 <ul class="dummy">
10196 <li>
10197 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
10198 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-1470">line 1470</a>
10199 </li>
10200 </ul>
10201 </dd>
10202
10203
10204
10205
10206
10207
10208
10209</dl>
10210
10211
10212
10213
10214
10215
10216
10217
10218
10219
10220
10221
10222
10223 <h5>Returns:</h5>
10224
10225
10226<div class="param-desc">
10227 <p>Returns the desired regular expression (escaping the string) using the native JavaScript's <a href="https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/RegExp">RegExp</a> from a given string.</p>
10228</div>
10229
10230
10231
10232<dl>
10233 <dt>
10234 Type
10235 </dt>
10236 <dd>
10237
10238<span class="param-type">RegExp</span>
10239
10240
10241
10242 </dd>
10243</dl>
10244
10245
10246
10247
10248
10249</dd>
10250
10251
10252
10253<hr>
10254<dt>
10255 <h4 class="name" id="CB_renderString"><span class="type-signature"></span>CB_renderString<span class="signature">(str [, JSONObject] [, forceVanilla] [, depthLevelMax])</span><span class="type-signature"> &rarr; {str}</span></h4>
10256
10257
10258</dt>
10259<dd>
10260
10261
10262 <div class="description">
10263 <p>Processes a given string as a template and returns it rendered (if possible) with the values of the given JSON object.<br> Tries to use <a href="https://handlebarsjs.com/">Handlebars</a> as the first choice but if is is not available it will just replace all occurrences with<br> vanilla JavaScript.</p>
10264 </div>
10265
10266
10267
10268
10269
10270
10271
10272
10273 <h5>Parameters:</h5>
10274
10275
10276<table class="params table table-striped">
10277 <thead>
10278 <tr>
10279
10280 <th style="width:12%; min-width:110px;">Name</th>
10281
10282
10283 <th style="width:12%; min-width:110px;">Type</th>
10284
10285
10286 <th style="width:12%; min-width:110px;">Argument</th>
10287
10288
10289
10290 <th style="width:12%; min-width:110px;">Default</th>
10291
10292
10293 <th class="last" style="min-width:310px;">Description</th>
10294 </tr>
10295 </thead>
10296
10297 <tbody>
10298
10299
10300 <tr>
10301
10302 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>str</code></td>
10303
10304
10305 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10306
10307
10308<span class="param-type">string</span>
10309
10310
10311
10312
10313 </td>
10314
10315
10316 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10317
10318
10319
10320
10321
10322 </td>
10323
10324
10325
10326 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10327
10328 </td>
10329
10330
10331 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The string we want to render.</p></td>
10332 </tr>
10333
10334
10335
10336 <tr>
10337
10338 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>JSONObject</code></td>
10339
10340
10341 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10342
10343
10344<span class="param-type">Object</span>
10345
10346
10347
10348
10349 </td>
10350
10351
10352 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10353
10354 &lt;optional><br>
10355
10356
10357
10358
10359
10360 </td>
10361
10362
10363
10364 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10365
10366 CB_JSONData
10367
10368 </td>
10369
10370
10371 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The JSON object which contains the values. If not provided, it will try to use the global CB_JSONData object in the case it exists.</p></td>
10372 </tr>
10373
10374
10375
10376 <tr>
10377
10378 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>forceVanilla</code></td>
10379
10380
10381 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10382
10383
10384<span class="param-type">boolean</span>
10385
10386
10387
10388
10389 </td>
10390
10391
10392 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10393
10394 &lt;optional><br>
10395
10396
10397
10398
10399
10400 </td>
10401
10402
10403
10404 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10405
10406 false
10407
10408 </td>
10409
10410
10411 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Forces vanilla JavaScript rendering instead of using <a href="https://handlebarsjs.com/">Handlebars</a>.</p></td>
10412 </tr>
10413
10414
10415
10416 <tr>
10417
10418 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>depthLevelMax</code></td>
10419
10420
10421 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10422
10423
10424<span class="param-type">integer</span>
10425
10426
10427
10428
10429 </td>
10430
10431
10432 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10433
10434 &lt;optional><br>
10435
10436
10437
10438
10439
10440 </td>
10441
10442
10443
10444 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10445
10446 10
10447
10448 </td>
10449
10450
10451 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Maximum depth level allowed to read the object to render the string. Only applies when it is rendered by vanilla JavaScript. For performance purposes.</p></td>
10452 </tr>
10453
10454
10455 </tbody>
10456</table>
10457
10458
10459
10460
10461<dl class="details">
10462
10463
10464
10465
10466
10467
10468
10469
10470
10471
10472
10473
10474
10475
10476
10477
10478
10479
10480
10481
10482
10483
10484
10485
10486
10487
10488
10489
10490
10491 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
10492 <dd class="tag-source">
10493 <ul class="dummy">
10494 <li>
10495 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
10496 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-495">line 495</a>
10497 </li>
10498 </ul>
10499 </dd>
10500
10501
10502
10503
10504
10505
10506
10507</dl>
10508
10509
10510
10511
10512
10513
10514
10515
10516
10517
10518
10519
10520
10521 <h5>Returns:</h5>
10522
10523
10524
10525
10526<dl>
10527 <dt>
10528 Type
10529 </dt>
10530 <dd>
10531
10532<span class="param-type">str</span>
10533
10534
10535
10536 </dd>
10537</dl>
10538
10539
10540
10541
10542
10543</dd>
10544
10545
10546
10547<hr>
10548<dt>
10549 <h4 class="name" id="CB_replaceAll"><span class="type-signature"></span>CB_replaceAll<span class="signature">(stringOrArray, stringOrArrayFind [, stringReplace] [, caseInsensitive])</span><span class="type-signature"> &rarr; {string|array}</span></h4>
10550
10551
10552</dt>
10553<dd>
10554
10555
10556 <div class="description">
10557 <p>Returns the string or array of strings with all the desired occurrences replaced. Calls itself recursively and calls the <a href="global.html#CB_regularExpressionString"><code>CB_regularExpressionString</code></a> function internally.</p>
10558 </div>
10559
10560
10561
10562
10563
10564
10565
10566
10567 <h5>Parameters:</h5>
10568
10569
10570<table class="params table table-striped">
10571 <thead>
10572 <tr>
10573
10574 <th style="width:12%; min-width:110px;">Name</th>
10575
10576
10577 <th style="width:12%; min-width:110px;">Type</th>
10578
10579
10580 <th style="width:12%; min-width:110px;">Argument</th>
10581
10582
10583
10584 <th style="width:12%; min-width:110px;">Default</th>
10585
10586
10587 <th class="last" style="min-width:310px;">Description</th>
10588 </tr>
10589 </thead>
10590
10591 <tbody>
10592
10593
10594 <tr>
10595
10596 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>stringOrArray</code></td>
10597
10598
10599 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10600
10601
10602<span class="param-type">string</span>
10603|
10604
10605<span class="param-type">array</span>
10606
10607
10608
10609
10610 </td>
10611
10612
10613 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10614
10615
10616
10617
10618
10619 </td>
10620
10621
10622
10623 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10624
10625 </td>
10626
10627
10628 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>An string or an array of strings whose content we want to replace. It can also be an array of arrays of strings (as many levels as you wish). If an array is given, it will not be modified and a copy from it will be generated and returned with the occurrences replaced.</p></td>
10629 </tr>
10630
10631
10632
10633 <tr>
10634
10635 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>stringOrArrayFind</code></td>
10636
10637
10638 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10639
10640
10641<span class="param-type">string</span>
10642|
10643
10644<span class="param-type">array</span>
10645
10646
10647
10648
10649 </td>
10650
10651
10652 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10653
10654
10655
10656
10657
10658 </td>
10659
10660
10661
10662 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10663
10664 </td>
10665
10666
10667 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>An string or an array of strings (not a regular expressions) that we want to find to be replaced (special characters will be escaped).</p></td>
10668 </tr>
10669
10670
10671
10672 <tr>
10673
10674 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>stringReplace</code></td>
10675
10676
10677 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10678
10679
10680<span class="param-type">string</span>
10681
10682
10683
10684
10685 </td>
10686
10687
10688 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10689
10690 &lt;optional><br>
10691
10692
10693
10694
10695
10696 </td>
10697
10698
10699
10700 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10701
10702 ""
10703
10704 </td>
10705
10706
10707 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The string that will replace &quot;stringFind&quot;. If not provided, it will be replaced as an empty string (it will just remove the occurrences found).</p></td>
10708 </tr>
10709
10710
10711
10712 <tr>
10713
10714 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>caseInsensitive</code></td>
10715
10716
10717 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10718
10719
10720<span class="param-type">boolean</span>
10721
10722
10723
10724
10725 </td>
10726
10727
10728 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10729
10730 &lt;optional><br>
10731
10732
10733
10734
10735
10736 </td>
10737
10738
10739
10740 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10741
10742 false
10743
10744 </td>
10745
10746
10747 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Defines whether we want to be case insensitive or not.</p></td>
10748 </tr>
10749
10750
10751 </tbody>
10752</table>
10753
10754
10755
10756
10757<dl class="details">
10758
10759
10760
10761
10762
10763
10764
10765
10766
10767
10768
10769
10770
10771
10772
10773
10774
10775
10776
10777
10778
10779
10780
10781
10782
10783
10784
10785
10786
10787 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
10788 <dd class="tag-source">
10789 <ul class="dummy">
10790 <li>
10791 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
10792 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-1437">line 1437</a>
10793 </li>
10794 </ul>
10795 </dd>
10796
10797
10798
10799
10800
10801
10802
10803</dl>
10804
10805
10806
10807
10808
10809
10810
10811
10812
10813
10814
10815
10816
10817 <h5>Returns:</h5>
10818
10819
10820<div class="param-desc">
10821 <p>Returns the &quot;stringOrArray&quot; given with occurrences replaced. If the &quot;stringOrArray&quot; given was neither a string nor an array, it will be returned without being modified.</p>
10822</div>
10823
10824
10825
10826<dl>
10827 <dt>
10828 Type
10829 </dt>
10830 <dd>
10831
10832<span class="param-type">string</span>
10833|
10834
10835<span class="param-type">array</span>
10836
10837
10838
10839 </dd>
10840</dl>
10841
10842
10843
10844
10845
10846</dd>
10847
10848
10849
10850<hr>
10851<dt>
10852 <h4 class="name" id="CB_rtrim"><span class="type-signature"></span>CB_rtrim<span class="signature">(element [, undesiredStrings])</span><span class="type-signature"> &rarr; {string|array}</span></h4>
10853
10854
10855</dt>
10856<dd>
10857
10858
10859 <div class="description">
10860 <p>Trims the right side of a given string or array of strings (modifying the given array), taking off the desired strings or otherwise trimming spaces, tabs (&quot;\t&quot;), new lines (&quot;\n&quot;) and carriage returns (&quot;\r&quot;). Case sensitive.</p>
10861 </div>
10862
10863
10864
10865
10866
10867
10868
10869
10870 <h5>Parameters:</h5>
10871
10872
10873<table class="params table table-striped">
10874 <thead>
10875 <tr>
10876
10877 <th style="width:12%; min-width:110px;">Name</th>
10878
10879
10880 <th style="width:12%; min-width:110px;">Type</th>
10881
10882
10883 <th style="width:12%; min-width:110px;">Argument</th>
10884
10885
10886
10887 <th style="width:12%; min-width:110px;">Default</th>
10888
10889
10890 <th class="last" style="min-width:310px;">Description</th>
10891 </tr>
10892 </thead>
10893
10894 <tbody>
10895
10896
10897 <tr>
10898
10899 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>element</code></td>
10900
10901
10902 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10903
10904
10905<span class="param-type">string</span>
10906|
10907
10908<span class="param-type">array</span>
10909
10910
10911
10912
10913 </td>
10914
10915
10916 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10917
10918
10919
10920
10921
10922 </td>
10923
10924
10925
10926 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10927
10928 </td>
10929
10930
10931 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The element that will be trimmed. It should be either a string or an array of strings.</p></td>
10932 </tr>
10933
10934
10935
10936 <tr>
10937
10938 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>undesiredStrings</code></td>
10939
10940
10941 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10942
10943
10944<span class="param-type">string</span>
10945|
10946
10947<span class="param-type">array</span>
10948
10949
10950
10951
10952 </td>
10953
10954
10955 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10956
10957 &lt;optional><br>
10958
10959
10960
10961
10962
10963 </td>
10964
10965
10966
10967 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
10968
10969 [ " ", "\n", "\r", "\t" ]
10970
10971 </td>
10972
10973
10974 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>String or an array with the strings that we want to trim off the given element.</p></td>
10975 </tr>
10976
10977
10978 </tbody>
10979</table>
10980
10981
10982
10983
10984<dl class="details">
10985
10986
10987
10988
10989
10990
10991
10992
10993
10994
10995
10996
10997
10998
10999
11000
11001
11002
11003
11004
11005
11006
11007
11008
11009
11010
11011
11012
11013
11014 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
11015 <dd class="tag-source">
11016 <ul class="dummy">
11017 <li>
11018 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
11019 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-309">line 309</a>
11020 </li>
11021 </ul>
11022 </dd>
11023
11024
11025
11026
11027
11028
11029
11030 <dt class="tag-todo method-doc-label method-doc-details-label">To Do:</dt>
11031 <dd class="tag-todo">
11032 <ul>
11033 <li>Accept a "recursive" parameter (boolean) to affect multiple levels (array of arrays of strings, etc.).</li>
11034
11035 <li>Consider accepting objects instead of arrays in the "element" parameter.</li>
11036
11037 <li>Think about optimizing (using a counter for the number of occurrences in the loop and trim all the occurrences when finished).</li>
11038 </ul>
11039 </dd>
11040
11041</dl>
11042
11043
11044
11045
11046
11047
11048
11049
11050
11051
11052
11053
11054
11055 <h5>Returns:</h5>
11056
11057
11058<div class="param-desc">
11059 <p>Returns the given element again if it was an string, a number (it will be casted to a string) or an array of strings, trimmed if it has been possible. If it was another type, returns an empty string.</p>
11060</div>
11061
11062
11063
11064<dl>
11065 <dt>
11066 Type
11067 </dt>
11068 <dd>
11069
11070<span class="param-type">string</span>
11071|
11072
11073<span class="param-type">array</span>
11074
11075
11076
11077 </dd>
11078</dl>
11079
11080
11081
11082
11083
11084</dd>
11085
11086
11087
11088<hr>
11089<dt>
11090 <h4 class="name" id="CB_scriptPathCalculate"><span class="type-signature"></span>CB_scriptPathCalculate<span class="signature">()</span><span class="type-signature"> &rarr; {string}</span></h4>
11091
11092
11093</dt>
11094<dd>
11095
11096
11097 <div class="description">
11098 <p>Tries to calculate and returns the path where the script is located.</p>
11099 </div>
11100
11101
11102
11103
11104
11105
11106
11107
11108
11109
11110<dl class="details">
11111
11112
11113
11114
11115
11116
11117
11118
11119
11120
11121
11122
11123
11124
11125
11126
11127
11128
11129
11130
11131
11132
11133
11134
11135
11136
11137
11138
11139
11140 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
11141 <dd class="tag-source">
11142 <ul class="dummy">
11143 <li>
11144 <a href="CrossBrowdy.js.html">CrossBrowdy.js</a>,
11145 <a href="CrossBrowdy.js.html#sunlight-1-line-1004">line 1004</a>
11146 </li>
11147 </ul>
11148 </dd>
11149
11150
11151
11152
11153
11154
11155
11156</dl>
11157
11158
11159
11160
11161
11162
11163
11164
11165
11166
11167
11168
11169
11170 <h5>Returns:</h5>
11171
11172
11173<div class="param-desc">
11174 <p>If it cannot be calculated, it will returns the value of <code>CB_Configuration[CB_NAME].SCRIPT_PATH_DEFAULT</code>.</p>
11175</div>
11176
11177
11178
11179<dl>
11180 <dt>
11181 Type
11182 </dt>
11183 <dd>
11184
11185<span class="param-type">string</span>
11186
11187
11188
11189 </dd>
11190</dl>
11191
11192
11193
11194
11195
11196</dd>
11197
11198
11199
11200<hr>
11201<dt>
11202 <h4 class="name" id="CB_setCookie"><span class="type-signature"></span>CB_setCookie<span class="signature">(index, value [, days] [, path])</span><span class="type-signature"> &rarr; {boolean}</span></h4>
11203
11204
11205</dt>
11206<dd>
11207
11208
11209 <div class="description">
11210 <p>Stores a cookie.</p>
11211 </div>
11212
11213
11214
11215
11216
11217
11218
11219
11220 <h5>Parameters:</h5>
11221
11222
11223<table class="params table table-striped">
11224 <thead>
11225 <tr>
11226
11227 <th style="width:12%; min-width:110px;">Name</th>
11228
11229
11230 <th style="width:12%; min-width:110px;">Type</th>
11231
11232
11233 <th style="width:12%; min-width:110px;">Argument</th>
11234
11235
11236
11237
11238 <th class="last" style="min-width:310px;">Description</th>
11239 </tr>
11240 </thead>
11241
11242 <tbody>
11243
11244
11245 <tr>
11246
11247 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>index</code></td>
11248
11249
11250 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
11251
11252
11253<span class="param-type">string</span>
11254|
11255
11256<span class="param-type">number</span>
11257
11258
11259
11260
11261 </td>
11262
11263
11264 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
11265
11266
11267
11268
11269
11270 </td>
11271
11272
11273
11274
11275 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The index where the value given will be stored.</p></td>
11276 </tr>
11277
11278
11279
11280 <tr>
11281
11282 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>value</code></td>
11283
11284
11285 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
11286
11287
11288<span class="param-type">string</span>
11289|
11290
11291<span class="param-type">number</span>
11292
11293
11294
11295
11296 </td>
11297
11298
11299 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
11300
11301
11302
11303
11304
11305 </td>
11306
11307
11308
11309
11310 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The value we want to store. It should be a string or a number.</p></td>
11311 </tr>
11312
11313
11314
11315 <tr>
11316
11317 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>days</code></td>
11318
11319
11320 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
11321
11322
11323<span class="param-type">integer</span>
11324
11325
11326
11327
11328 </td>
11329
11330
11331 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
11332
11333 &lt;optional><br>
11334
11335
11336
11337
11338
11339 </td>
11340
11341
11342
11343
11344 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The number of days after which the cookie will expire. It belongs to the &quot;expires=&quot; parameter of the cookie. If not provided, the parameter will not be used at all.</p></td>
11345 </tr>
11346
11347
11348
11349 <tr>
11350
11351 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>path</code></td>
11352
11353
11354 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
11355
11356
11357<span class="param-type">string</span>
11358
11359
11360
11361
11362 </td>
11363
11364
11365 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
11366
11367 &lt;optional><br>
11368
11369
11370
11371
11372
11373 </td>
11374
11375
11376
11377
11378 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The path where the cookie will be stored. It belongs to the &quot;path=&quot; parameter of the cookie. If not provided, the parameter will not be used at all.</p></td>
11379 </tr>
11380
11381
11382 </tbody>
11383</table>
11384
11385
11386
11387
11388<dl class="details">
11389
11390
11391
11392
11393
11394
11395
11396
11397
11398
11399
11400
11401
11402
11403
11404
11405
11406
11407
11408
11409
11410
11411
11412
11413
11414
11415
11416
11417
11418 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
11419 <dd class="tag-source">
11420 <ul class="dummy">
11421 <li>
11422 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
11423 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-764">line 764</a>
11424 </li>
11425 </ul>
11426 </dd>
11427
11428
11429
11430
11431
11432
11433
11434</dl>
11435
11436
11437
11438
11439
11440
11441
11442
11443
11444
11445
11446
11447
11448 <h5>Returns:</h5>
11449
11450
11451<div class="param-desc">
11452 <p>Returns true if the value has been stored successfully (not totally reliable, it should be checked with <a href="global.html#CB_getCookie"><code>CB_getCookie</code></a> after a while).</p>
11453</div>
11454
11455
11456
11457<dl>
11458 <dt>
11459 Type
11460 </dt>
11461 <dd>
11462
11463<span class="param-type">boolean</span>
11464
11465
11466
11467 </dd>
11468</dl>
11469
11470
11471
11472
11473
11474</dd>
11475
11476
11477
11478<hr>
11479<dt>
11480 <h4 class="name" id="CB_setDatum"><span class="type-signature"></span>CB_setDatum<span class="signature">(index, value [, days] [, path] [, forceCookie])</span><span class="type-signature"> &rarr; {boolean}</span></h4>
11481
11482
11483</dt>
11484<dd>
11485
11486
11487 <div class="description">
11488 <p>Stores a value using <a href="https://developer.mozilla.org/en-US/docs/Web/API/Web_Storage_API">Web Storage API</a> (<a href="https://developer.mozilla.org/en-US/docs/Web/API/Window/localStorage">localStorage</a>). It can use <a href="https://github.com/mortzdk/localStorage">localStorage</a> as a fallback or cookies instead.</p>
11489 </div>
11490
11491
11492
11493
11494
11495
11496
11497
11498 <h5>Parameters:</h5>
11499
11500
11501<table class="params table table-striped">
11502 <thead>
11503 <tr>
11504
11505 <th style="width:12%; min-width:110px;">Name</th>
11506
11507
11508 <th style="width:12%; min-width:110px;">Type</th>
11509
11510
11511 <th style="width:12%; min-width:110px;">Argument</th>
11512
11513
11514
11515 <th style="width:12%; min-width:110px;">Default</th>
11516
11517
11518 <th class="last" style="min-width:310px;">Description</th>
11519 </tr>
11520 </thead>
11521
11522 <tbody>
11523
11524
11525 <tr>
11526
11527 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>index</code></td>
11528
11529
11530 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
11531
11532
11533<span class="param-type">string</span>
11534|
11535
11536<span class="param-type">number</span>
11537
11538
11539
11540
11541 </td>
11542
11543
11544 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
11545
11546
11547
11548
11549
11550 </td>
11551
11552
11553
11554 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
11555
11556 </td>
11557
11558
11559 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The index where the value given will be stored.</p></td>
11560 </tr>
11561
11562
11563
11564 <tr>
11565
11566 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>value</code></td>
11567
11568
11569 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
11570
11571
11572<span class="param-type">string</span>
11573|
11574
11575<span class="param-type">number</span>
11576
11577
11578
11579
11580 </td>
11581
11582
11583 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
11584
11585
11586
11587
11588
11589 </td>
11590
11591
11592
11593 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
11594
11595 </td>
11596
11597
11598 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The value we want to store. It should be a string or a number.</p></td>
11599 </tr>
11600
11601
11602
11603 <tr>
11604
11605 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>days</code></td>
11606
11607
11608 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
11609
11610
11611<span class="param-type">integer</span>
11612
11613
11614
11615
11616 </td>
11617
11618
11619 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
11620
11621 &lt;optional><br>
11622
11623
11624
11625
11626
11627 </td>
11628
11629
11630
11631 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
11632
11633 </td>
11634
11635
11636 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The number of days after which the cookie will expire (in the case that cookies are used). It belongs to the &quot;expires=&quot; parameter of the cookie. If not provided, the parameter will not be used at all.</p></td>
11637 </tr>
11638
11639
11640
11641 <tr>
11642
11643 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>path</code></td>
11644
11645
11646 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
11647
11648
11649<span class="param-type">string</span>
11650
11651
11652
11653
11654 </td>
11655
11656
11657 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
11658
11659 &lt;optional><br>
11660
11661
11662
11663
11664
11665 </td>
11666
11667
11668
11669 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
11670
11671 </td>
11672
11673
11674 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The path where the cookie will be stored (in the case that cookies are used). It belongs to the &quot;path=&quot; parameter of the cookie. If not provided, the parameter will not be used at all.</p></td>
11675 </tr>
11676
11677
11678
11679 <tr>
11680
11681 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>forceCookie</code></td>
11682
11683
11684 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
11685
11686
11687<span class="param-type">boolean</span>
11688
11689
11690
11691
11692 </td>
11693
11694
11695 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
11696
11697 &lt;optional><br>
11698
11699
11700
11701
11702
11703 </td>
11704
11705
11706
11707 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
11708
11709 false
11710
11711 </td>
11712
11713
11714 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Forces to use cookies instead of <a href="https://developer.mozilla.org/en-US/docs/Web/API/Web_Storage_API">Web Storage API</a> (<a href="https://developer.mozilla.org/en-US/docs/Web/API/Window/localStorage">localStorage</a>).</p></td>
11715 </tr>
11716
11717
11718 </tbody>
11719</table>
11720
11721
11722
11723
11724<dl class="details">
11725
11726
11727
11728
11729
11730
11731
11732
11733
11734
11735
11736
11737
11738
11739
11740
11741
11742
11743
11744
11745
11746
11747
11748
11749
11750
11751
11752
11753
11754 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
11755 <dd class="tag-source">
11756 <ul class="dummy">
11757 <li>
11758 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
11759 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-718">line 718</a>
11760 </li>
11761 </ul>
11762 </dd>
11763
11764
11765
11766
11767
11768
11769
11770</dl>
11771
11772
11773
11774
11775
11776
11777
11778
11779
11780
11781
11782
11783
11784 <h5>Returns:</h5>
11785
11786
11787<div class="param-desc">
11788 <p>Returns true if the value has been stored successfully (not totally reliable, it should be checked with <a href="global.html#CB_getDatum"><code>CB_getDatum</code></a> after a while).</p>
11789</div>
11790
11791
11792
11793<dl>
11794 <dt>
11795 Type
11796 </dt>
11797 <dd>
11798
11799<span class="param-type">boolean</span>
11800
11801
11802
11803 </dd>
11804</dl>
11805
11806
11807
11808
11809
11810</dd>
11811
11812
11813
11814<hr>
11815<dt>
11816 <h4 class="name" id="CB_sizeof"><span class="type-signature"></span>CB_sizeof<span class="signature">()</span><span class="type-signature"></span></h4>
11817
11818
11819</dt>
11820<dd>
11821
11822
11823 <div class="description">
11824 <p>Alias for <a href="global.html#CB_sizeOf"><code>CB_sizeOf</code></a>.</p>
11825 </div>
11826
11827
11828
11829
11830
11831
11832
11833
11834
11835
11836<dl class="details">
11837
11838
11839
11840
11841
11842
11843
11844
11845
11846
11847
11848
11849
11850
11851
11852
11853
11854
11855
11856
11857
11858
11859
11860
11861
11862
11863
11864
11865
11866 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
11867 <dd class="tag-source">
11868 <ul class="dummy">
11869 <li>
11870 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
11871 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-195">line 195</a>
11872 </li>
11873 </ul>
11874 </dd>
11875
11876
11877
11878
11879
11880 <dt class="tag-see method-doc-label method-doc-details-label">See:</dt>
11881 <dd class="tag-see">
11882 <ul>
11883 <li><a href="global.html#CB_sizeOf"><code>CB_sizeOf</code></a></li>
11884 </ul>
11885 </dd>
11886
11887
11888
11889</dl>
11890
11891
11892
11893
11894
11895
11896
11897
11898
11899
11900
11901
11902
11903
11904
11905</dd>
11906
11907
11908
11909<hr>
11910<dt>
11911 <h4 class="name" id="CB_sizeOf"><span class="type-signature"></span>CB_sizeOf<span class="signature">(element [, onlyOwn])</span><span class="type-signature"> &rarr; {integer}</span></h4>
11912
11913
11914</dt>
11915<dd>
11916
11917
11918 <div class="description">
11919 <p>Returns the size of an object or array.</p>
11920 </div>
11921
11922
11923
11924
11925
11926
11927
11928
11929 <h5>Parameters:</h5>
11930
11931
11932<table class="params table table-striped">
11933 <thead>
11934 <tr>
11935
11936 <th style="width:12%; min-width:110px;">Name</th>
11937
11938
11939 <th style="width:12%; min-width:110px;">Type</th>
11940
11941
11942 <th style="width:12%; min-width:110px;">Argument</th>
11943
11944
11945
11946 <th style="width:12%; min-width:110px;">Default</th>
11947
11948
11949 <th class="last" style="min-width:310px;">Description</th>
11950 </tr>
11951 </thead>
11952
11953 <tbody>
11954
11955
11956 <tr>
11957
11958 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>element</code></td>
11959
11960
11961 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
11962
11963
11964<span class="param-type">Object</span>
11965|
11966
11967<span class="param-type">array</span>
11968
11969
11970
11971
11972 </td>
11973
11974
11975 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
11976
11977
11978
11979
11980
11981 </td>
11982
11983
11984
11985 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
11986
11987 </td>
11988
11989
11990 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The element whose size we want to know. It should be an object or an array.</p></td>
11991 </tr>
11992
11993
11994
11995 <tr>
11996
11997 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>onlyOwn</code></td>
11998
11999
12000 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12001
12002
12003<span class="param-type">boolean</span>
12004
12005
12006
12007
12008 </td>
12009
12010
12011 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12012
12013 &lt;optional><br>
12014
12015
12016
12017
12018
12019 </td>
12020
12021
12022
12023 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12024
12025 false
12026
12027 </td>
12028
12029
12030 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>If the &quot;element&quot; given is not an object, this parameter will be ignored. Otherwise, if it is set to true, it will only have into account the properties which the object has as their own property and have not been inherited (using the <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/hasOwnProperty">Object.hasOwnProperty</a> method).</p></td>
12031 </tr>
12032
12033
12034 </tbody>
12035</table>
12036
12037
12038
12039
12040<dl class="details">
12041
12042
12043
12044
12045
12046
12047
12048
12049
12050
12051
12052
12053
12054
12055
12056
12057
12058
12059
12060
12061
12062
12063
12064
12065
12066
12067
12068
12069
12070 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
12071 <dd class="tag-source">
12072 <ul class="dummy">
12073 <li>
12074 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
12075 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-207">line 207</a>
12076 </li>
12077 </ul>
12078 </dd>
12079
12080
12081
12082
12083
12084
12085
12086</dl>
12087
12088
12089
12090
12091
12092
12093
12094
12095
12096
12097
12098
12099
12100 <h5>Returns:</h5>
12101
12102
12103<div class="param-desc">
12104 <p>If an object is provided, the size will be the number of its properties. Otherwise, if an array is given, the size will be the numbers of its indexes (<a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/length">Array.length</a> property).</p>
12105</div>
12106
12107
12108
12109<dl>
12110 <dt>
12111 Type
12112 </dt>
12113 <dd>
12114
12115<span class="param-type">integer</span>
12116
12117
12118
12119 </dd>
12120</dl>
12121
12122
12123
12124
12125
12126</dd>
12127
12128
12129
12130<hr>
12131<dt>
12132 <h4 class="name" id="CB_stringifyJSON"><span class="type-signature"></span>CB_stringifyJSON<span class="signature">(objectOrValue [, replacer] [, space] [, returnValueOnFail] [, failIfUndefinedOrNull] [, onError])</span><span class="type-signature"> &rarr; {string}</span></h4>
12133
12134
12135</dt>
12136<dd>
12137
12138
12139 <div class="description">
12140 <p>Tries to create a JSON valid string from a given JSON object or value. Internally it will use the native <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/JSON/stringify">JSON.stringify</a> method or otherwise use <a href="https://bestiejs.github.io/json3/">JSON 3</a> instead.</p>
12141 </div>
12142
12143
12144
12145
12146
12147
12148
12149
12150 <h5>Parameters:</h5>
12151
12152
12153<table class="params table table-striped">
12154 <thead>
12155 <tr>
12156
12157 <th style="width:12%; min-width:110px;">Name</th>
12158
12159
12160 <th style="width:12%; min-width:110px;">Type</th>
12161
12162
12163 <th style="width:12%; min-width:110px;">Argument</th>
12164
12165
12166
12167 <th style="width:12%; min-width:110px;">Default</th>
12168
12169
12170 <th class="last" style="min-width:310px;">Description</th>
12171 </tr>
12172 </thead>
12173
12174 <tbody>
12175
12176
12177 <tr>
12178
12179 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>objectOrValue</code></td>
12180
12181
12182 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12183
12184
12185<span class="param-type">*</span>
12186
12187
12188
12189
12190 </td>
12191
12192
12193 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12194
12195
12196
12197
12198
12199 </td>
12200
12201
12202
12203 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12204
12205 </td>
12206
12207
12208 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The object or value that we want to stringify. First parameter when calling the <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/JSON/stringify">JSON.stringify</a> method (or equivalent).</p></td>
12209 </tr>
12210
12211
12212
12213 <tr>
12214
12215 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>replacer</code></td>
12216
12217
12218 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12219
12220
12221<span class="param-type">function</span>
12222
12223
12224
12225
12226 </td>
12227
12228
12229 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12230
12231 &lt;optional><br>
12232
12233
12234
12235
12236
12237 </td>
12238
12239
12240
12241 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12242
12243 </td>
12244
12245
12246 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Second parameter when calling the <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/JSON/stringify">JSON.stringify</a> method (or equivalent).</p></td>
12247 </tr>
12248
12249
12250
12251 <tr>
12252
12253 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>space</code></td>
12254
12255
12256 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12257
12258
12259<span class="param-type">string</span>
12260|
12261
12262<span class="param-type">integer</span>
12263
12264
12265
12266
12267 </td>
12268
12269
12270 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12271
12272 &lt;optional><br>
12273
12274
12275
12276
12277
12278 </td>
12279
12280
12281
12282 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12283
12284 </td>
12285
12286
12287 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Third parameter when calling the <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/JSON/stringify">JSON.stringify</a> method (or equivalent).</p></td>
12288 </tr>
12289
12290
12291
12292 <tr>
12293
12294 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>returnValueOnFail</code></td>
12295
12296
12297 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12298
12299
12300<span class="param-type">*</span>
12301
12302
12303
12304
12305 </td>
12306
12307
12308 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12309
12310 &lt;optional><br>
12311
12312
12313
12314
12315
12316 </td>
12317
12318
12319
12320 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12321
12322 </td>
12323
12324
12325 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The value we want it to return in the case it cannot be stringify. If not provided, undefined will be returned.</p></td>
12326 </tr>
12327
12328
12329
12330 <tr>
12331
12332 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>failIfUndefinedOrNull</code></td>
12333
12334
12335 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12336
12337
12338<span class="param-type">boolean</span>
12339
12340
12341
12342
12343 </td>
12344
12345
12346 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12347
12348 &lt;optional><br>
12349
12350
12351
12352
12353
12354 </td>
12355
12356
12357
12358 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12359
12360 false
12361
12362 </td>
12363
12364
12365 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>If it is set to true and the returning value is undefined or null, the value of &quot;returnValueOnFail&quot; will be returned.</p></td>
12366 </tr>
12367
12368
12369
12370 <tr>
12371
12372 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>onError</code></td>
12373
12374
12375 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12376
12377
12378<span class="param-type">function</span>
12379
12380
12381
12382
12383 </td>
12384
12385
12386 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12387
12388 &lt;optional><br>
12389
12390
12391
12392
12393
12394 </td>
12395
12396
12397
12398 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12399
12400 </td>
12401
12402
12403 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Callback which will be called if it failed to be stringified (it will receive the &quot;objectOrValue&quot; as the unique parameter).</p></td>
12404 </tr>
12405
12406
12407 </tbody>
12408</table>
12409
12410
12411
12412
12413<dl class="details">
12414
12415
12416
12417
12418
12419
12420
12421
12422
12423
12424
12425
12426
12427
12428
12429
12430
12431
12432
12433
12434
12435
12436
12437
12438
12439
12440
12441
12442
12443 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
12444 <dd class="tag-source">
12445 <ul class="dummy">
12446 <li>
12447 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
12448 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-917">line 917</a>
12449 </li>
12450 </ul>
12451 </dd>
12452
12453
12454
12455
12456
12457
12458
12459</dl>
12460
12461
12462
12463
12464
12465
12466
12467
12468
12469
12470
12471
12472
12473 <h5>Returns:</h5>
12474
12475
12476<div class="param-desc">
12477 <p>Returns the object stringified from the given object or value if possible or the value of &quot;returnValueOnFail&quot; otherwise (which will be undefined if not provided). Avoids returning undefined or null if &quot;failIfUndefinedOrNull&quot; is set to true, returning the value of &quot;returnValueOnFail&quot; instead.</p>
12478</div>
12479
12480
12481
12482<dl>
12483 <dt>
12484 Type
12485 </dt>
12486 <dd>
12487
12488<span class="param-type">string</span>
12489
12490
12491
12492 </dd>
12493</dl>
12494
12495
12496
12497
12498
12499</dd>
12500
12501
12502
12503<hr>
12504<dt>
12505 <h4 class="name" id="CB_symmetricCall"><span class="type-signature"></span>CB_symmetricCall<span class="signature">(callbackFunction, timeMs [, id])</span><span class="type-signature"> &rarr; {number|null}</span></h4>
12506
12507
12508</dt>
12509<dd>
12510
12511
12512 <div class="description">
12513 <p>Calls the given function once through the native <a href="https://developer.mozilla.org/docs/Web/API/WindowOrWorkerGlobalScope/setTimeout">setTimeout</a> function internally but having in mind the time taken when the function was called previously so it can be called multiple times and respect a symmetric interval between each call (simulates <a href="https://developer.mozilla.org/en-US/docs/Web/API/window/requestAnimationFrame">requestAnimationFrame</a>).</p>
12514 </div>
12515
12516
12517
12518
12519
12520
12521
12522
12523 <h5>Parameters:</h5>
12524
12525
12526<table class="params table table-striped">
12527 <thead>
12528 <tr>
12529
12530 <th style="width:12%; min-width:110px;">Name</th>
12531
12532
12533 <th style="width:12%; min-width:110px;">Type</th>
12534
12535
12536 <th style="width:12%; min-width:110px;">Argument</th>
12537
12538
12539
12540 <th style="width:12%; min-width:110px;">Default</th>
12541
12542
12543 <th class="last" style="min-width:310px;">Description</th>
12544 </tr>
12545 </thead>
12546
12547 <tbody>
12548
12549
12550 <tr>
12551
12552 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>callbackFunction</code></td>
12553
12554
12555 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12556
12557
12558<span class="param-type"><a href="global.html#CB_symmetricCall_CALLBACK">CB_symmetricCall_CALLBACK</a></span>
12559
12560
12561
12562
12563 </td>
12564
12565
12566 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12567
12568
12569
12570
12571
12572 </td>
12573
12574
12575
12576 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12577
12578 </td>
12579
12580
12581 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Function that will be called every time, receiving as the unique parameter the time (timestamp in milliseconds returned by the <a href="https://developer.mozilla.org/en-US/docs/Web/API/Performance/now">performance.now</a> method, which could have been polyfilled automatically by CrossBrowdy) when it is called, being &quot;this&quot; the same &quot;this&quot; of the scope where it was called.</p></td>
12582 </tr>
12583
12584
12585
12586 <tr>
12587
12588 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>timeMs</code></td>
12589
12590
12591 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12592
12593
12594<span class="param-type">integer</span>
12595
12596
12597
12598
12599 </td>
12600
12601
12602 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12603
12604
12605
12606
12607
12608 </td>
12609
12610
12611
12612 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12613
12614 </td>
12615
12616
12617 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Milliseconds between one call to the function and the next one. The accuracy will depend on many factors as the platform used, code performance, etc.</p></td>
12618 </tr>
12619
12620
12621
12622 <tr>
12623
12624 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>id</code></td>
12625
12626
12627 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12628
12629
12630<span class="param-type">string</span>
12631
12632
12633
12634
12635 </td>
12636
12637
12638 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12639
12640 &lt;optional><br>
12641
12642
12643
12644
12645
12646 </td>
12647
12648
12649
12650 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12651
12652 callbackFunction.toString()
12653
12654 </td>
12655
12656
12657 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>String that will identify this symmetric interval. Recommended to avoid possible problems.</p></td>
12658 </tr>
12659
12660
12661 </tbody>
12662</table>
12663
12664
12665
12666
12667<dl class="details">
12668
12669
12670
12671
12672
12673
12674
12675
12676
12677
12678
12679
12680
12681
12682
12683
12684
12685
12686
12687
12688
12689
12690
12691
12692
12693
12694
12695
12696
12697 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
12698 <dd class="tag-source">
12699 <ul class="dummy">
12700 <li>
12701 <a href="CrossBase_general_CB_others.js.html">CrossBase/general/CB_others.js</a>,
12702 <a href="CrossBase_general_CB_others.js.html#sunlight-1-line-25">line 25</a>
12703 </li>
12704 </ul>
12705 </dd>
12706
12707
12708
12709
12710
12711
12712
12713</dl>
12714
12715
12716
12717
12718
12719
12720
12721
12722
12723
12724
12725
12726
12727 <h5>Returns:</h5>
12728
12729
12730<div class="param-desc">
12731 <p>Returns a numeric identifier generated by an internal call to the native <a href="https://developer.mozilla.org/docs/Web/API/WindowOrWorkerGlobalScope/setTimeout">setTimeout</a> function (can be cleared/cancelled with <a href="https://developer.mozilla.org/en-US/docs/Web/API/WindowOrWorkerGlobalScope/clearTimeout">clearTimeout</a>). Returns null if the given &quot;callbackFunction&quot; is not a valid function.</p>
12732</div>
12733
12734
12735
12736<dl>
12737 <dt>
12738 Type
12739 </dt>
12740 <dd>
12741
12742<span class="param-type">number</span>
12743|
12744
12745<span class="param-type">null</span>
12746
12747
12748
12749 </dd>
12750</dl>
12751
12752
12753
12754
12755
12756</dd>
12757
12758
12759
12760<hr>
12761<dt>
12762 <h4 class="name" id="CB_symmetricCallClear"><span class="type-signature"></span>CB_symmetricCallClear<span class="signature">(id)</span><span class="type-signature"> &rarr; {boolean|null}</span></h4>
12763
12764
12765</dt>
12766<dd>
12767
12768
12769 <div class="description">
12770 <p>Clears the stored last time used by <a href="global.html#CB_symmetricCall"><code>CB_symmetricCall</code></a> for a given symmetric interval identifier.</p>
12771 </div>
12772
12773
12774
12775
12776
12777
12778
12779
12780 <h5>Parameters:</h5>
12781
12782
12783<table class="params table table-striped">
12784 <thead>
12785 <tr>
12786
12787 <th style="width:12%; min-width:110px;">Name</th>
12788
12789
12790 <th style="width:12%; min-width:110px;">Type</th>
12791
12792
12793
12794
12795
12796 <th class="last" style="min-width:310px;">Description</th>
12797 </tr>
12798 </thead>
12799
12800 <tbody>
12801
12802
12803 <tr>
12804
12805 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>id</code></td>
12806
12807
12808 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12809
12810
12811<span class="param-type">string</span>
12812
12813
12814
12815
12816 </td>
12817
12818
12819
12820
12821
12822 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>String that identifies this symmetric interval.</p></td>
12823 </tr>
12824
12825
12826 </tbody>
12827</table>
12828
12829
12830
12831
12832<dl class="details">
12833
12834
12835
12836
12837
12838
12839
12840
12841
12842
12843
12844
12845
12846
12847
12848
12849
12850
12851
12852
12853
12854
12855
12856
12857
12858
12859
12860
12861
12862 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
12863 <dd class="tag-source">
12864 <ul class="dummy">
12865 <li>
12866 <a href="CrossBase_general_CB_others.js.html">CrossBase/general/CB_others.js</a>,
12867 <a href="CrossBase_general_CB_others.js.html#sunlight-1-line-73">line 73</a>
12868 </li>
12869 </ul>
12870 </dd>
12871
12872
12873
12874
12875
12876
12877
12878</dl>
12879
12880
12881
12882
12883
12884
12885
12886
12887
12888
12889
12890
12891
12892 <h5>Returns:</h5>
12893
12894
12895<div class="param-desc">
12896 <p>Returns null if the given &quot;id&quot; is not a valid string. Returns false if the stored time did not exist for the given &quot;id&quot; or it was cleared already. Returns true otherwise, after clearing it.</p>
12897</div>
12898
12899
12900
12901<dl>
12902 <dt>
12903 Type
12904 </dt>
12905 <dd>
12906
12907<span class="param-type">boolean</span>
12908|
12909
12910<span class="param-type">null</span>
12911
12912
12913
12914 </dd>
12915</dl>
12916
12917
12918
12919
12920
12921</dd>
12922
12923
12924
12925<hr>
12926<dt>
12927 <h4 class="name" id="CB_trim"><span class="type-signature"></span>CB_trim<span class="signature">(element [, undesiredStrings])</span><span class="type-signature"> &rarr; {string|array}</span></h4>
12928
12929
12930</dt>
12931<dd>
12932
12933
12934 <div class="description">
12935 <p>Trims a given string or array of strings (modifying the given array), taking off the desired strings or otherwise trimming spaces, tabs (&quot;\t&quot;), new lines (&quot;\n&quot;) and carriage returns (&quot;\r&quot;). Case sensitive.</p>
12936 </div>
12937
12938
12939
12940
12941
12942
12943
12944
12945 <h5>Parameters:</h5>
12946
12947
12948<table class="params table table-striped">
12949 <thead>
12950 <tr>
12951
12952 <th style="width:12%; min-width:110px;">Name</th>
12953
12954
12955 <th style="width:12%; min-width:110px;">Type</th>
12956
12957
12958 <th style="width:12%; min-width:110px;">Argument</th>
12959
12960
12961
12962 <th style="width:12%; min-width:110px;">Default</th>
12963
12964
12965 <th class="last" style="min-width:310px;">Description</th>
12966 </tr>
12967 </thead>
12968
12969 <tbody>
12970
12971
12972 <tr>
12973
12974 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>element</code></td>
12975
12976
12977 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12978
12979
12980<span class="param-type">string</span>
12981|
12982
12983<span class="param-type">array</span>
12984
12985
12986
12987
12988 </td>
12989
12990
12991 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
12992
12993
12994
12995
12996
12997 </td>
12998
12999
13000
13001 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
13002
13003 </td>
13004
13005
13006 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The element that will be trimmed. It should be either a string or an array of strings.</p></td>
13007 </tr>
13008
13009
13010
13011 <tr>
13012
13013 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>undesiredStrings</code></td>
13014
13015
13016 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
13017
13018
13019<span class="param-type">string</span>
13020|
13021
13022<span class="param-type">array</span>
13023
13024
13025
13026
13027 </td>
13028
13029
13030 <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
13031
13032 &lt;optional><br>
13033
13034
13035
13036
13037
13038 </td>
13039
13040
13041
13042 <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
13043
13044 [ " ", "\n", "\r", "\t" ]
13045
13046 </td>
13047
13048
13049 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>String or an array with the strings that we want to trim off the given element.</p></td>
13050 </tr>
13051
13052
13053 </tbody>
13054</table>
13055
13056
13057
13058
13059<dl class="details">
13060
13061
13062
13063
13064
13065
13066
13067
13068
13069
13070
13071
13072
13073
13074
13075
13076
13077
13078
13079
13080
13081
13082
13083
13084
13085
13086
13087
13088
13089 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
13090 <dd class="tag-source">
13091 <ul class="dummy">
13092 <li>
13093 <a href="CrossBase_general_CB_data.js.html">CrossBase/general/CB_data.js</a>,
13094 <a href="CrossBase_general_CB_data.js.html#sunlight-1-line-267">line 267</a>
13095 </li>
13096 </ul>
13097 </dd>
13098
13099
13100
13101
13102
13103
13104
13105 <dt class="tag-todo method-doc-label method-doc-details-label">To Do:</dt>
13106 <dd class="tag-todo">
13107 <ul>
13108 <li>Accept a "recursive" parameter (boolean) to affect multiple levels (array of arrays of strings, etc.).</li>
13109
13110 <li>Consider accepting objects instead of arrays in the "element" parameter.</li>
13111 </ul>
13112 </dd>
13113
13114</dl>
13115
13116
13117
13118
13119
13120
13121
13122
13123
13124
13125
13126
13127
13128 <h5>Returns:</h5>
13129
13130
13131<div class="param-desc">
13132 <p>Returns the given element again if it was an string, a number (it will be casted to a string) or an array of strings, trimmed if it has been possible. If it was another type, returns an empty string.</p>
13133</div>
13134
13135
13136
13137<dl>
13138 <dt>
13139 Type
13140 </dt>
13141 <dd>
13142
13143<span class="param-type">string</span>
13144|
13145
13146<span class="param-type">array</span>
13147
13148
13149
13150 </dd>
13151</dl>
13152
13153
13154
13155
13156
13157</dd>
13158
13159 </dl>
13160
13161
13162
13163 <h3 class="subsection-title">Type Definitions</h3>
13164
13165 <dl>
13166
13167<hr>
13168<dt>
13169 <h4 class="name" id="CB_includeJSFile_CALLBACK"><span class="type-signature"></span>CB_includeJSFile_CALLBACK<span class="signature">(filepath, callbackOk, callbackError, timeoutMs, asynchronously)</span><span class="type-signature"></span></h4>
13170
13171
13172</dt>
13173<dd>
13174
13175
13176 <div class="description">
13177 <p>Callback for when the file is included successfully or fails to load.</p>
13178 </div>
13179
13180
13181
13182
13183
13184
13185
13186
13187 <h5>Parameters:</h5>
13188
13189
13190<table class="params table table-striped">
13191 <thead>
13192 <tr>
13193
13194 <th style="width:12%; min-width:110px;">Name</th>
13195
13196
13197 <th style="width:12%; min-width:110px;">Type</th>
13198
13199
13200
13201
13202
13203 <th class="last" style="min-width:310px;">Description</th>
13204 </tr>
13205 </thead>
13206
13207 <tbody>
13208
13209
13210 <tr>
13211
13212 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>filepath</code></td>
13213
13214
13215 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
13216
13217
13218<span class="param-type">string</span>
13219
13220
13221
13222
13223 </td>
13224
13225
13226
13227
13228
13229 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The 'filepath' parameter when <a href="global.html#CB_includeJSFile"><code>CB_includeJSFile</code></a> was called (if any).</p></td>
13230 </tr>
13231
13232
13233
13234 <tr>
13235
13236 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>callbackOk</code></td>
13237
13238
13239 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
13240
13241
13242<span class="param-type"><a href="global.html#CB_includeJSFile_CALLBACK">CB_includeJSFile_CALLBACK</a></span>
13243
13244
13245
13246
13247 </td>
13248
13249
13250
13251
13252
13253 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The 'callbackOk' parameter when <a href="global.html#CB_includeJSFile"><code>CB_includeJSFile</code></a> was called (if any).</p></td>
13254 </tr>
13255
13256
13257
13258 <tr>
13259
13260 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>callbackError</code></td>
13261
13262
13263 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
13264
13265
13266<span class="param-type"><a href="global.html#CB_includeJSFile_CALLBACK">CB_includeJSFile_CALLBACK</a></span>
13267
13268
13269
13270
13271 </td>
13272
13273
13274
13275
13276
13277 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The 'callbackError' parameter when <a href="global.html#CB_includeJSFile"><code>CB_includeJSFile</code></a> was called (if any).</p></td>
13278 </tr>
13279
13280
13281
13282 <tr>
13283
13284 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>timeoutMs</code></td>
13285
13286
13287 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
13288
13289
13290<span class="param-type">integer</span>
13291
13292
13293
13294
13295 </td>
13296
13297
13298
13299
13300
13301 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The 'timeoutMs' parameter when <a href="global.html#CB_includeJSFile"><code>CB_includeJSFile</code></a> was called (if any).</p></td>
13302 </tr>
13303
13304
13305
13306 <tr>
13307
13308 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>asynchronously</code></td>
13309
13310
13311 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
13312
13313
13314<span class="param-type">boolean</span>
13315
13316
13317
13318
13319 </td>
13320
13321
13322
13323
13324
13325 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The 'asynchronously' parameter when <a href="global.html#CB_includeJSFile"><code>CB_includeJSFile</code></a> was called (if any).</p></td>
13326 </tr>
13327
13328
13329 </tbody>
13330</table>
13331
13332
13333
13334
13335<dl class="details">
13336
13337
13338
13339
13340
13341
13342
13343
13344
13345
13346
13347
13348
13349
13350
13351
13352
13353
13354
13355
13356
13357
13358
13359
13360
13361
13362
13363
13364
13365 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
13366 <dd class="tag-source">
13367 <ul class="dummy">
13368 <li>
13369 <a href="CrossBrowdy.js.html">CrossBrowdy.js</a>,
13370 <a href="CrossBrowdy.js.html#sunlight-1-line-360">line 360</a>
13371 </li>
13372 </ul>
13373 </dd>
13374
13375
13376
13377
13378
13379
13380
13381</dl>
13382
13383
13384
13385
13386
13387
13388
13389
13390
13391
13392
13393
13394
13395
13396
13397</dd>
13398
13399
13400
13401<hr>
13402<dt>
13403 <h4 class="name" id="CB_includeRequiredFileErrorCallback"><span class="type-signature"></span>CB_includeRequiredFileErrorCallback<span class="signature">(filepath, callbackOk, callbackError, timeoutMs, asynchronously, filesRequested, filesLoaded)</span><span class="type-signature"></span></h4>
13404
13405
13406</dt>
13407<dd>
13408
13409
13410 <div class="description">
13411 <p>Callback for when the script is loaded successfully. Without parameters.</p>
13412 </div>
13413
13414
13415
13416
13417
13418
13419
13420
13421 <h5>Parameters:</h5>
13422
13423
13424<table class="params table table-striped">
13425 <thead>
13426 <tr>
13427
13428 <th style="width:12%; min-width:110px;">Name</th>
13429
13430
13431 <th style="width:12%; min-width:110px;">Type</th>
13432
13433
13434
13435
13436
13437 <th class="last" style="min-width:310px;">Description</th>
13438 </tr>
13439 </thead>
13440
13441 <tbody>
13442
13443
13444 <tr>
13445
13446 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>filepath</code></td>
13447
13448
13449 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
13450
13451
13452<span class="param-type">string</span>
13453
13454
13455
13456
13457 </td>
13458
13459
13460
13461
13462
13463 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The 'filepath' parameter when <a href="global.html#CB_includeJSFile"><code>CB_includeJSFile</code></a> was called internally (if any).</p></td>
13464 </tr>
13465
13466
13467
13468 <tr>
13469
13470 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>callbackOk</code></td>
13471
13472
13473 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
13474
13475
13476<span class="param-type"><a href="global.html#CB_includeJSFile_CALLBACK">CB_includeJSFile_CALLBACK</a></span>
13477
13478
13479
13480
13481 </td>
13482
13483
13484
13485
13486
13487 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The 'callbackOk' parameter when <a href="global.html#CB_includeJSFile"><code>CB_includeJSFile</code></a> was called internally (if any).</p></td>
13488 </tr>
13489
13490
13491
13492 <tr>
13493
13494 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>callbackError</code></td>
13495
13496
13497 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
13498
13499
13500<span class="param-type"><a href="global.html#CB_includeJSFile_CALLBACK">CB_includeJSFile_CALLBACK</a></span>
13501
13502
13503
13504
13505 </td>
13506
13507
13508
13509
13510
13511 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The 'callbackError' parameter when <a href="global.html#CB_includeJSFile"><code>CB_includeJSFile</code></a> was called internally (if any).</p></td>
13512 </tr>
13513
13514
13515
13516 <tr>
13517
13518 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>timeoutMs</code></td>
13519
13520
13521 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
13522
13523
13524<span class="param-type">integer</span>
13525
13526
13527
13528
13529 </td>
13530
13531
13532
13533
13534
13535 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The 'timeoutMs' parameter when <a href="global.html#CB_includeJSFile"><code>CB_includeJSFile</code></a> was called internally (if any).</p></td>
13536 </tr>
13537
13538
13539
13540 <tr>
13541
13542 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>asynchronously</code></td>
13543
13544
13545 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
13546
13547
13548<span class="param-type">boolean</span>
13549
13550
13551
13552
13553 </td>
13554
13555
13556
13557
13558
13559 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The 'asynchronously' parameter when <a href="global.html#CB_includeJSFile"><code>CB_includeJSFile</code></a> was called (if any).</p></td>
13560 </tr>
13561
13562
13563
13564 <tr>
13565
13566 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>filesRequested</code></td>
13567
13568
13569 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
13570
13571
13572<span class="param-type">object</span>
13573
13574
13575
13576
13577 </td>
13578
13579
13580
13581
13582
13583 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Object whose indexes are all the filepaths of the script files requested so far and the value is true when the file is still loading (or to be loaded in the future), false if it was loaded successfully (the most likely) or null if it failed to load.</p></td>
13584 </tr>
13585
13586
13587
13588 <tr>
13589
13590 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>filesLoaded</code></td>
13591
13592
13593 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
13594
13595
13596<span class="param-type">array</span>
13597
13598
13599
13600
13601 </td>
13602
13603
13604
13605
13606
13607 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Numeric array whose values are the filepaths of the script files loaded successfully so far.</p></td>
13608 </tr>
13609
13610
13611 </tbody>
13612</table>
13613
13614
13615
13616
13617<dl class="details">
13618
13619
13620
13621
13622
13623
13624
13625
13626
13627
13628
13629
13630
13631
13632
13633
13634
13635
13636
13637
13638
13639
13640
13641
13642
13643
13644
13645
13646
13647 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
13648 <dd class="tag-source">
13649 <ul class="dummy">
13650 <li>
13651 <a href="CrossBrowdy.js.html">CrossBrowdy.js</a>,
13652 <a href="CrossBrowdy.js.html#sunlight-1-line-485">line 485</a>
13653 </li>
13654 </ul>
13655 </dd>
13656
13657
13658
13659
13660
13661
13662
13663</dl>
13664
13665
13666
13667
13668
13669
13670
13671
13672
13673
13674
13675
13676
13677
13678
13679</dd>
13680
13681
13682
13683<hr>
13684<dt>
13685 <h4 class="name" id="CB_init_CALLBACK"><span class="type-signature"></span>CB_init_CALLBACK<span class="signature">()</span><span class="type-signature"></span></h4>
13686
13687
13688</dt>
13689<dd>
13690
13691
13692 <div class="description">
13693 <p>Callback for when the script is loaded successfully. Without parameters.</p>
13694 </div>
13695
13696
13697
13698
13699
13700
13701
13702
13703
13704
13705<dl class="details">
13706
13707
13708
13709
13710
13711
13712
13713
13714
13715
13716
13717
13718
13719
13720
13721
13722
13723
13724
13725
13726
13727
13728
13729
13730
13731
13732
13733
13734
13735 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
13736 <dd class="tag-source">
13737 <ul class="dummy">
13738 <li>
13739 <a href="CrossBrowdy.js.html">CrossBrowdy.js</a>,
13740 <a href="CrossBrowdy.js.html#sunlight-1-line-1035">line 1035</a>
13741 </li>
13742 </ul>
13743 </dd>
13744
13745
13746
13747
13748
13749
13750
13751</dl>
13752
13753
13754
13755
13756
13757
13758
13759
13760
13761
13762
13763
13764
13765
13766
13767</dd>
13768
13769
13770
13771<hr>
13772<dt>
13773 <h4 class="name" id="CB_symmetricCall_CALLBACK"><span class="type-signature"></span>CB_symmetricCall_CALLBACK<span class="signature">(expectedCallingTime)</span><span class="type-signature"></span></h4>
13774
13775
13776</dt>
13777<dd>
13778
13779
13780 <div class="description">
13781 <p>Callback that is called by <a href="global.html#CB_symmetricCall"><code>CB_symmetricCall</code></a>.</p>
13782 </div>
13783
13784
13785
13786
13787
13788
13789
13790
13791 <h5>Parameters:</h5>
13792
13793
13794<table class="params table table-striped">
13795 <thead>
13796 <tr>
13797
13798 <th style="width:12%; min-width:110px;">Name</th>
13799
13800
13801 <th style="width:12%; min-width:110px;">Type</th>
13802
13803
13804
13805
13806
13807 <th class="last" style="min-width:310px;">Description</th>
13808 </tr>
13809 </thead>
13810
13811 <tbody>
13812
13813
13814 <tr>
13815
13816 <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>expectedCallingTime</code></td>
13817
13818
13819 <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
13820
13821
13822<span class="param-type">integer</span>
13823
13824
13825
13826
13827 </td>
13828
13829
13830
13831
13832
13833 <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The timestamp in milliseconds that represents when the callback should have been called (it will be more or less accurate depending on many factors as the platform used, code performance, etc.).</p></td>
13834 </tr>
13835
13836
13837 </tbody>
13838</table>
13839
13840
13841
13842
13843<dl class="details">
13844
13845
13846
13847
13848
13849
13850
13851
13852
13853
13854
13855
13856
13857
13858
13859
13860
13861
13862
13863
13864
13865
13866
13867
13868
13869
13870
13871
13872
13873 <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
13874 <dd class="tag-source">
13875 <ul class="dummy">
13876 <li>
13877 <a href="CrossBase_general_CB_others.js.html">CrossBase/general/CB_others.js</a>,
13878 <a href="CrossBase_general_CB_others.js.html#sunlight-1-line-9">line 9</a>
13879 </li>
13880 </ul>
13881 </dd>
13882
13883
13884
13885
13886
13887
13888
13889</dl>
13890
13891
13892
13893
13894
13895
13896
13897
13898
13899
13900
13901
13902
13903
13904
13905</dd>
13906
13907 </dl>
13908
13909
13910
13911</article>
13912
13913</section>
13914
13915
13916
13917
13918 </div>
13919 </div>
13920
13921 <div class="clearfix"></div>
13922
13923
13924 <div class="col-md-3">
13925 <div id="toc" class="col-md-3 hidden-xs hidden-sm hidden-md"></div>
13926 </div>
13927
13928
13929</div>
13930</div>
13931
13932
13933 <div class="modal fade" id="searchResults">
13934 <div class="modal-dialog">
13935 <div class="modal-content">
13936 <div class="modal-header">
13937 <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
13938 <h4 class="modal-title">Search results</h4>
13939 </div>
13940 <div class="modal-body"></div>
13941 <div class="modal-footer">
13942 <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
13943 </div>
13944 </div><!-- /.modal-content -->
13945 </div><!-- /.modal-dialog -->
13946 </div>
13947
13948
13949<footer>
13950
13951
13952 <span class="copyright">
13953 <a href="printable/" target="_blank">See a more printer-friendly version</a><hr /><span style="color:#000000">© <address style="display:inline; font-style:normal;"><a href="https://crossbrowdy.com/" target="_blank">CrossBrowdy</a> API documentation</address> by <a href="https://joanalbamaldonado.com/" target="_blank">Joan Alba Maldonado</a> - <a href="https://creativecommons.org/licenses/by/4.0/" target="_blank">Creative Commons Attribution 4.0 International</a><br />DocStrap Copyright © 2012-2015 The contributors to the JSDoc3 and DocStrap projects.</span>
13954 </span>
13955
13956<span class="jsdoc-message">
13957 Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.5.5</a>
13958
13959 on Mon Feb 3rd 2020
13960
13961 using the <a href="https://github.com/docstrap/docstrap">DocStrap template</a>.
13962</span>
13963</footer>
13964
13965<script src="scripts/docstrap.lib.js"></script>
13966<script src="scripts/toc.js"></script>
13967
13968 <script type="text/javascript" src="scripts/fulltext-search-ui.js"></script>
13969
13970
13971<script>
13972$( function () {
13973 $( "[id*='$']" ).each( function () {
13974 var $this = $( this );
13975
13976 $this.attr( "id", $this.attr( "id" ).replace( "$", "__" ) );
13977 } );
13978
13979 $( ".tutorial-section pre, .readme-section pre, pre.prettyprint.source" ).each( function () {
13980 var $this = $( this );
13981
13982 var example = $this.find( "code" );
13983 exampleText = example.html();
13984 var lang = /{@lang (.*?)}/.exec( exampleText );
13985 if ( lang && lang[1] ) {
13986 exampleText = exampleText.replace( lang[0], "" );
13987 example.html( exampleText );
13988 lang = lang[1];
13989 } else {
13990 var langClassMatch = example.parent()[0].className.match(/lang\-(\S+)/);
13991 lang = langClassMatch ? langClassMatch[1] : "javascript";
13992 }
13993
13994 if ( lang ) {
13995
13996 $this
13997 .addClass( "sunlight-highlight-" + lang )
13998 .addClass( "linenums" )
13999 .html( example.html() );
14000
14001 }
14002 } );
14003
14004 Sunlight.highlightAll( {
14005 lineNumbers : true,
14006 showMenu : true,
14007 enableDoclinks : true
14008 } );
14009
14010 $.catchAnchorLinks( {
14011 navbarOffset: 10
14012 } );
14013 $( "#toc" ).toc( {
14014 anchorName : function ( i, heading, prefix ) {
14015 return $( heading ).attr( "id" ) || ( prefix + i );
14016 },
14017 selectors : "#toc-content h1,#toc-content h2,#toc-content h3,#toc-content h4",
14018 showAndHide : false,
14019 smoothScrolling: true
14020 } );
14021
14022 $( "#main span[id^='toc']" ).addClass( "toc-shim" );
14023 $( '.dropdown-toggle' ).dropdown();
14024
14025 $( "table" ).each( function () {
14026 var $this = $( this );
14027 $this.addClass('table');
14028 } );
14029
14030} );
14031</script>
14032
14033
14034
14035<!--Navigation and Symbol Display-->
14036
14037<script>
14038 $( function () {
14039 $( '#main' ).localScroll( {
14040 offset : { top : 60 } //offset by the height of your header (give or take a few px, see what works for you)
14041 } );
14042 $( "dt.name" ).each( function () {
14043 var $this = $( this ).find("h4");
14044 var icon = $( "<i/>" ).addClass( "icon-plus-sign" ).addClass( "pull-right" ).addClass( "icon-white" );
14045 var dt = $(this);
14046 var children = dt.next( "dd" );
14047
14048 dt.prepend( icon ).css( {cursor : "pointer"} );
14049 dt.addClass( "member-collapsed" ).addClass( "member" );
14050
14051
14052 children.hide();
14053
14054 dt.children().on( "click", function () {
14055 children = dt.next( "dd" );
14056 children.slideToggle( "fast", function () {
14057
14058 if ( children.is( ":visible" ) ) {
14059 icon.addClass( "icon-minus-sign" ).removeClass( "icon-plus-sign" ).removeClass( "icon-white" );
14060 dt.addClass( "member-open" ).animate( "member-collapsed" );
14061 } else {
14062 icon.addClass( "icon-plus-sign" ).removeClass( "icon-minus-sign" ).addClass( "icon-white" );
14063 dt.addClass( "member-collapsed" ).removeClass( "member-open" );
14064 }
14065 } );
14066 } );
14067
14068 } );
14069 } );
14070</script>
14071
14072
14073<!--Google Analytics-->
14074
14075
14076
14077 <script type="text/javascript">
14078 $(document).ready(function() {
14079 SearcherDisplay.init();
14080 });
14081 </script>
14082
14083
14084</body>
14085</html>
\No newline at end of file