javascript - Regarding using the Vue framework on the front end and WordPress on the back end, how to call the back-end functions?
PHP中文网
PHP中文网 2017-05-19 10:15:07
0
4
577
Blog information is displayed in the

tag. The official wordpress writing method is like this

If I use vue as the front-end framework, how do I add this code to the php code (my writing method is definitely wrong)

Question: I would like to ask how to write such a situation, thank you, I am a newbie still figuring it out.

PHP中文网
PHP中文网

认证0级讲师

reply all(4)
阿神

It can’t be written.
This needs to be parsed through vueLoader. It cannot be written like this without using php
.

伊谢尔伦

You need to separate the front and back ends ~~ Use ajax to request, vue-resource is not officially recommended. It is recommended to use axios

漂亮男人

The front and back ends are separated, the routing front end is determined, PHP only returns the interface data, or the front end is mixed with PHP, so there is no need for the Vue framework

phpcn_u1582

If it’s php rendering, your writing method is fine, but you can’t use .vue files.

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template