Skip to content

Instantly share code, notes, and snippets.

@Mativve
Last active October 1, 2021 22:22
Show Gist options
  • Save Mativve/96bd64d3811665f4f262c7088cc1776c to your computer and use it in GitHub Desktop.
Save Mativve/96bd64d3811665f4f262c7088cc1776c to your computer and use it in GitHub Desktop.
WordPress - mapa kontaktów z podziałem na województwa

Skrypt ten dodajemy albo do swojego motywu w pliku functions.php lub przy pomocy wtyczki, która rozszerza taką możliwość np.: https://pl.wordpress.org/plugins/my-custom-functions/

Mapkę umieszczamy w treści strony/posta przy pomocy odpowiednich shortcode'ów w następujący sposób:

[map]
[card title="Oddział Główny" name="Adam Kowalski" phone="000-111-222" email="myemail@gmail.com" address="Warszawska XYZ abc" wojewodztwo="małopolskie"]
[card title="Oddział Główny" name="Andrzej Jędrzej" phone="111-111-222" email="jedrzej@gmail.com" address="Prosta 12/3" wojewodztwo="małopolskie"]
[card name="Michał Nowak" phone="111-222-000" email="emailmy@gmail.com" address="Krakowska XYZ abc" wojewodztwo="pomorskie"]
[/map]

Tworzymy otwierający i zamykający shortcode map ([map]...[/map]) Następnie w zależności od potrzeby tworzymy wizytówki działów/osób dodając shortcode samozamykający card ([card]). Gdy jakiś parametr nie zostranie wpisany w jego miejsce pojawi się pusty string "";

Jego dostępne parametry:

  • 'title': Tutaj tytuł np.: Nazwa oddziału albo stanowisko osoby
  • 'name': Tutaj możemy wpisać imię, imię i nazwisko, nazwę firmy etc
  • 'phone': Tutaj wpiszemy numer telefonu
  • 'email': Tutaj podajemy adres email (klikalny przez mailto:)
  • 'address': Tutaj adres
  • 'wojewodztwo': Tutaj wpisz slug województwa - poniżej znajdziesz listę dostepnych opcji (to ważne aby były identyczne, ponieważ na ich podstawie klikalna mapa będzie wyszukiwać odpowiednie wizytówki)

Dostepna lista województw: podkarpackie małopolskie malopolskie sląskie slaskie opolskie dolnośląskie dolnoslaskie świetokrzyskie swietokrzyskie lubelskie łódzkie lodzkie mazowieckie wielkopolskie lubuskie kujawsko-pomorskie podlaskie zachodnio-pomorskie warminsko-mazurskie pomorskie

<?php
remove_filter( 'the_content', 'wpautop' );
add_filter( 'the_content', 'wpautop' , 99 );
add_filter( 'the_content', 'shortcode_unautop', 100 );
// Create Shortcode card
// Shortcode: [card title="" name="" phone="" email="" address=""][/card]
function create_card_shortcode($atts, $content = null) {
$atts = shortcode_atts(
array(
'title' => '',
'name' => '',
'phone' => '',
'email' => '',
'address' => '',
'wojewodztwo' => '',
), $atts, 'card'
);
$title = $atts['title'];
$name = $atts['name'];
$phone = $atts['phone'];
$email = $atts['email'];
$address = $atts['address'];
$wojewodztwo = $atts['wojewodztwo'];
$html = '<div class="card-box" data-search="'. $title .' '. $name .' '. $phone .' '. $email .' '. $address .' '. $wojewodztwo .'">';
$html .= (!$title) ? '' : '<p class="card-box-title">'. __("Oddział") .': '. $title .'</p>';
$html .= (!$name) ? '' : '<p>'. __("Imię i nazwisko") .': '. $name .'</p>';
$html .= (!$phone) ? '' : '<p>'. __("Numer telefonu") .': '. $phone .'</p>';
$html .= (!$email) ? '' : '<p>'. __("Adres e-mail") .': <a href="mailto:'. $email .'">'. $email .'</a></p>';
$html .= (!$address) ? '' : '<p>'. __("Adres") .': '. $address .'</p>';
$html .= '</div>';
return $html;
}
add_shortcode( 'card', 'create_card_shortcode' );
function map_css_style(){
global $post;
if ( is_a( $post, 'WP_Post' ) && !has_shortcode( $post->post_content, 'map') ) { return false; }
?>
<style>
.map-wrapper {
display: flex;
align-items: flex-start
}
.map-box {
display: inline-block;
position: relative;
width: 50%;
padding-bottom: 50%;
vertical-align: middle;
overflow: hidden
}
.map-box svg {
display: inline-block;
position: absolute;
top: 0;
left: 0;
transform: scale(.9)
}
.map-box svg polygon:hover {
fill: rgba(0, 115, 170, 0.5)
}
.map-box svg .active {
fill: #0073aa
}
.map-box svg polygon {
display: block;
position: relative;
cursor: pointer
}
.cards-list {
display: flex;
flex-direction: column;
width: 50%;
max-width: 50%
}
.cards-list[data-empty="0"] .card-box.empty{
display: block;
}
.cards-list-search {
display: block;
width: 100%;
margin-bottom: 16px
}
.cards-list-search input {
display: block;
width: 100%
}
.card-box {
display: none;
padding: 16px;
background-color: #eee
}
.card-box.empty {
display: none;
}
.card-box.show + .card-box.show {
margin-top: 16px
}
.card-box.show {
display: block;
}
.card-box p {
margin: 0
}
</style>
<?php
}
add_action('wp_head', 'map_css_style', 100);
function map_script_style(){
global $post;
if ( is_a( $post, 'WP_Post' ) && !has_shortcode( $post->post_content, 'map') ) { return false; }
?>
<script>
const map_box = document.querySelectorAll('.map-box svg polygon');
const map_cards_list = document.querySelector('.cards-list');
const map_cards = map_cards_list.querySelectorAll('.card-box:not(.empty)');
function search_cards(query){
query = query.split(" ");
map_cards.forEach(function(card, i){
let search = card.dataset.search;
search = search.toLowerCase();
let find = 0;
query.forEach(function(el){
if( el.length > 0 ){
console.log(i, el, search, search.search(el), search.includes(el));
if( search.includes(el) > 0 ){
find++;
}
}
});
map_cards_list.setAttribute("data-search", find);
if( find > 0 ){
card.classList.add("show");
}
else{
card.classList.remove("show");
}
});
}
map_box.forEach(function(el){
el.addEventListener("click", function(e){
let woj = el.dataset.woj;
woj = woj.toLowerCase();
map_box.forEach(function(elm){elm.classList.remove("active");});
el.classList.add("active");
search_cards(woj);
});
});
</script>
<?php
}
add_action('wp_footer', 'map_script_style', 100);
// Create Shortcode map
// Shortcode: [map][/map]
function create_map_shortcode($atts, $content = null) {
$atts = shortcode_atts( array( ), $atts, 'mapka' );
$html = '<div class="map-wrapper">';
$html .= '<div class="map-box">';
$html .= '<svg viewBox="0 0 500 480"><polygon data-woj=" podkarpackie" fill="#cecece" points=" 426.6105041503906,454.2125549316406 417.0033264160156,451.04510498046875 411.23907470703125,448.2472229003906 403.2943115234375,444.728759765625 397.7436828613281,440.8729553222656 385.0124206542969,430.1250915527344 381.06927490234375,428.8128662109375 373.6282043457031,427.8734130859375 365.05096435546875,427.0694885253906 356.100830078125,405.0213623046875 352.2062683105469,397.42120361328125 351.6747741699219,392.2021179199219 353.59619140625,389.8023986816406 351.6747741699219,386.59332275390625 349.7533264160156,378.4233703613281 348.3060607910156,367.19866943359375 350.5705871582031,357.42138671875 361.6924743652344,347.2991027832031 371.9172668457031,338.0848693847656 385.8646545410156,322.5431823730469 390.1033630371094,321.29571533203125 393.3813171386719,320.0865173339844 395.86761474609375,325.6969909667969 404.3155212402344,334.55865478515625 412.52001953125,339.7120361328125 408.03668212890625,342.9013671875 403.5533447265625,349.4296569824219 411.97930908203125,356.3629455566406 421.9295654296875,358.1767578125 433.9512939453125,359.9906005859375 442.6388854980469,357.3687744140625 457.7572326660156,356.9844055175781 461.3634948730469,360.01043701171875 455.6418151855469,367.1125793457031 448.3211975097656,377.07867431640625 445.81793212890625,380.5472717285156 434.29620361328125,398.8090515136719 433.2243957519531,399.89471435546875 427.82568359375,407.69720458984375 423.498779296875,415.4997253417969 425.79669189453125,421.5321350097656 427.21807861328125,434.18707275390625 433.8836669921875,448.8138427734375 436.8581237792969,453.12322998046875 426.6105041503906,454.2125549316406"></polygon><polygon data-woj="małopolskie malopolskie" fill="#cecece" points=" 290.12054443359375,445.77337646484375 281.2223815917969,445.28106689453125 280.26165771484375,444.5718078613281 281.8628845214844,437.1385192871094 277.493408203125,431.3342590332031 266.4914245605469,420.4879455566406 264.57000732421875,416.386474609375 262.6485900878906,413.4143981933594 254.87359619140625,401.8158874511719 249.83905029296875,395.2784118652344 246.68588256835938,387.84619140625 243.53271484375,385.0498352050781 246.3656463623047,381.5785827636719 254.0021514892578,373.1825256347656 256.8504943847656,363.1687316894531 269.2734375,353.94451904296875 281.27532958984375,348.91033935546875 289.6993408203125,346.4919128417969 301.0771484375,354.6517639160156 306.8118591308594,368.7388916015625 321.374755859375,367.9613952636719 343.2353515625,361.1998291015625 346.405029296875,378.2748107910156 348.3349609375,388.2508544921875 348.62921142578125,390.2209777832031 349.6617126464844,399.848388671875 353.6379089355469,407.94427490234375 357.6046142578125,420.2113342285156 359.3773193359375,426.2799987792969 350.3784484863281,426.71337890625 342.067626953125,429.3328857421875 330.6280822753906,433.30511474609375 318.3758239746094,430.3023681640625 305.6641845703125,433.1683654785156 301.3289489746094,436.171142578125 295.7955627441406,442.2201843261719 290.12054443359375,445.77337646484375"></polygon><polygon data-woj="sląskie slaskie" fill="#cecece" points=" 239.5914306640625,430.2270202636719 234.5294189453125,424.5916442871094 229.0853729248047,414.6375732421875 226.7819061279297,408.37603759765625 217.17477416992188,397.41259765625 213.3319091796875,390.43023681640625 208.27215576171875,388.918701171875 204.0478057861328,387.80255126953125 190.51490783691406,374.9510803222656 194.13645935058594,373.2919616699219 203.71078491210938,370.04620361328125 209.5677947998047,363.69781494140625 209.35621643066406,350.42095947265625 211.4104766845703,347.1768493652344 215.2533416748047,343.66619873046875 219.09620666503906,341.0571594238281 212.34744262695312,331.1463623046875 213.308349609375,328.57562255859375 216.13023376464844,321.7480163574219 219.42352294921875,314.7721252441406 221.3164825439453,307.1796875 229.87054443359375,299.5298767089844 236.52464294433594,302.5785827636719 245.2366485595703,305.423828125 258.2275085449219,311.88958740234375 262.6133117675781,315.2496643066406 266.9546813964844,317.0634765625 269.53173828125,318.8772888183594 270.7001037597656,323.60235595703125 274.32989501953125,331.95526123046875 276.40411376953125,337.9060363769531 276.09857177734375,345.0427551269531 267.0285949707031,350.8880920410156 257.20452880859375,355.8189697265625 253.04144287109375,364.3901672363281 250.79977416992188,371.4778137207031 244.0088348388672,389.686767578125 247.53146362304688,397.1706237792969 252.38978576660156,404.12969970703125 258.62982177734375,409.9296569824219 254.34666442871094,420.07928466796875 247.65591430664062,426.728271484375 242.54730224609375,431.3342590332031 239.5914306640625,430.2270202636719"></polygon><polygon data-woj="opolskie" fill="#cecece" points=" 178.32899475097656,382.58544921875 175.5438232421875,378.395751953125 172.98190307617188,375.71038818359375 170.42001342773438,373.13623046875 172.98190307617188,371.2239074707031 175.5438232421875,366.63671875 175.5438232421875,362.68194580078125 166.71246337890625,362.21087646484375 152.76344299316406,356.9087829589844 137.83535766601562,347.86700439453125 134.07212829589844,346.576416015625 138.1555938720703,344.2321472167969 142.23904418945312,339.53582763671875 144.89813232421875,336.7973327636719 153.3093719482422,320.62713623046875 159.63296508789062,312.3221740722656 165.2961883544922,304.2664794921875 167.85809326171875,300.7391052246094 168.9822235107422,295.9022216796875 169.13905334472656,294.0884094238281 174.41970825195312,292.27459716796875 178.105712890625,294.6930236816406 184.35365295410156,297.1114501953125 192.19619750976562,295.297607421875 203.0843048095703,294.6930236816406 208.0851593017578,295.9022216796875 216.53428649902344,302.8790588378906 217.81524658203125,306.1805419921875 216.71595764160156,312.4818115234375 213.56834411621094,319.32958984375 210.8247528076172,326.0754699707031 209.8533477783203,333.38787841796875 213.01708984375,336.8380432128906 212.0123291015625,341.64898681640625 208.84857177734375,344.7014465332031 206.7657470703125,348.0249328613281 205.41026306152344,357.8467102050781 204.46347045898438,366.03668212890625 199.53237915039062,368.4551086425781 192.4007110595703,370.87353515625 187.5721435546875,377.8265380859375 182.28677368164062,385.3841247558594 178.32899475097656,382.58544921875"></polygon><polygon data-woj="dolnośląskie dolnoslaskie" fill="#cecece" points=" 116.66555786132812,371.52392578125 114.05809783935547,366.1053161621094 102.5489730834961,350.79425048828125 103.81047821044922,343.0616149902344 107.65332794189453,336.9159240722656 104.8498764038086,329.8073425292969 96.7652359008789,328.551025390625 80.75334167480469,323.0272521972656 76.54143524169922,321.29571533203125 55.13428497314453,304.7059631347656 52.25214385986328,302.0594482421875 45.74789810180664,300.69989013671875 37.4438591003418,306.000732421875 33.921234130859375,310.4128112792969 33.31422424316406,305.29864501953125 37.940608978271484,296.3687438964844 42.467811584472656,285.6990966796875 43.38426208496094,275.6202087402344 43.3568115234375,271.1461181640625 49.37000274658203,269.29949951171875 61.5390510559082,264.1365051269531 65.35260772705078,263.7852783203125 68.23235321044922,266.8645935058594 76.93485260009766,261.369873046875 80.83106231689453,256.5794677734375 84.12920379638672,251.01422119140625 86.6925277709961,246.82504272460938 88.43904876708984,246.28646850585938 88.6112289428711,244.20828247070312 96.7947006225586,240.0547637939453 101.59130859375,244.88511657714844 109.66288757324219,244.13766479492188 112.31292724609375,238.92788696289062 117.66885375976562,244.4129638671875 123.02477264404297,252.3311309814453 129.91163635253906,259.0807800292969 155.81924438476562,262.1319274902344 160.58477783203125,259.4776611328125 163.26072692871094,262.1116943359375 164.33547973632812,265.3095703125 162.73428344726562,268.6521301269531 168.37408447265625,272.77142333984375 174.54237365722656,279.8679504394531 175.62759399414062,287.4377136230469 172.34144592285156,289.167724609375 165.33692932128906,295.528564453125 164.01524353027344,298.9252624511719 162.73428344726562,301.8768615722656 157.07107543945312,309.9037170410156 150.74746704101562,318.2087097167969 142.3362274169922,334.3788757324219 139.67715454101562,337.1558837890625 135.84237670898438,341.6063537597656 131.99952697753906,345.26409912109375 130.07000732421875,348.6758117675781 132.6319122314453,358.09954833984375 132.7509765625,365.49078369140625 123.82984924316406,370.2038269042969 119.27300262451172,374.14398193359375 116.66555786132812,371.52392578125"></polygon><polygon data-woj="świetokrzyskie swietokrzyskie" fill="#cecece" points=" 309.3737487792969,366.3204650878906 303.6390686035156,352.2158203125 290.06201171875,343.78948974609375 278.991455078125,340.4516906738281 276.63995361328125,329.262451171875 274.1773681640625,321.8996887207031 276.6327819824219,317.6680908203125 280.5819091796875,309.41705322265625 285.7057189941406,307.7871398925781 290.82952880859375,308.2484130859375 290.82952880859375,303.41387939453125 288.9297180175781,297.89117431640625 287.7857971191406,295.3433837890625 294.8094482421875,293.4837951660156 301.0771484375,291.1468505859375 303.6390686035156,288.0423278808594 306.2009582519531,285.08587646484375 314.4310607910156,284.4837951660156 318.2485046386719,288.12158203125 324.1284484863281,291.92364501953125 334.0169982910156,294.318115234375 341.67205810546875,295.8140869140625 347.1440734863281,299.37359619140625 353.6011047363281,302.5584716796875 363.84381103515625,302.5528869628906 369.48162841796875,300.7391052246094 376.6004943847656,311.0904846191406 377.3042297363281,325.2987365722656 373.2218933105469,330.1274108886719 369.0212097167969,335.70721435546875 360.2801513671875,344.1017150878906 347.1914367675781,356.3294677734375 343.6688232421875,358.2642822265625 318.8128356933594,365.5404968261719 309.3737487792969,366.3204650878906"></polygon><polygon data-woj="lubelskie" fill="#cecece" points=" 424.048583984375,355.75836181640625 414.37738037109375,354.0365295410156 410.90716552734375,344.87542724609375 416.1434326171875,340.2330017089844 406.8526916503906,332.1402282714844 398.4295349121094,323.278564453125 398.4295349121094,317.6680908203125 393.3813171386719,317.6680908203125 387.54144287109375,318.8772888183594 384.4475402832031,320.0865173339844 377.7964782714844,294.0997009277344 379.4936218261719,283.6476745605469 379.9661865234375,279.4041442871094 377.8409729003906,269.29949951171875 373.4225158691406,260.1849670410156 373.3783264160156,254.78890991210938 380.4961853027344,243.10369873046875 381.77716064453125,236.0460968017578 381.4569091796875,227.79541015625 384.04547119140625,226.32925415039062 388.9246520996094,224.40237426757812 397.22418212890625,223.34933471679688 404.83428955078125,222.14012145996094 410.04443359375,220.930908203125 414.4414367675781,218.51246643066406 415.56048583984375,216.09405517578125 418.2843017578125,217.3032684326172 426.9501037597656,216.8158416748047 432.1680603027344,209.9013214111328 444.813232421875,205.73681640625 449.75341796875,207.62954711914062 455.55291748046875,210.651123046875 460.41851806640625,213.67416381835938 460.8685607910156,223.2300262451172 461.55194091796875,234.08438110351562 460.7816467285156,237.624267578125 458.6343078613281,247.33453369140625 461.836669921875,257.43341064453125 465.0390625,267.57586669921875 468.8275451660156,278.9183044433594 480.4104919433594,297.8706970214844 482.15838623046875,300.3766784667969 486.0540771484375,305.3100891113281 486.2276306152344,311.1402282714844 487.4557189941406,320.8061828613281 488.86859130859375,335.11358642578125 480.2361755371094,343.0616149902344 465.88287353515625,355.7003479003906 459.3768005371094,354.02105712890625 448.79144287109375,350.31689453125 440.9616394042969,353.9368896484375 433.6557312011719,357.4725646972656 424.048583984375,355.75836181640625"></polygon><polygon data-woj="łódzkie lodzkie" fill="#cecece" points=" 270.1036376953125,315.3503723144531 264.9267578125,312.83123779296875 260.6363525390625,309.8971862792969 247.80833435058594,302.5528869628906 238.90403747558594,299.8321838378906 229.34678649902344,297.1114501953125 220.97853088378906,298.3804016113281 217.12123107910156,296.5665588378906 210.26629638671875,293.4837951660156 205.6461944580078,292.27459716796875 201.7277374267578,291.06536865234375 198.60096740722656,290.0411682128906 196.03904724121094,286.2284851074219 195.54188537597656,275.23333740234375 201.7754364013672,273.95477294921875 207.67782592773438,259.02117919921875 215.4615020751953,242.93914794921875 225.83692932128906,232.8826904296875 230.238037109375,223.1334228515625 234.21551513671875,218.97958374023438 237.73814392089844,213.86634826660156 240.8920135498047,209.7716064453125 246.84136962890625,202.20314025878906 255.6033477783203,204.3030242919922 268.4128723144531,207.16445922851562 280.42340087890625,206.16864013671875 287.5694274902344,212.7467041015625 292.1290283203125,217.91693115234375 295.9533386230469,225.55699157714844 297.490478515625,232.78123474121094 307.7137145996094,234.23226928710938 317.164306640625,237.5576171875 319.3199462890625,243.59193420410156 312.2032470703125,250.47323608398438 308.76287841796875,260.23040771484375 311.32476806640625,265.0128173828125 312.7346496582031,268.9375305175781 311.4537048339844,271.0746765136719 308.734375,273.3109436035156 306.2009582519531,277.7640075683594 303.66754150390625,282.8216857910156 301.0771484375,285.6239013671875 298.5152587890625,288.7284240722656 292.2475280761719,291.06536865234375 285.2023010253906,292.97808837890625 286.3462219238281,300.3017883300781 286.42181396484375,305.575927734375 283.7843017578125,304.3667297363281 278.0743103027344,307.8039855957031 274.2595520019531,315.15997314453125 271.77020263671875,317.8694763183594 270.1036376953125,315.3503723144531"></polygon><polygon data-woj="mazowieckie" fill="#cecece" points=" 356.1629943847656,300.1400451660156 349.7059631347656,296.9551696777344 344.2152404785156,293.32806396484375 336.79150390625,290.8745422363281 326.3147888183594,289.4195861816406 320.6146545410156,285.71136474609375 316.95037841796875,281.9051513671875 313.1898193359375,278.2472229003906 314.0050048828125,273.4963073730469 315.1676330566406,266.2764587402344 313.8866882324219,262.764892578125 311.35498046875,257.8377685546875 314.40423583984375,253.5797119140625 320.7333984375,251.36837768554688 321.71759033203125,240.96768188476562 319.7381286621094,236.05946350097656 318.8943786621094,231.8138427734375 310.2419738769531,231.8138427734375 300.0523986816406,230.36279296875 298.5152587890625,223.17349243164062 295.0224304199219,215.85491943359375 290.38934326171875,210.64976501464844 281.0721740722656,203.6259002685547 269.37493896484375,204.65966796875 257.5261535644531,201.58432006835938 253.68191528320312,193.1189727783203 254.946044921875,185.12228393554688 259.02520751953125,174.00527954101562 260.086669921875,164.70242309570312 258.80572509765625,161.00341796875 261.2785339355469,158.05174255371094 264.1606750488281,155.38058471679688 267.77239990234375,151.98948669433594 270.9747619628906,145.2989959716797 276.38568115234375,137.5529327392578 286.083740234375,137.2408447265625 296.0442810058594,138.673095703125 304.0647888183594,133.83624267578125 312.407470703125,129.03057861328125 319.6674499511719,126.30985260009766 324.9608459472656,123.21965026855469 331.2439270019531,120.49890899658203 338.90692138671875,118.14763641357422 345.81109619140625,116.44686889648438 353.4957580566406,114.33074951171875 359.6851806640625,113.91541290283203 360.33935546875,124.77136993408203 363.2420654296875,136.863525390625 372.81048583984375,147.07113647460938 386.9923400878906,160.4701690673828 391.7275085449219,162.8885955810547 397.7998962402344,165.30702209472656 402.27239990234375,168.08822631835938 403.77105712890625,172.28416442871094 403.6265563964844,178.3990020751953 410.61529541015625,192.3660125732422 424.51251220703125,196.74661254882812 433.0152587890625,198.5604248046875 437.3351745605469,200.51731872558594 436.4037780761719,201.42422485351562 429.7649841308594,207.45870971679688 420.8547058105469,214.89779663085938 415.52685546875,213.6756134033203 410.3292541503906,216.09405517578125 405.9658508300781,218.51246643066406 402.27239990234375,219.72169494628906 394.66229248046875,220.930908203125 386.36273193359375,221.9839324951172 381.8038024902344,223.76754760742188 379.471435546875,230.36279296875 379.471435546875,233.264892578125 377.9342956542969,240.85572814941406 370.8164367675781,252.3704833984375 371.1492614746094,262.7458801269531 374.78973388671875,270.6512145996094 375.3173522949219,277.1593933105469 374.5686340332031,296.20452880859375 368.397705078125,298.3206481933594 361.28192138671875,300.13446044921875 356.1629943847656,300.1400451660156"></polygon><polygon data-woj="wielkopolskie" fill="#cecece" points=" 179.57513427734375,288.94921875 177.2379608154297,277.44952392578125 170.64859008789062,270.2846374511719 166.28973388671875,268.3822937011719 164.89340209960938,258.6273498535156 155.34817504882812,258.7188720703125 132.84107971191406,256.8927001953125 125.586669921875,249.86732482910156 119.2822494506836,241.09619140625 112.06800842285156,231.38150024414062 105.7156982421875,228.7299041748047 99.50147247314453,226.59756469726562 92.94390869140625,218.66029357910156 88.61982727050781,201.1620330810547 87.80255889892578,191.91392517089844 87.1726303100586,187.6609649658203 87.22456359863281,180.685302734375 84.52871704101562,173.57235717773438 85.16002655029297,170.2039337158203 87.73524475097656,164.59576416015625 90.47853088378906,159.6554718017578 96.12476348876953,148.43807983398438 99.99307250976562,144.7503662109375 115.35710144042969,135.63644409179688 118.18949890136719,132.65716552734375 129.4295196533203,120.80889129638672 127.03656005859375,117.59365844726562 122.35468292236328,114.48914337158203 123.14646911621094,112.09706115722656 134.78709411621094,103.62113189697266 137.75572204589844,102.0750503540039 153.77804565429688,109.21723175048828 158.4466552734375,112.72061920166016 159.5319061279297,123.70030975341797 159.7071533203125,130.3844451904297 155.9176025390625,140.27127075195312 161.5174560546875,153.8507843017578 163.239501953125,162.25645446777344 163.39532470703125,173.27984619140625 169.1596221923828,173.41607666015625 171.70095825195312,175.7364959716797 177.96975708007812,178.11993408203125 183.79049682617188,181.90676879882812 189.5623321533203,185.8453826904297 196.04669189453125,188.8953857421875 206.2866668701172,188.88670349121094 210.4268035888672,189.49131774902344 215.5931854248047,191.9097442626953 220.26185607910156,194.63047790527344 232.087158203125,201.09173583984375 238.36276245117188,201.66331481933594 234.2311248779297,212.17730712890625 231.66921997070312,217.0084228515625 227.46905517578125,220.9293975830078 222.5787353515625,233.10250854492188 220.85000610351562,238.45701599121094 213.5361785888672,239.63015747070312 205.07618713378906,256.61053466796875 203.52926635742188,271.09918212890625 199.96241760253906,270.2901916503906 193.58447265625,272.6248474121094 188.5048828125,276.5547790527344 188.7777557373047,280.41033935546875 191.36407470703125,285.33355712890625 193.50155639648438,288.6469421386719 194.7581024169922,289.85614013671875 193.38565063476562,291.06536865234375 190.09176635742188,292.8791809082031 184.71023559570312,294.6930236816406 179.57513427734375,288.94921875"></polygon><polygon data-woj="lubuskie" fill="#cecece" points=" 51.857582092285156,266.767578125 46.017696380615234,265.892578125 41.04380798339844,264.9883117675781 36.07195281982422,262.2300720214844 29.487693786621094,254.252685546875 26.95333480834961,240.88294982910156 23.146100997924805,236.12216186523438 27.077539443969727,230.00003051757812 30.97331428527832,225.1631622314453 30.091896057128906,212.46641540527344 26.834932327270508,195.0743865966797 26.987323760986328,187.02784729003906 27.92475700378418,173.96302795410156 28.244998931884766,171.32127380371094 32.304412841796875,170.1623992919922 39.762855529785156,161.12249755859375 42.96059799194336,155.63742065429688 49.436588287353516,154.45773315429688 58.48671340942383,153.15289306640625 66.29971313476562,148.07571411132812 70.54740142822266,145.9595947265625 74.34857177734375,144.14576721191406 79.46910095214844,142.33193969726562 86.99797821044922,141.57618713378906 91.00096130371094,137.34393310546875 92.86202239990234,133.867431640625 94.07449340820312,140.2158203125 89.0261459350586,156.66612243652344 85.07654571533203,162.73748779296875 82.5203857421875,167.84640502929688 82.25682830810547,175.91635131835938 83.63471221923828,185.15518188476562 85.15936279296875,194.26760864257812 85.75869750976562,200.68812561035156 84.65198516845703,210.9299774169922 90.38199615478516,221.0787353515625 96.95463562011719,229.0727081298828 103.27120971679688,231.61697387695312 108.0003890991211,240.26890563964844 103.81047821044922,240.88294982910156 102.4825210571289,237.2279052734375 87.53479766845703,241.02203369140625 83.42073059082031,243.90599060058594 81.52172088623047,248.86488342285156 78.21038055419922,254.4338836669922 74.30400848388672,259.148681640625 66.89592742919922,260.23040771484375 63.74413299560547,257.20733642578125 58.977142333984375,262.0986328125 53.507816314697266,268.09027099609375 51.857582092285156,266.767578125"></polygon><polygon data-woj="kujawsko-pomorskie" fill="#cecece" points=" 240.8723907470703,199.01119995117188 234.17189025878906,198.2559051513672 222.92697143554688,192.21205139160156 217.8920135498047,189.49131774902344 212.69143676757812,187.07289123535156 202.44381713867188,186.46827697753906 196.8125762939453,186.00247192382812 191.12890625,183.06236267089844 185.45083618164062,178.08670043945312 175.8000030517578,175.22259521484375 174.2628631591797,173.2505645751953 170.0997772216797,170.42849731445312 166.11753845214844,164.39146423339844 163.08340454101562,150.68438720703125 158.7269287109375,141.2175750732422 162.200439453125,132.36302185058594 162.09381103515625,121.28186798095703 160.8128662109375,115.29193878173828 162.73428344726562,112.97126007080078 168.98245239257812,100.70539855957031 174.17413330078125,101.3706283569336 180.72604370117188,100.56413269042969 183.22952270507812,96.9283447265625 189.7792510986328,93.9633560180664 193.01393127441406,92.14952850341797 203.3180694580078,92.58871459960938 213.8821563720703,95.68573760986328 226.46998596191406,100.0404281616211 238.31048583984375,104.50099182128906 246.6366729736328,105.45089721679688 247.03627014160156,110.01757049560547 263.29302978515625,123.24301147460938 269.0533447265625,129.7467803955078 271.2950134277344,134.4637908935547 270.7751770019531,136.32589721679688 267.8033447265625,146.59942626953125 262.96881103515625,150.2698974609375 261.36761474609375,153.17694091796875 258.97332763671875,155.63330078125 257.23150634765625,166.87843322753906 256.55291748046875,171.3599853515625 253.68191528320312,174.8722686767578 252.4009552001953,176.18995666503906 252.55198669433594,187.9409942626953 251.27102661132812,190.8921356201172 248.55810546875,195.18113708496094 246.0803985595703,199.1225128173828 240.8723907470703,199.01119995117188"></polygon><polygon data-woj="podlaskie" fill="#cecece" points=" 435.5771484375,196.14199829101562 427.07440185546875,194.32818603515625 413.2312927246094,189.98147583007812 405.56988525390625,183.8477783203125 408.72222900390625,177.39918518066406 407.3962097167969,171.35308837890625 404.86279296875,165.60931396484375 398.4295349121094,162.37945556640625 395.6035461425781,160.16786193847656 391.1994934082031,158.05174255371094 375.37237548828125,144.6527099609375 365.8039855957031,134.44508361816406 362.8895263671875,122.1839828491211 362.2236328125,111.15904998779297 367.5103454589844,110.31587982177734 373.4284973144531,108.50824737548828 380.0008239746094,106.7027816772461 395.83868408203125,95.37979125976562 401.68353271484375,90.33570098876953 412.0835876464844,78.56194305419922 410.7748718261719,68.18545532226562 407.0851745605469,60.75602722167969 403.4291687011719,52.74837875366211 400.4367980957031,50.298439025878906 406.3270568847656,45.225860595703125 412.96893310546875,38.03715896606445 422.006103515625,38.94407272338867 426.73004150390625,41.967105865478516 430.7484436035156,44.38553237915039 435.6201477050781,46.80397415161133 444.9217529296875,65.95436096191406 445.5567626953125,70.9882583618164 448.90081787109375,84.15825653076172 450.0307922363281,91.27348327636719 452.9378662109375,98.06275177001953 456.8736877441406,107.73648834228516 459.8998107910156,115.17122650146484 462.5182189941406,122.42652130126953 470.8724670410156,152.42713928222656 465.2309875488281,169.88304138183594 451.18212890625,178.82911682128906 447.4783935546875,183.2293243408203 445.82476806640625,187.15927124023438 444.78106689453125,189.49131774902344 441.5993957519531,193.7235870361328 435.5771484375,196.14199829101562"></polygon><polygon data-woj="zachodnio-pomorskie" fill="#cecece" points=" 24.39142417907715,169.4248504638672 15.466830253601074,159.8115997314453 6.500154495239258,149.71261596679688 12.222375869750977,142.2068634033203 17.986669540405273,135.05233764648438 21.395219802856445,127.14388275146484 23.37942123413086,116.0347671508789 21.146780014038086,106.05549621582031 19.419050216674805,94.56795501708984 16.97252655029297,85.89884185791016 16.249671936035156,77.73664093017578 21.042909622192383,72.14440155029297 30.15570640563965,70.24365234375 41.04380798339844,66.65126037597656 50.010475158691406,62.71487045288086 74.18047332763672,55.87755584716797 86.43208312988281,51.716678619384766 95.09017181396484,49.2224006652832 120.32755279541016,33.74126052856445 131.13194274902344,27.456531524658203 136.16224670410156,40.962215423583984 133.6894073486328,49.09849548339844 133.13096618652344,58.76262664794922 134.90008544921875,66.50302124023438 136.9629364013672,73.32974243164062 137.9311065673828,80.6619873046875 135.4943389892578,88.78480529785156 133.3975372314453,97.3500747680664 131.99142456054688,101.23164367675781 120.93058013916016,109.68315887451172 121.6728286743164,117.96009826660156 126.72564697265625,121.41535949707031 121.93905639648438,125.82758331298828 115.57357788085938,130.23980712890625 112.79704284667969,133.2134552001953 99.12223815917969,142.1227264404297 97.2094497680664,136.57635498046875 97.60161590576172,131.44900512695312 93.02034759521484,131.44900512695312 88.43904876708984,134.92550659179688 84.43607330322266,139.15774536132812 76.9072036743164,139.91351318359375 71.78666687011719,141.7273406982422 67.85960388183594,143.54115295410156 63.83171081542969,145.65728759765625 48.422000885009766,151.1306915283203 39.953407287597656,154.17147827148438 37.20094299316406,159.58685302734375 29.678455352783203,167.72544860839844 25.92856216430664,169.176513671875 24.39142417907715,169.4248504638672"></polygon><polygon data-woj="warminsko-mazurskie" fill="#cecece" points=" 288.311767578125,134.94256591796875 280.62603759765625,134.1123046875 271.6094665527344,126.9144515991211 260.7213439941406,118.34233856201172 249.83905029296875,108.32836151123047 243.8539581298828,101.78121185302734 247.46792602539062,95.09796905517578 251.98939514160156,90.16209411621094 254.9438018798828,86.70806121826172 266.4914245605469,75.97769165039062 259.6406555175781,71.0639877319336 254.803466796875,66.90967559814453 251.85867309570312,62.1064338684082 252.55035400390625,55.268470764160156 253.68191528320312,50.431610107421875 256.8316650390625,45.59475326538086 269.0218505859375,39.1431999206543 277.0592956542969,37.536556243896484 292.7509460449219,39.331993103027344 343.34857177734375,43.62543869018555 376.6533508300781,42.13706970214844 398.4295349121094,40.08106231689453 408.03668212890625,39.41514587402344 403.2330627441406,43.41185760498047 401.6319274902344,55.76314926147461 404.83428955078125,63.6501350402832 407.8721618652344,70.39308166503906 409.38568115234375,76.45768737792969 397.7462158203125,89.15148162841797 389.6636962890625,96.90321350097656 380.1212463378906,103.68354797363281 365.7652587890625,108.09475708007812 350.7715148925781,111.75627899169922 343.24920654296875,114.0284423828125 336.34503173828125,115.72920989990234 328.61761474609375,118.14763641357422 323.8515625,120.56607818603516 316.4485778808594,124.84088134765625 310.8828430175781,126.61215209960938 300.5018615722656,133.5651397705078 295.5467834472656,136.209228515625 288.311767578125,134.94256591796875"></polygon><polygon data-woj="pomorskie" fill="#cecece" points=" 146.72239685058594,104.53182220458984 138.11317443847656,90.03339385986328 140.43617248535156,83.08041381835938 142.23904418945312,77.68148803710938 139.70574951171875,71.0027084350586 137.94166564941406,64.42483520507812 135.9916534423828,56.92891311645508 136.4871368408203,51.41549301147461 138.89947509765625,40.25617980957031 136.382080078125,27.8833065032959 138.77330017089844,23.792299270629883 152.45362854003906,16.99260902404785 158.57119750976562,14.940912246704102 166.5350341796875,10.358352661132812 205.7428741455078,6.735597133636475 231.94383239746094,24.082382202148438 228.62278747558594,27.81818199157715 211.82720947265625,13.665016174316406 218.39682006835938,27.812850952148438 222.06483459472656,41.43335723876953 238.01820373535156,42.111480712890625 249.2064666748047,53.61872863769531 249.7496337890625,64.60884857177734 252.63177490234375,69.38675689697266 258.0892333984375,73.69049072265625 263.7297668457031,75.23348999023438 252.88131713867188,84.27674865722656 249.427490234375,87.74366760253906 244.81536865234375,92.71498107910156 240.12271118164062,98.3198013305664 235.92828369140625,101.65721893310547 229.16659545898438,97.94294738769531 211.92926025390625,92.78297424316406 205.6461944580078,90.33570098876953 190.4520263671875,89.7311019897461 186.79234313964844,91.56343078613281 179.87225341796875,95.77717590332031 172.18655395507812,98.19561004638672 164.040283203125,101.90235900878906 158.27601623535156,105.59552001953125 152.48667907714844,106.3894271850586 146.72239685058594,104.53182220458984"></polygon></svg>';
$html .= '</div>';
$html .= '<div class="cards-list">';
$html .= '<div class="card-box empty">';
$html .= '<p>'. __("Nie znaleziono") .'</p>';
$html .= '</div>';
$html .= do_shortcode($content, true);
$html .= '</div>';
$html .= '</div>';
return $html;
}
add_shortcode( 'map', 'create_map_shortcode' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment