I'm new in wordpress and I don't know two much about this.
Situation There is plugin that generate shortcode [unread_messages].
plugin path is wp-content/plugin/chat/ I create a php file under wp-content/custom/messages.php
messages.php
<?php
echo do_shortcode('[unread_messages]');
?>
And I call request through AJAX like providing url wp-content/custom/messages.php But this php file gives an error call undefined function do_shortcode
How can I access the value of shortcode through which is not a part of plugin.