开发者

Require or Include PHP class : can't access functions

I am working on a Wordpress-based site. I'm trying to include a PHP class, and seem to have success, though I can't use the functions within the class (functions are not recognized).

Note: I'm including the clas开发者_StackOverflow中文版s inline via a custom template page within my WP theme.


Try to instantiate the class first, then access the function through your variable

$a = new Class();
$a->function();

But some functions are private, read the documentation of the class first..

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜