My custom wordpress plugin shortcode is working when I just return something. But I want to return another php page, which includes html.
This is my map.php
<?php
function example($map){
echo "Hello!";
}
?>
I've tried like this
add_shortcode( 'map_shortcode', 'map_shortcode' );
function map_shortcode() {
wp_enqueue_style( 'my-css' );
wp_enqueue_style( 'meyer-reset' );
wp_enqueue_style( 'tooltipster-bundle' );
wp_enqueue_script( 'mypluginscript' );
return $map;}
?>
I mean the shortcode works; when I tried just a simple string like 'abc' it showed, so it works, but I want to show the other page on the return function.
functions.phpfile usingwp_enqueue_scripts()function. developer.wordpress.org/themes/basics/including-css-javascript/…