Title: admin restrictions affecting forms
Last modified: December 27, 2018

---

# admin restrictions affecting forms

 *  [not1_name](https://wordpress.org/support/users/not1_name/)
 * (@not1_name)
 * [7 years, 4 months ago](https://wordpress.org/support/topic/admin-restrictions-affecting-forms/)
 * I had a lot of attacks from certain IPs and was recommended to restrict access
   to admin by only allowing our IP in the admin htaccess file. However this had
   a really strange side effect that I cannot explain. All our site online forms(
   Ninja Forms), stopped submitting. The send button spinner would just spin. Not
   send. I have no idea why the admin htaccess could affect this. I removed the 
   code and the forms started working again. As I would like to limit admin access,
   please help me understand what happened. The code is below.
 * order deny,allow
    allow from [our IP address] deny from all

Viewing 3 replies - 1 through 3 (of 3 total)

 *  [Edward Caissie](https://wordpress.org/support/users/cais/)
 * (@cais)
 * [7 years, 4 months ago](https://wordpress.org/support/topic/admin-restrictions-affecting-forms/#post-11030356)
 * [@not1_name](https://wordpress.org/support/users/not1_name/) – I would suggest
   pinging the Ninja Forms support team via the plugins forums or directly ([https://wordpress.org/support/topic/get-better-faster-help-here/](https://wordpress.org/support/topic/get-better-faster-help-here/))
   although as is, I suspect the plugin is calling to functions it needs to complete
   its processes in the “admin” side of your site and your `.htaccess` code is blocking
   it (likely as these processes are getting owned by the server’s IP address and
   not yours).
 * You might also consider blocking the offending IP addresses (and, yes, this can
   become a very extensive and hard to manage list in some cases) rather than allowing
   your IP address only.
 * ~Cais.
 *  Moderator [Samuel Wood (Otto)](https://wordpress.org/support/users/otto42/)
 * (@otto42)
 * WordPress.org Admin
 * [7 years, 4 months ago](https://wordpress.org/support/topic/admin-restrictions-affecting-forms/#post-11030715)
 * When you restricted access to the wp-admin, you forgot that some things, like
   form submission, still go through that. Specifically, you need to allow access
   to admin-ajax.php and admin-post.php for plugins that use those to be able to
   work.
 *     ```
       <Files admin-ajax.php>
           Order allow,deny
           Allow from all
           Satisfy any
       </Files>
       ```
   
 * And so on.
 *  Thread Starter [not1_name](https://wordpress.org/support/users/not1_name/)
 * (@not1_name)
 * [7 years, 4 months ago](https://wordpress.org/support/topic/admin-restrictions-affecting-forms/#post-11031721)
 * In case anyone finds this thread, I have posted Ninja forms reply. They do use
   a file in the admin folder to submit forms. So if you lock down your admin files
   to prevent attack, you will break the form submission.
 * “Ninja Forms uses admin-ajax.php to handle the submission go the form data”

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘admin restrictions affecting forms’ is closed to new replies.

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 3 replies
 * 3 participants
 * Last reply from: [not1_name](https://wordpress.org/support/users/not1_name/)
 * Last activity: [7 years, 4 months ago](https://wordpress.org/support/topic/admin-restrictions-affecting-forms/#post-11031721)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
