Anybody knows if i could upload a leaflet or openlayers3 map to wordpress webpage?

Rather than uploading the static files, the “WordPress way” would be to:

  1. Create a child theme

  2. Create a Page Template – this is where you can include your HTML for the map. You will probably also want to include basic theme tags such as wp_head() and wp_footer() so your header and footer are included and the page looks like the rest of your WordPress site. I would start by copying your current theme’s page.php file and then adding the custom HTML in the middle, close to the Loop. Depending on your desire you may want to remove the Loop (which means any content you type into the Editor will not appear – only your hard-coded map will) or you might want to leave it in place so you can add text either above or below the map, depending on where you insert the map HTML.

  3. Enqueue the JS and CSS – you can restrict it so they only appear on the map page, not the entire website.

  4. Create a Page in WordPress – make sure to choose your Page Template, and once you publish it, WordPress will combine the HTML, JS, and CSS to display your map.