【发布时间】:2012-12-19 13:01:57
【问题描述】:
我正在为 WordPress 开发模板页面,我需要在单击按钮时加载图像,路径为 namesite.com/wordpress/test,我需要加载图像
$("<img src='wp-content/themes/twentytwelve/images/loader.gif' class='loader' />").appendTo("#contact");
问题是图像没有在wordpress/wp-content/themes/twentytwelve/images/loader.gif 中搜索,而是在wordpress/test/wp-content/themes/twentytwelve/images/loader.gif 中搜索,所以我有错误。我该怎么办?
【问题讨论】: