I have a shortcode that is working and displaying the problem is that it jumps to the top of the page. If I have any text or other shortcodes above it in the page editor they will be displayed below this one on the front end.
add_shortcode('shortcode_exsample', 'shortcode_name');
function shortcode_name(){
return require_once ( plugin_dir_path(__FILE__) . '/shortcode_file.php');;
};
There is about 259 lines of HTML in the shortcode_file.php
file that is why I am doing it this way rather that just having it inside the function.
Any idea on why this is happening would be great. Thank you.