How to get page title in to shortcode parameter's value? I have custom php script written which accepts parameters, I can send hard coded shotcodes in parameter as value but I have to send the page's title in parameter
2 Answers
Not sure that I understand your question, but to get the title of the current post use get_the_title(). You can use it within the shortcode function or when prepering the call for the custom php script you made.
https://developer.wordpress.org/reference/functions/get_the_title/