dongluan0020 2017-04-05 19:20
浏览 66

在WordPress中设置阻止直接访问方法后,主题不再起作用

I experienced the following issues during my WordPress theme development:

  1. If I set up the 'prevent direct access' method on the top of every WP PHP file, I can't reach the WP admin dashboard anymore, I see only the white screen. Anyway, the front-end works correctly. If I delete this lines in my PHP codes, it doesn't solve this problem, because I can't reach the WP admin dashboard still.

Here is the code I'm using:

<?php if ( ! defined( 'ABSPATH' ) ) exit; ?>
  1. If I activate another theme and login into WP admin dashboard, after re-activating my original theme works fine further. But, If I logout again from the WP admin dashboard, I get a bad redirection with the following lines: 'wp-login.php?action=logout&_wpnonce=94d379d5aa'

Do you have any ideas, what could be the solution?

Thanks a lot!

Frank

  • 写回答

0条回答 默认 最新

    报告相同问题?

    悬赏问题

    • ¥60 大一项目课,微信小程序
    • ¥15 求视频摘要youtube和ovp数据集
    • ¥15 在启动roslaunch时出现如下问题
    • ¥15 汇编语言实现加减法计算器的功能
    • ¥20 关于多单片机模块化的一些问题
    • ¥30 seata使用出现报错,其他服务找不到seata
    • ¥35 引用csv数据文件(4列1800行),通过高斯-赛德尔法拟合曲线,在选取(每五十点取1点)数据,求该数据点的曲率中心。
    • ¥20 程序只发送0X01,串口助手显示不正确,配置看了没有问题115200-8-1-no,如何解决?
    • ¥15 Google speech command 数据集获取
    • ¥15 vue3+element-plus页面崩溃