- This topic has 6 replies, 2 voices, and was last updated 1 year, 11 months ago by Tom.
May 16, 2019 at 4:32 am #901292Joseph
Not sure why when creating a hook in Elements it redirects to the main directory when saving. We build our sites under our staging site directory and install a fresh WP under a subdirectory for each client. This time around when I save an element it redirects to our staging site main directory. It’s a new site and I disables the short list of plugins and still get the redirect. When I go back to the WP dashboard and view the Elements module, I see the title of the element I tried creating in draft mode. Here is what I am using for that Element.
<?php if ( is_page( '2' ) ) : ?> <div> </div> <?php endif; ?>
Activate PHP/ shortcodes
Location: Front Page.
Any help is appreciated.May 16, 2019 at 8:22 am #901651TomLead DeveloperLead Developer
So it just redirects to the home page? Is this only happening on the staging site?
Are your URLs set to the staging URL in “Settings > General”?May 16, 2019 at 9:51 am #901756Joseph
It’s only happening with this install. I have reinstalled WP and still does the same. I have no plugin activated.
These are our settings: https://provinciaclient.com/savannahrae/docs/savvy_wip.png
We build our sites under our staging URL and create a client based subdirectory.
I can send you login credentials if you’d like.
Thanks Tom!!May 16, 2019 at 5:43 pm #902051TomLead DeveloperLead Developer
So it’s only on this one site? Not the others? I wonder if something weird happened in the database. What if you re-create the staging site – same issue?May 16, 2019 at 10:49 pm #902147Joseph
Yes it’s only this site or the latest WP install which is this site. All of the other sites under development in the staging URL work fine. I have reinstalled WP several (4) times and get the same result.
The rest of the GP Premium options work fine. It’s just the Element issue. I even tried the “Header Element” option and got the same result. I went into the MyPHP platform and the database is normal.
Here is a video of what is happening. After it goes to the URL main page and I go back to the Elements option it has the Element listed but only as a “Draft”
This is concerning as we have more sites in que for development.
Thanks TomMay 17, 2019 at 3:53 am #902383Joseph
Ok Tom finally got to the bottom of this. Our staging URL was blacklisted in ModSecurity. Once it was whitelisted everything is working well. Our hosting provider thought they would add additional security and that did not work.
FYI for others that may encounter this issue.
Mod_security is an Apache module that helps to protect your website from various attacks. Mod_Security is used to block commonly known exploits by use of regular expressions and rule sets. We installed a Mod_Security for increasing the security of our servers. It is an Apache module which works as a web application firewall. It blocks known exploits and provides protection from a range of attacks against web applications. Its activity may cause such issues from time to time, when requests sent to the server match with mod_sec rules. Sometimes such requests are false-positive.
Thank you for your time Tom.May 17, 2019 at 7:11 am #902697
- You must be logged in to reply to this topic.