
    <script>
        window.addEventListener('load', function() {
            if (typeof booknetic !== "undefined")
                booknetic.select2Ajax = function(select, url, parameters, postURL) {
                    var parseUrl = url.split('.'),
                        module, action;

                    if (parseUrl.length === 1) {
                        module = currentModule;
                        action = parseUrl[0];
                    } else {
                        module = parseUrl[0];
                        action = parseUrl[1];
                    }

                    var params = {};
                    params['module'] = module;
                    params['action'] = action;

                    select.select2({
                        theme: 'bootstrap',
                        placeholder: booknetic.__('select'),
                        allowClear: true,
                        language: {
                            searching: function() {
                                return booknetic.__('searching');
                            }
                        },
                        ajax: {
                            url: postURL ? postURL : ajaxurl,
                            dataType: 'json',
                            type: "POST",
                            data: function(q) {
                                params = booknetic.doFilter('select2_ajax_' + module + '.' + action, params);
                                var sendParams = params;
                                sendParams['q'] = q['term'];

                                if (typeof parameters == 'function') {
                                    var additionalParameters = parameters($(this));

                                    for (var key in additionalParameters) {
                                        sendParams[key] = additionalParameters[key];
                                    }
                                } else if (typeof parameters == 'object') {
                                    for (var key in parameters) {
                                        sendParams[key] = parameters[key];
                                    }
                                }

                                return sendParams;
                            },
                            processResults: function(result) {

                                if (booknetic.ajaxResultCheck(result)) {
                                    booknetic.doAction('bkntc_select2_ajax_after_' + action + '_success', module, result);
                                    try {
                                        result.results = result.results.map(row => {

                                            return ({
                                                ...row,
                                                text: row.text.indexOf("&amp;") > -1 ? row.text.replace("&amp;", "&") : row.text,
                                            });
                                        });
                                    } catch (e) {
                                        console.error('Error processing Select2 results:', e);
                                    }
                                    return result;
                                }
                            }
                        }
                    });
                };
        })
    </script>
    
<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" href="https://myresa.ma/wp-sitemap-index.xsl" ?>
<sitemapindex xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"><sitemap><loc>https://myresa.ma/wp-sitemap-posts-page-1.xml</loc></sitemap><sitemap><loc>https://myresa.ma/wp-sitemap-posts-liquid-header-1.xml</loc></sitemap><sitemap><loc>https://myresa.ma/wp-sitemap-posts-liquid-footer-1.xml</loc></sitemap><sitemap><loc>https://myresa.ma/wp-sitemap-posts-metform-form-1.xml</loc></sitemap><sitemap><loc>https://myresa.ma/wp-sitemap-users-1.xml</loc></sitemap></sitemapindex>
