How to echo script in php

后端 未结 6 1109
再見小時候
再見小時候 2021-01-20 04:11

I am using the shortcode execute plugin in wordpress.

This simply allows me to write shortcode like this [email_spamproof]

But I am trying to echo a script.

6条回答
  •  失恋的感觉
    2021-01-20 04:19

    It is easy. Save your javascript code in a new one file and then use this to load it:

    include('myjavascript.php');
    

    Then you will use the include option as a echo because the web will understand your code as HTML and you execute it when you want with php (like echo).

提交回复
热议问题