douyu1656 2012-12-01 15:33
浏览 56
已采纳

我看不到wordpress .php文件?

I installed WAMP server on Windows XP - it worked. I installed Wordpress 3.4.2 into www.wordpress - no problem. In Dreamweaver CS5 I created a site with www.wordpress as root folder, and assigned a local test server - no problem.

The, in Dreamweaver, I opened twentyten theme - index.php - and pressed <kbd>F12</kbd> to see the page in Firefox - and got:

Fatal error: Call to undefined function get_header()... - on line 16

This is a completely new and clear wordpress installation. Why is the function (get_header) - undefined? To check the server I copied another .php file into the same folder - <kbd>F12</kbd> - it works.

  • 写回答

3条回答 默认 最新

  • doucang2831 2012-12-01 17:50
    关注

    When you click the <kbd>F12</kbd> in Dreamweaver , it will open the file in the browser using the windows local path file system to the file, which wont work as you should run the file on localhost.

    Using <kbd>F12</kbd> file will open as C:\\Wamp\Wordpress\index.php.

    But you should rather open it as localhost/wordpress/.

    Also, you should be running index.php that is in wordpress folder and not the index file that is in themes folder.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(2条)

报告相同问题?

悬赏问题

  • ¥20 我要一个分身加定位两个功能的安卓app
  • ¥15 基于FOC驱动器,如何实现卡丁车下坡无阻力的遛坡的效果
  • ¥15 IAR程序莫名变量多重定义
  • ¥15 (标签-UDP|关键词-client)
  • ¥15 关于库卡officelite无法与虚拟机通讯的问题
  • ¥15 目标检测项目无法读取视频
  • ¥15 GEO datasets中基因芯片数据仅仅提供了normalized signal如何进行差异分析
  • ¥100 求采集电商背景音乐的方法
  • ¥15 数学建模竞赛求指导帮助
  • ¥15 STM32控制MAX7219问题求解答