How to reuse php templates as shortcodes?

You can write a wrap function for short code like that. function simplest_shortcode_ever() { ob_start(); ?> Your PHP Logic here <?php return ob_get_clean(); } add_shortcode( ‘simple_shortcode’, ‘simplest_shortcode_ever’ ); And then use it[simple_shortcode]

Shortcode to do math with url variables

In your case, because you call [URLParam] twice, you need to store this data in session, because every call of your shortcode is isolated. If number of params is fixed (param1, param2 and operation, for example) better use it in single shortcode. Actually, there is a lot of variations, how to solve this. You can … Read more

Primary menu shortcode name

You basically have everything set. You simply need to call the shortcode: [shortcodemenu menu=”slug-of-your-menu”] Remember to use the SLUG of the menu you want to show instead of its name.

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)