1/** 2 * NOTICE OF LICENSE 3 * 4 * This source file is subject to the Academic Free License version 3.0 5 * that is bundled with this package in the file LICENSE.txt 6 * It is also available through the world-wide-web at this URL: 7 * https://opensource.org/licenses/AFL-3.0 8 * 9 * DISCLAIMER 10 * 11 * Do not edit or add to this file if you wish to upgrade this module to a newer 12 * versions in the future. If you wish to customize this module for your 13 * needs please refer to CustomizationPolicy.txt file inside our module for more information. 14 * 15 * @author Webkul IN 16 * @copyright Since 2010 Webkul 17 * @license https://opensource.org/licenses/AFL-3.0 Academic Free License version 3.0 18 */ 19 20$(document).ready(function () { 21 afterPageLoadScript(); 22 setTimeout(function () { 23 $('[data-set-default="1"]').each(function () { 24 const $input = $(this); 25 const $variantItem = $input.closest('.wk-product-variants-item'); 26 const idField = $input.data('id_field'); 27 28 // Handle radio buttons 29 if ($input.hasClass('wk_radio_selected')) { 30 const idValue = $input.data('id-radio-val'); 31 $('#wk_option_radio_value_id_' + idField).val(idValue); 32 } 33 34 // Handle single dropdowns 35 if ($input.hasClass('wk_select_dropdown_single')) { 36 const idValue = $input.find(':selected').data('id-option-val'); 37 $('#wk_option_dropdown_value_id_' + idField).val(idValue); 38 } 39 40 // Handle multiple dropdowns 41 if ($input.hasClass('wk_select_dropdown_multiple')) { 42 const selectedValue = $input.val(); 43 $('#wk_option_dropdown_value_id_multi_' + idField).val(selectedValue.toString()); 44 } 45 46 // Handle checkboxes 47 if ($input.hasClass('wk_checkbox_selected')) { 48 const itemValue = $input.data('id-check-val'); 49 let selectedValue = $('#wk_option_checkbox_value_id_' + idField).val(); 50 selectedValue = selectedValue ? selectedValue + ',' + itemValue : itemValue; 51 $('#wk_option_checkbox_value_id_' + idField).val(selectedValue); 52 } 53 54 // Only trigger update if parent checkbox is checked 55 if ($variantItem.find('.wk_option_checkbox_parent').prop('checked') === true) { 56 updatePsPrice(); 57 } 58 updatePsPrice(); 59 }); 60 }, 100) 61 // hide customization block for option on order-summary checkout page 62 $('.wk-customization-option-modal').closest('.order-line').find('.customizations').css('display', 'none'); 63 if (typeof wk_ps_version != 'undefined' && wk_ps_version >= '8.1.0') { 64 // Issue due to this PR : 29016 65 prestashop.on("handleError", function (event) { 66 if (event.eventType == 'addProductToCart') { 67 var response = event.resp; 68 if (response.hasError) { 69 totalErrors = response.errors; 70 var ajaxError = ""; 71 $.each(totalErrors, (index, item) => { 72 ajaxError += item; 73 ajaxError += "<br>"; 74 }); 75 $(".wk-product-add-to-cart .ajax-error").html('<div class="alert alert-danger">' + ajaxError + '</div>').show(); 76 $(".wk_ajax-error .alert").html(ajaxError); 77 $(".wk_ajax-error").show(); 78 } 79 } 80 }) 81 } 82 // save option data on add to cart event 83 prestashop.on('updateCart',function (event) { 84 //update cart native code added for update cart quantity in the cart 85 // var refreshURL = $('.blockcart').data('refresh-url'); 86 // var requestData = {}; 87 // if (event && event.reason && typeof event.resp !== 'undefined' && !event.resp.hasError) { 88 // requestData = { 89 // id_customization: event.reason.idCustomization, 90 // id_product_attribute: event.reason.idProductAttribute, 91 // id_product: event.reason.idProduct, 92 // action: event.reason.linkAction 93 // }; 94 // } 95 // if (event && event.resp && event.resp.hasError) { 96 // prestashop.emit('showErrorNextToAddtoCartButton', { errorMessage: event.resp.errors.join('<br/>')}); 97 // } 98 // $.post(refreshURL, requestData).then(function (resp) { 99 // var html = $('<div />').append($.parseHTML(resp.preview)); 100 // $('.blockcart').replaceWith($(resp.preview).find('.blockcart')); 101 // if (resp.modal) { 102 // showModal(resp.modal); 103 // } 104 // }).fail(function (resp) { 105 // prestashop.emit('handleError', { eventType: 'updateShoppingCart', resp: resp }); 106 // }); 107 108 //code end 109 110 111 112 var form = document.getElementById("add-to-cart-or-refresh"); 113 if (typeof form != "undefined" && form) { 114 var formData = new FormData(form); 115 if (typeof event.resp != "undefined" && event.reason && typeof event.reason.linkAction != "undefined" && event.reason.linkAction == "add-to-cart") { 116 var response = event.resp; 117 formData.append("action", "addProductOption"); 118 formData.append("id_product", response.id_product); 119 formData.append("id_product_attribute", response.id_product_attribute); 120 formData.append("id_customization", response.id_customization); 121 if (response.success) { 122 $.ajax({ 123 url: wk_product_option_ajax, 124 type: "POST", 125 data: formData, 126 contentType: false, 127 processData: false, 128 dataType: "json", 129 success: function (data) { 130 $(".product-add-to-cart .ajax-error").hide(); 131 $(".wk-product-add-to-cart .ajax-error").hide(); 132 form.reset(); 133 $(".wk_select_dropdown_multiple").select2('destroy'); 134 $(".wk_select_dropdown_multiple").select2({ placeholder: wk_multi_select_placeholder }); 135 $('.wk_option_file_contain').val('0'); 136 $('.js-file-name').html(wk_no_file); 137 $('.wk_quickview').modal('hide'); 138 }, 139 }); 140 } else if (response.hasError) { 141 totalErrors = response.errors; 142 var ajaxError = ""; 143 $.each(totalErrors, (index, item) => { 144 ajaxError += item; 145 ajaxError += "<br>"; 146 }); 147 $(".product-add-to-cart .ajax-error").html(ajaxError).show(); 148 $(".wk_ajax-error .alert").html(ajaxError); 149 $(".wk_ajax-error").show(); 150 } 151 } 152 } 153 // history.go() 154 }); 155 const currentURL = window.location.href; 156 const pageTitle = document.title; 157 prestashop.on("updateProduct", function (event) { 158 $(".wk_ajax-error .alert").html(''); 159 $(".wk_ajax-error").hide(''); 160 $(".product-add-to-cart .ajax-error").html(''); 161 $(".product-add-to-cart .ajax-error").hide(); 162 $(".wk-product-add-to-cart .ajax-error").hide(); 163 $('.wk_quickview').addClass('quickview'); 164 $('.quickview').removeClass('wk_quickview'); 165 if (event.eventType != 'updatedProductQuantity') { 166 setTimeout(function () {
167 $("#wk_id_product_attribute_form").val($("#wk_id_product_attribute").val()); 168 $.ajax({ 169 url: wk_product_option_ajax, 170 type: "post", 171 async: true, 172 dataType: "json", 173 data: { 174 ajax: true, 175 action: "changeVariantTemplate", 176 token: secure_key, 177 id_product: $('#product_page_product_id').val(), 178 id_product_attribute: $("#wk_id_product_attribute").val(), 179 }, 180 success: function (response) { 181 $(".wk_custom_variant").html(response.data); 182 afterPageLoadScript(); 183 }, 184 }); 185 }, 1000) 186 } 187 }); 188 189 prestashop.on("updatedProduct", function (event) { 190 if ($('.modal.wk_quickview.in').length > 0) { 191 window.history.pushState( 192 '', 193 pageTitle, 194 currentURL, 195 ); 196 } 197 updatePsPrice(); 198 $('.quickview').addClass('wk_quickview'); 199 $('.wk_quickview').removeClass('quickview'); 200 }); 201 prestashop.on("clickQuickView", function (event) { 202 setTimeout(function () { 203 $('.quickview').addClass('wk_quickview'); 204 $('.wk_quickview').removeClass('quickview'); 205 updatePsPrice(); 206 afterPageLoadScript(true); 207 }, 1000) 208 }); 209 $(document).on("change", '.js-file-input', function () { 210 var imageId = $(this).attr("id"); 211 var $addToCartBtn = $('[data-button-action="add-to-cart"]'); 212 if (typeof this.files[0] != "undefined") { 213 if (this.files[0].size > maxSizeAllowed * 1000000) { 214 $("#" + imageId + "_contain").val(2); 215 setTimeout(() => { 216 $addToCartBtn.prop('disabled', false); 217 }, 200); 218 } else { 219 if (this.files[0].size > 0) { 220 var form = document.getElementById("add-to-cart-or-refresh"); 221 var formData = new FormData(form); 222 formData.append("action", "validateImage"); 223 var fieldName = imageId; 224 var spanFileNameID = '#' + fieldName + '_name'; 225 226 $(spanFileNameID).html(this.files[0].name); 227 228 formData.append("field_name", fieldName); 229 $addToCartBtn.prop('disabled', true); 230 $.ajax({ 231 url: wk_product_option_ajax, 232 type: "POST", 233 data: formData, 234 contentType: false, 235 processData: false, 236 dataType: "json", 237 success: function (data) { 238 if (data.status == 'fail') { 239 $("#" + imageId + "_contain").val(3); 240 } else { 241 $("#" + imageId + "_contain").val(1); 242 } 243 $addToCartBtn.prop('disabled', false); 244 }, 245 error: function () { 246 $addToCartBtn.prop('disabled', false); 247 }, 248 complete: function () { 249 setTimeout(() => { 250 $addToCartBtn.prop('disabled', false); 251 }, 200); 252 } 253 }); 254 } 255 } 256 } 257 }); 258 259 $(document).on("click", ".wk_image_upload", function (e) { 260 e.preventDefault(); 261 var idImage = $(this).data("id_image"); 262 $("#" + idImage).trigger("click"); 263 }); 264 $(document).on("click", ".wk_option_checkbox_parent", function (e) { 265 updatePsPrice(); 266 }); 267 $(document).on('change', '.wk_select_dropdown_single', function (e) { 268 var idField = $(this).data('id_field'); 269 var idValue = $(this).find(':selected').data('id-option-val'); 270 $('#wk_option_dropdown_value_id_' + idField).val(idValue); 271 if ($(this).closest('.wk-product-variants-item').find('.wk_option_checkbox_parent').prop('checked') == true) { 272 updatePsPrice(); 273 } 274 }) 275 $(document).on('click', '.wk_checkbox_selected', function (e) { 276 var idField = $(this).data('id_field'); 277 var selectedValue = $('#wk_option_checkbox_value_id_' + idField).val(); 278 var itemValue = $(this).data('id-check-val'); 279 if ($(this).prop('checked') == true) { 280 selectedValue += "," + itemValue; 281 } else { 282 selectedValue = selectedValue.split(','); 283 selectedValue = selectedValue.filter(function (item) { 284 return item != itemValue 285 }) 286 selectedValue = selectedValue.toString(); 287 } 288 $('#wk_option_checkbox_value_id_' + idField).val(selectedValue); 289 if ($(this).closest('.wk-product-variants-item').find('.wk_option_checkbox_parent').prop('checked') == true) { 290 updatePsPrice() 291 } 292 }) 293 $('.wk_select_dropdown_multiple').on('change', function () { 294 var idField = $(this).data('id_field'); 295 var selectedValue = $(this).val(); 296 $('#wk_option_dropdown_value_id_multi_' + idField).val(selectedValue.toString()); 297 if ($(this).closest('.wk-product-variants-item').find('.wk_option_checkbox_parent').prop('checked') == true) { 298 updatePsPrice(); // vary price based on selected checkbox value 299 } 300 }); 301 $(document).on('click', '.wk_radio_selected', function (e) { 302 var idField = $(this).data('id_field'); 303 var idValue = $(this).data('id-radio-val'); 304 $('#wk_option_radio_value_id_' + idField).val(idValue); 305 if ($(this).closest('.wk-product-variants-item').find('.wk_option_checkbox_parent').prop('checked') == true) { 306 updatePsPrice(); 307 } 308 }) 309 $(document).on('click', '.wk_custom_addon', function () { 310 $(this).closest('.input-group').find('input').focus(); 311 }) 312}); 313 314function afterPageLoadScript(is_quick_view = false) { 315 if ($('.wk_select_dropdown_multiple').length > 0) { 316 var idField = $('.wk_select_dropdown_multiple').data('id_field'); 317 var selectedValue = $('.wk_select_dropdown_multiple').val(); 318 $('#wk_option_dropdown_value_id_multi_' + idField).val(selectedValue.toString()); 319 } 320 if ($('.wk_select_dropdown_single').length > 0) { 321 var optionIdField = $('.wk_select_dropdown_single').data('id_field'); 322 var idValue = $('.wk_select_dropdown_single').find(':selected').data('id-option-val'); 323 $('#wk_option_dropdown_value_id_' + optionIdField).val(idValue); 324 } 325 $('.wk_product_opt_container [data-toggle="tooltip"]').tooltip(); 326 if (typeof wk_controller != 'undefined' && wk_controller == 'product') { 327 updatePsPrice(); 328 } 329 $(".wk_select_dropdown_multiple").select2({ placeholder: wk_multi_select_placeholder });
330 $("#wk_id_product_attribute_form").val($("#wk_id_product_attribute").val()); 331 $(".wk_option_info_icon").mouseover(function () { 332 var id = $(this).attr("data-id_info"); 333 $("#wk-hovercard" + id + "") 334 .removeClass("wk-hovercard") 335 .addClass("wk-hovercard_hover"); 336 }); 337 $(".wk_option_info_icon").mouseout(function () { 338 var id = $(this).attr("data-id_info"); 339 $("#wk-hovercard" + id + "") 340 .removeClass("wk-hovercard_hover") 341 .addClass("wk-hovercard"); 342 }); 343 $(".wk_color_input").change(function () { 344 var idParent = $(this).data("id_parent"); 345 $("#" + idParent).css("color", $(this).val()); 346 }); 347 $('.wk_product_option_date').datepicker({ 348 dateFormat: "yy-mm-dd", 349 closeText: wkcloseText, 350 prevText: wkprevText, 351 nextText: wknextText, 352 startDate: '1970-01-01', 353 currentText: wkcurrentText, 354 monthNames: wkMonthNameFull, 355 monthNamesShort: wkMonthNameShort, 356 dayNamesMin: wkDaysOfWeek, 357 }).attr('readonly', 'readonly'); 358 $('.wk_product_option_time').timepicker({ 359 timeText: wktimeText, 360 hourText: wkhourText, 361 minuteText: wkminuteText, 362 showSecond: true, 363 secondText: wksecondText, 364 timeFormat: 'hh:mm:ss', 365 currentText: wkcurrentTimeText, 366 closeText: wkcloseText, 367 timeOnlyTitle: wktimeOnlyTitle, 368 }).attr('readonly', 'readonly'); 369 $('.wk_product_option_datetime').datetimepicker({ 370 dateFormat: "yy-mm-dd", 371 timeFormat: 'hh:mm:ss', 372 timeText: wktimeText, 373 hourText: wkhourText, 374 closeText: wkcloseText, 375 prevText: wkprevText, 376 nextText: wknextText, 377 currentText: wkcurrentText, 378 monthNames: wkMonthNameFull, 379 monthNamesShort: wkMonthNameShort, 380 dayNamesMin: wkDaysOfWeek, 381 showSecond: true, 382 secondText: wksecondText, 383 }).attr('readonly', 'readonly'); 384 if (is_quick_view) { 385 setTimeout(function () { 386 $('#ui-datepicker-div').css('z-index', '10000 !important'); 387 $('#ui-datepicker-div').addClass('wk_custom_index') 388 }, 400) 389 } 390 if (typeof wk_is_color_picker_allowed != 'undefined' && wk_is_color_picker_allowed == 1) { 391 $('.wk_color_input').minicolors({ 392 // animation speed 393 animationSpeed: 50, 394 395 // easing function 396 animationEasing: 'swing', 397 change: function () { 398 $('#' + $(this).data('id_parent')).css({ 'color': $(this).val() }) 399 }, 400 // defers the change event from firing while the user makes a selection 401 changeDelay: 0, 402 403 // hue, brightness, saturation, or wheel 404 control: 'hue', 405 406 // default color 407 defaultValue: '', 408 409 // hex or rgb 410 format: 'hex', 411 412 // show/hide speed 413 showSpeed: 100, 414 hideSpeed: 100, 415 416 // is inline mode? 417 inline: false, 418 419 // a comma-separated list of keywords that the control should accept (e.g. inherit, transparent, initial). 420 keywords: '', 421 422 // uppercase or lowercase 423 letterCase: 'lowercase', 424 425 // enables opacity slider 426 opacity: false, 427 428 // custom position 429 position: 'bottom right', 430 431 // additional theme class 432 theme: 'default', 433 swatches: [] 434 435 }); 436 } 437} 438 439function updatePsPrice() { 440 var options = []; 441 var idValues = []; 442 $(".wk_option_checkbox_parent:checked").each(function () { 443 var id_option = $(this).val(); 444 var dropValueMulti = $('#wk_option_dropdown_value_id_multi_' + id_option).val(); 445 if (dropValueMulti) { 446 dropValueMulti = dropValueMulti.split(','); 447 $.each(dropValueMulti, function (index, dval) { 448 idValues.push(dval); 449 }) 450 } 451 var dropcheckBox = $('#wk_option_checkbox_value_id_' + id_option).val(); 452 if (dropcheckBox) { 453 dropcheckBox = dropcheckBox.split(','); 454 $.each(dropcheckBox, function (index, cval) { 455 idValues.push(cval); 456 }) 457 } 458 var dropValue = $('#wk_option_dropdown_value_id_' + id_option).val(); 459 if (dropValue) { 460 idValues.push(dropValue); 461 } 462 var radioValue = $('#wk_option_radio_value_id_' + id_option).val(); 463 if (radioValue) { 464 idValues.push(radioValue); 465 } 466 options.push(id_option); 467 }); 468 var idProduct = $("#product_page_product_id").val(); 469 var idProductAttribute = $("#wk_id_product_attribute").val(); 470 var qty_wanted = $('#quantity_wanted').val(); 471 $.ajax({ 472 url: wk_product_option_ajax, 473 type: "post", 474 async: true, 475 dataType: "json", 476 data: { 477 ajax: true, 478 action: "changeCatalogPrice", 479 token: secure_key, 480 selectedOption: options, 481 id_product: idProduct, 482 id_product_attribute: idProductAttribute, 483 id_values: idValues, 484 quantity_wanted: qty_wanted 485 }, 486 success: function (response) { 487 if (typeof response.price_tpl != 'undefined' && response.price_tpl != '') { 488 $(".wk_price_option").html(response.price_tpl); 489 } 490 }, 491 }); 492} 493 494if (typeof wk_product_option_parent_checkbox_hide != 'undefined' && wk_product_option_parent_checkbox_hide == 1) { 495 //for text 496 $(document).on('blur', '.wk_custom_text', function () { 497 // Extract the ID number from the input's ID 498 var inputId = $(this).attr('id'); 499 500 var optionId = inputId.replace('wk_option_text_area_', ''); 501 502 // Construct the correct checkbox selector 503 var checkboxSelector = '#wk_option_' + optionId; 504 505 // Check the checkbox if the input has a value 506 if ($(this).val().trim() != '') { 507 $(checkboxSelector).prop('checked', true); 508 } else { 509 $(checkboxSelector).prop('checked', false); 510 } 511 512 updatePsPrice(); 513 }); 514 //for textare 515 $(document).on('blur', '.wk_option_text_area', function () { 516 // Extract the ID number from the input's ID 517 var inputId = $(this).attr('id'); 518 519 var optionId = inputId.replace('wk_option_text_area_new_', ''); 520 521 // Construct the correct checkbox selector 522 var checkboxSelector = '#wk_option_' + optionId; 523 524 // Check the checkbox if the input has a value 525 if ($(this).val().trim() != '') { 526 $(checkboxSelector).prop('checked', true); 527 } else { 528 $(checkboxSelector).prop('checked', false); 529 } 530 531 updatePsPrice(); 532 }); 533 //for dropdown 534 $(document).on('change', '.wk_select_dropdown_multiple, .wk_select_dropdown_single', function () { 535 // Extract the ID number from the input's ID 536 var inputId = $(this).attr('id'); 537 var optionId = inputId.replace('wk_option_dropdown_', ''); 538 539 // Construct the correct checkbox selector 540 var checkboxSelector = '#wk_option_' + optionId; 541 542 // Check the checkbox if the input has a value 543 if ($(this).val() != '') { 544 $(checkboxSelector).prop('checked', true); 545 } else { 546 $(checkboxSelector).prop('checked', false); 547 } 548 549 // updatePsPrice(); 550 }); 551 552 //for checkbox 553 $(document).on('click', '.wk_checkbox_selected', function () { 554 // Extract the ID number from the input's ID 555 var inputId = $(this).attr('id'); 556 557 // Extract the option ID (first part of the input's ID) 558 var optionId = inputId.split('_')[2]; 559 560 // Construct the correct checkbox selector 561 var checkboxSelector = '#wk_option_' + optionId; 562 563 // Check the checkbox if the input has a value 564 if ($(this).val() != '') { 565 $(checkboxSelector).prop('checked', true); 566 } else { 567 $(checkboxSelector).prop('checked', false); 568 } 569 570 // updatePsPrice(); 571 }); 572 573 //for radio button 574 $(document).on('click', '.wk_radio_selected', function () { 575 // Extract the ID number from the input's ID 576 var inputId = $(this).attr('id'); 577 var optionId = inputId.split('_')[3]; 578 579 // Construct the correct checkbox selector 580 var checkboxSelector = '#wk_option_' + optionId; 581 582 // Check the checkbox if the input has a value 583 if ($(this).val() != '') { 584 $(checkboxSelector).prop('checked', true); 585 } else { 586 $(checkboxSelector).prop('checked', false); 587 } 588 589 // updatePsPrice(); 590 }); 591 592 //for imagefile 593 $(document).on('change', '.wk_image_upload_input', function () { 594 595 // Extract the ID number from the input's data-id_image attribute 596 var inputId = $(this).attr('id'); 597 598 // Extract the option ID (remove 'wk_option_file' from the inputId) 599 var optionId = inputId.replace('wk_option_file', ''); 600 601 // Construct the correct checkbox selector 602 var checkboxSelector = '#wk_option_' + optionId; 603 604 // Check the checkbox if the input has a value 605 if ($(this).val() != '') { 606 $(checkboxSelector).prop('checked', true); 607 } else { 608 $(checkboxSelector).prop('checked', false); 609 } 610 611 updatePsPrice(); 612 }); 613 614 //for date 615 $(document).on('change', '.wk_product_option_date', function () { 616 617 // Extract the ID number from the input's data-id_image attribute 618 var inputId = $(this).attr('id'); 619 620 // Extract the option ID (remove 'wk_option_file' from the inputId) 621 var optionId = inputId.replace('wk_option_date_', ''); 622 623 // Construct the correct checkbox selector 624 var checkboxSelector = '#wk_option_' + optionId; 625 626 // Check the checkbox if the input has a value 627 if ($(this).val() != '') { 628 $(checkboxSelector).prop('checked', true); 629 } else { 630 $(checkboxSelector).prop('checked', false); 631 } 632 633 updatePsPrice(); 634 }); 635 636 //for time 637 $(document).on('change', '.wk_product_option_time', function () { 638 639 // Extract the ID number from the input's data-id_image attribute 640 var inputId = $(this).attr('id'); 641 642 // Extract the option ID (remove 'wk_option_file' from the inputId) 643 var optionId = inputId.replace('wk_option_time_', ''); 644 645 // Construct the correct checkbox selector 646 var checkboxSelector = '#wk_option_' + optionId; 647 648 // Check the checkbox if the input has a value 649 if ($(this).val() != '') { 650 $(checkboxSelector).prop('checked', true); 651 } else { 652 $(checkboxSelector).prop('checked', false); 653 } 654 655 updatePsPrice(); 656 }); 657 658 //for datetime 659 $(document).on('change', '.wk_product_option_datetime', function () { 660 661 // Extract the ID number from the input's data-id_image attribute 662 var inputId = $(this).attr('id'); 663 664 // Extract the option ID (remove 'wk_option_file' from the inputId) 665 var optionId = inputId.replace('wk_option_datetime_', ''); 666 667 // Construct the correct checkbox selector 668 var checkboxSelector = '#wk_option_' + optionId; 669 670 // Check the checkbox if the input has a value 671 if ($(this).val() != '') { 672 $(checkboxSelector).prop('checked', true); 673 } else { 674 $(checkboxSelector).prop('checked', false); 675 } 676 677 updatePsPrice(); 678 }); 679}
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.