PageSourceSearch

https://opeco.com.br/pages/Opeco%20%E2%80%93%20sobre_files/plugins.js.download

js opeco.com.br collected 2026-10-06 18:05:05 UTC 11,193 bytes, 306 lines download raw bytes

1var _____WB$wombat$assign$function_____ = function(name) {return (self._wb_wombat && self._wb_wombat.local_init && self._wb_wombat.local_init(name)) || self[name]; };
2if (!self.__WB_pmw) { self.__WB_pmw = function(obj) { this.__WB_source = obj; return this; } }
3{
4  let window = _____WB$wombat$assign$function_____("window");
5  let self = _____WB$wombat$assign$function_____("self");
6  let document = _____WB$wombat$assign$function_____("document");
7  let location = _____WB$wombat$assign$function_____("location");
8  let top = _____WB$wombat$assign$function_____("top");
9  let parent = _____WB$wombat$assign$function_____("parent");
10  let frames = _____WB$wombat$assign$function_____("frames");
11  let opener = _____WB$wombat$assign$function_____("opener");
12
13// Avoid `console` errors in browsers that lack a console.
14(function() {
15    var method;
16    var noop = function () {};
17    var methods = [
18        'assert', 'clear', 'count', 'debug', 'dir', 'dirxml', 'error',
19        'exception', 'group', 'groupCollapsed', 'groupEnd', 'info', 'log',
20        'markTimeline', 'profile', 'profileEnd', 'table', 'time', 'timeEnd',
21        'timeStamp', 'trace', 'warn'
22    ];
23    var length = methods.length;
24    var console = (window.console = window.console || {});
25
26    while (length--) {
27        method = methods[length];
28
29        // Only stub undefined methods.
30        if (!console[method]) {
31            console[method] = noop;
32        }
33    }
34
35    //Menu Scroll
36    $('a[href*=#]').click(function() {
37        if (location.pathname.replace(/^\//,'') == this.pathname.replace(/^\//,'') && location.hostname == this.hostname) {
38            var $target = $(this.hash);
39            $target = $target.length && $target || $('[name=' + this.hash.slice(1) +']');
40            if ($target.length) {
41                var targetOffset = $target.offset().top;
42                $('html,body').animate({scrollTop: targetOffset-92}, 1000);
43                return false;
44            }
45        }
46    });
47    $("#user-send").on("click",function(){validar()});
48    //Onload Global
49    //Verify if it is IE8 or below
50    if(document.addEventListener){
51        document.addEventListener('DOMContentLoaded', function(callback_1, callback_2){
52            var mainHeader = 'mainHeader',
53                mainContent = 'mainContent',
54                mainFooter = 'mainFooter';
55            document.getElementsByClassName(mainHeader)[0].className = mainHeader;
56            callback_1 = document.getElementsByClassName(mainContent)[0].className = mainContent;
57            callback_2 = document.getElementsByClassName(mainFooter)[0].className = mainFooter;
58        });
59    }else{
60        document.attachEvent('DOMContentLoaded', function(callback_1, callback_2){
61            var mainHeader = 'mainHeader',
62                mainContent = 'mainContent',
63                mainFooter = 'mainFooter';
64            document.getElementsByClassName(mainHeader)[0].className = mainHeader;
65            callback_1 = document.getElementsByClassName(mainContent)[0].className = mainContent;
66            callback_2 = document.getElementsByClassName(mainFooter)[0].className = mainFooter;
67        });
68    }
69}());
70
71function validar(){
72    var dto = {};
73    if(document.getElementById('user-name').value == ""){
74        alert("Preencha o nome");
75        return;
76    }
77    if(document.getElementById('user-mail').value == ""){
78        alert("Preencha o e-mail");
79        return;
80    }
81    if(document.getElementById('user-mail').value != ""){
82        if(!isMail(document.getElementById('user-mail').value)){
83            alert("Preencher e-mail corretamente");
84            return;
85        }
86    }
87    if(document.getElementById('user-combo').options[document.getElementById('user-combo').selectedIndex].value == ""){
88        alert("Escolhar o motivo");
89        return;
90    }
91     if(document.getElementById('user-msg').value == ""){
92        alert("Preencha a mensagem");
93        return;
94    }
95    dto = {
96        name  : document.getElementById('user-name').value,
97        mail  : document.getElementById('user-mail').value,
98        combo : document.getElementById('user-combo').options[document.getElementById('user-combo').selectedIndex].value,
99        msg   : document.getElementById('user-msg').value, 
100        check : document.getElementById('user-subsMail').checked
101    }
102    document.getElementById('modal-contact').style.display = "block";
103    $.ajax({
104              method: "POST",
105              url   : "send.php",
106              data  : { data : dto}
107           })
108    .done(function( msg ) {
109         document.getElementById('modal-contact').style.display = "none";
110        alert("Sua mensagem foi enviado com sucesso!");
111        document.getElementById('user-name').value                  = "";
112        document.getElementById('user-mail').value                  = "";
113        document.getElementById('user-msg').value                   =  "";
114        document.getElementById('user-subsMail').checked            = false;
115        document.getElementById('user-combo').options[0].selected   = true;
116        $('.contact-form').fadeOut('fast', function(){
117            $('.contact-box-choice').fadeIn();
118        });
119    });
120}
121function isMail(email){
122    var exclude=/[^@\-\.\w]|^[_@\.\-]|[\._\-]{2}|[@\.]{2}|(@)[^@]*\1/;
123    var check=/@[\w\-]+\./;
124    var checkend=/\.[a-zA-Z]{2,3}$/;
125    if(((email.search(exclude) != -1)||(email.search(check)) == -1)||(email.search(checkend) == -1)){return false;}
126    else {return true;}
127}
128jQuery(function(){
129    //Corrigi LogoBox na Home
130    var fixMe = jQuery('.wrapLogoBox');
131    for(var i = 0; i < fixMe.length; i+=5) {
132        fixMe.slice(i, i+5).wrapAll("<div class='home-logos'></div>");
133    }
134});
135
136function btHpLogo($boxName, $logoName){
137    var $btDefault = '.btHpProd';
138    var $boxDefault = '.home-logos-info';
139    var $bigBoxDefault = '.home-suppliers-container';
140    var $hpBox = document.getElementById($boxName);
141    var boxLogos = '.boxLogos';
142
143    if($hpBox.style.display == 'none'){
144        jQuery(function(){
145            $(boxLogos).animate({
146                height: '515px'
147            }, 400, function(){
148                $($boxDefault).fadeOut();
149                $($hpBox).fadeIn();
150            });
151            //$(boxLogos).animate({height: '515px'}, 400);
152            $($btDefault).removeClass('select');
153            $('.'+$logoName).addClass('select');
154            $('.boxLogos').cycle('pause');
155        });
156    }else{
157        $($boxDefault).fadeOut('fast');
158        $(boxLogos).animate({
159            height:'116px'
160        });
161        //$(boxLogos).animate({height: '0'}, 400);
162        $($btDefault).removeClass('select');
163        $('.boxLogos').cycle('resume');
164    }
165}
166
167function btPopUp($boxName, $logoName){
168    var $btDefault = '.defaultBt';
169    var $boxDefault = '.popupInfo';
170    var $hpBox = document.getElementById($boxName);
171
172    if($hpBox.style.display == 'none'){
173        jQuery(function(){
174            $($boxDefault).fadeOut();
175            $($hpBox).fadeIn();
176            $('html,body').animate({scrollTop: '150px'}, 1000);
177            $($btDefault).removeClass('select');
178            $('.'+$logoName).addClass('select');
179        });
180    }else{
181        $($boxDefault).fadeOut('fast');
182        $($btDefault).removeClass('select');
183    }
184}
185
186function closePopUp(){
187    var $btDefault = '.defaultBt';
188    var $boxDefault = '.popupInfo';
189    jQuery(function(){
190        $($boxDefault).fadeOut('fast');
191        $($btDefault).removeClass('select');
192    });
193}
194
195//Function that controls the search on head of the website
196var realInput = document.getElementById('realInput');
197function addEvent(obj, string){
198    var object = document.getElementById(obj);
199    var nameForm = document.getElementById('searchForm');
200    //check if it's IE8 or below
201    if(object.addEventListener){
202        object.addEventListener('click', function(){
203            realInput.name = string;
204            jQuery(function(){
205                $('.search > div').removeClass('selected');
206                $('#' + obj).addClass('selected');
207            });
208              if(string == 'code'){
209                nameForm.action = '../pages/produto.html';
210            }else if(string == 'brand'){
211                nameForm.action = '../pages/produtos.html';
212            }
213        }, false);
214    }else{
215        object.onclick = function(){
216            realInput.name = string;
217            jQuery(function(){
218                $('.search > div').removeClass('selected');
219                $('#' + obj).addClass('selected');
220            });
221              if(string == 'code'){
222                nameForm.action = '../pages/produto.html';
223            }else if(string == 'brand'){
224                nameForm.action = '../pages/produtos.html';
225            }
226        }
227    }
228}
229addEvent('prodSearch', 'code');
230addEvent('brandSearch', 'brand');
231
232function validateForm(){
233    var input = document.getElementById('realInput');
234    if(input.name == 'realInput'){
235        input.placeholder = 'escolha antes';
236        return false;
237    }else if(input.name == 'brand'){
238        return input.value = input.value.toUpperCase();
239    }
240}
241
242// Control contact form
243(function(){
244    jQuery(function(){
245        $('.contact-tag-pFisico').click(function(){
246            $('.contact-box-choice').fadeOut('fast', function(){
247                $('.contact-form').fadeIn();
248                $('.form-headInfo-title').text('Pessoa Física');
249                $('.form-context-webName').text('loja online e-Store');
250            });
251        });
252        $('.contact-tag-pJuridico').click(function(){
253            $('.contact-box-choice').fadeOut('fast', function(){
254                $('.contact-form').fadeIn();
255                $('.form-headInfo-title').text('Pessoa Jurídica');
256                $('.form-context-webName').text('Opeco');
257            });
258        });
259        $('.form-heardInfo-back').click(function(){
260            $('.contact-form').fadeOut('fast', function(){
261                $('.contact-box-choice').fadeIn();
262            });
263        });
264    });
265})();
266
267//AJAX
268function loadDoc() {
269    var str = document.getElementById('txtCont').value;
270    if (str.length == 0) {
271        document.getElementById("boxOla").innerHTML = "";
272        return;
273    }
274    var xhttp = new XMLHttpRequest();
275    xhttp.onreadystatechange=function() {
276        if (xhttp.readyState == 4 && xhttp.status == 200) {
277            document.getElementById("boxOla").innerHTML = xhttp.responseText;
278        }
279    };
280    xhttp.open("GET", "https://web.archive.org/web/20240709004634/http://www.opeco.com.br/wp-content/themes/opeco/__ajax-produtos.php?t=" + str, true);
281    xhttp.send();
282}
283
284
285}
286/*
287     FILE ARCHIVED ON 00:46:34 Jul 09, 2024 AND RETRIEVED FROM THE
288     INTERNET ARCHIVE ON 13:15:16 Sep 22, 2025.
289     JAVASCRIPT APPENDED BY WAYBACK MACHINE, COPYRIGHT INTERNET ARCHIVE.
290
291     ALL OTHER CONTENT MAY ALSO BE PROTECTED BY COPYRIGHT (17 U.S.C.
292     SECTION 108(a)(3)).
293*/
294/*
295playback timings (ms):
296  captures_list: 0.447
297  exclusion.robots: 0.016
298  exclusion.robots.policy: 0.007
299  esindex: 0.009
300  cdx.remote: 75.819
301  LoadShardBlock: 528.028 (3)
302  PetaboxLoader3.datanode: 612.738 (5)
303  PetaboxLoader3.resolve: 486.04 (2)
304  load_resource: 745.221
305  loaddict: 207.983
306*/

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.