PageSourceSearch

https://onezoom.vn/js/search.js?v=2mSroQazmAO-qiwDR1Q4hifrAdGwcSR1uBiT5Q1uKZc

js onezoom.vn collected 2026-10-08 19:42:00 UTC 3,132 bytes, 82 lines download raw bytes

1function convertToUnsign(str) {
2    str = str.replace(/à|á|ạ|ả|ã|â|ầ|ấ|ậ|ẩ|ẫ|ă|ằ|ắ|ặ|ẳ|ẵ/g, "a");
3    str = str.replace(/è|é|ẹ|ẻ|ẽ|ê|ề|ế|ệ|ể|ễ/g, "e");
4    str = str.replace(/ì|í|ị|ỉ|ĩ/g, "i");
5    str = str.replace(/ò|ó|ọ|ỏ|õ|ô|ồ|ố|ộ|ổ|ỗ|ơ|ờ|ớ|ợ|ở|ỡ/g, "o");
6    str = str.replace(/ù|ú|ụ|ủ|ũ|ư|ừ|ứ|ự|ử|ữ/g, "u");
7    str = str.replace(/ỳ|ý|ỵ|ỷ|ỹ/g, "y");
8    str = str.replace(/đ/g, "d");
9    str = str.replace(/À|Á|Ạ|Ả|Ã|Â|Ầ|Ấ|Ậ|Ẩ|Ẫ|Ă|Ằ|Ắ|Ặ|Ẳ|Ẵ/g, "A");
10    str = str.replace(/È|É|Ẹ|Ẻ|Ẽ|Ê|Ề|Ế|Ệ|Ể|Ễ/g, "E");
11    str = str.replace(/Ì|Í|Ị|Ỉ|Ĩ/g, "I");
12    str = str.replace(/Ò|Ó|Ọ|Ỏ|Õ|Ô|Ồ|Ố|Ộ|Ổ|Ỗ|Ơ|Ờ|Ớ|Ợ|Ở|Ỡ/g, "O");
13    str = str.replace(/Ù|Ú|Ụ|Ủ|Ũ|Ư|Ừ|Ứ|Ự|Ử|Ữ/g, "U");
14    str = str.replace(/Ỳ|Ý|Ỵ|Ỷ|Ỹ/g, "Y");
15    str = str.replace(/Đ/g, "D");
16    // Some system encode vietnamese combining accent as individual utf-8 characters
17    // Một vài bộ encode coi các dấu mũ, dấu chữ như một kí tự riêng biệt nên thêm hai dòng này
18    str = str.replace(/\u0300|\u0301|\u0303|\u0309|\u0323/g, ""); // ̀ ́ ̃ ̉ ̣  huyền, sắc, ngã, hỏi, nặng
19    str = str.replace(/\u02C6|\u0306|\u031B/g, ""); // ˆ ̆ ̛  Â, Ê, Ă, Ơ, Ư
20    // Remove extra spaces
21    // Bỏ các khoảng trắng liền nhau
22    str = str.replace(/ + /g, " ");
23    str = str.trim();
24    // Remove punctuations
25    // Bỏ dấu câu, kí tự đặc biệt
26    str = str.replace(/!|@|%|\^|\*|\(|\)|\+|\=|\<|\>|\?|\/|,|\.|\:|\;|\'|\"|\&|\#|\[|\]|~|\$|_|`|-|{|}|\||\\/g, " ");
27    return str;
28}
29function getUrl() {
30    // gen keyword
31    let keyword = $('#search-keyword').val()
32    if (!keyword) {
33        keyword = "viec-lam"
34    } else {
35        keyword = convertToUnsign(keyword).toLowerCase().replace(' ','-')
36    }
37    // category
38    let category = $('#select-business').find(':selected').data('slug')
39    if (!category) {
40        category = ''
41    } else {
42        category = '-' + category
43    }
44    // district
45    let district = $('#select-location').find(':selected').data('slug')
46    if (!district) {
47        district = ''
48    } else {
49        district = '-tai-' + district
50    }
51    //
52    let salary = $('#select-salary').find(':selected').data('slug')
53    if (!salary) {
54        salary = ''
55    } else {
56        salary = '-' + salary
57    }
58    //
59    const url = '/tim-kiem/'+keyword + category + district + salary
60    $('.form-search').attr('action', url)
61}
62$(document).ready(function () {
63    $('#search-keyword').keyup(function (evt) {
64        getUrl()
65    })
66    $('#select-business').change(function (evt) {
67        getUrl()
68    })
69    $('#select-location').change(function (evt) {
70        getUrl()
71    })
72    $('#select-salary').change(function (evt) {
73        getUrl()
74    })
75    $('.form-search').submit(function (evt) {        
76        getUrl()
77    })
78    $('.order-option').change(function () {
79        const val = $(this).val()
80        window.location.href = val
81    })
82})

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.