PageSourceSearch

https://www.yogasecrets.hu/!common_packages/jquery/own/shop_common…/function_coupon.js?mod_time=1789019842

js yogasecrets.hu collected 2026-10-08 18:15:50 UTC 1,018 bytes, 29 lines download raw bytes

1function cart_coupon_check(coupon_id) {
2    const coupon_code = (coupon_id == '#coupon_id' || coupon_id == '#coupon_id_mobile') ? $(coupon_id).val() : coupon_id;
3    $.ajax({
4        type: "GET",
5        async: true,
6        url: unas_shop_url+"/shop_cart.php",
7        data: {
8            action:"coupon_check",
9            coupon_id:coupon_code
10        },
11        success: function(result){
12            let targetUrl = unas_shop_url + "/shop_cart.php?scroll_to=coupon_id&if_visible=1&disp=autofocus";
13            if (result === "") {
14                targetUrl += "&overlay=order_coupon_ok";
15            } else if (result !== "empty") {
16                targetUrl += "&overlay=order_coupon_error_" + result;
17            }
18            location.href = targetUrl;
19        }
20    });
21}
22$(document).ready(function(){
23    $("#coupon_check").on("click",function(){
24        cart_coupon_check("#coupon_id");
25    });
26    $("#coupon_check_mobile").on("click",function(){
27        cart_coupon_check("#coupon_id_mobile");
28    });
29});

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.