# .htaccess found in /wp-content/uploads/gravity\_forms

**URL:** <https://community.gravityforms.com/t/htaccess-found-in-wp-content-uploads-gravity-forms/17509>\
**Category:** Get Help\
**Tags:** htaccess, has-ticket\
**Created:** [May 21, 2024, 6:49pm UTC](https://community.gravityforms.com/t/htaccess-found-in-wp-content-uploads-gravity-forms/17509 "2024-05-21T18:49:41Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![jlpeifer](https://avatars.discourse-cdn.com/v4/letter/j/f9ae1b/32.png) [@jlpeifer](https://community.gravityforms.com/u/jlpeifer)\
**Post date:** [May 21, 2024, 6:49pm UTC](https://community.gravityforms.com/t/htaccess-found-in-wp-content-uploads-gravity-forms/17509/1 "2024-05-21T18:49:41Z")

</div>

I want to give GF tech support access to a log file located in “wp-content/uploads/gravity\_forms/logs/” via https (e.g. “[https://yaddayadda.com/wp-content/uploads/gravity\_forms/logs/ajumbledmixofcharacters.txt](https://yaddayadda.com/wp-content/uploads/gravity_forms/logs/ajumbledmixofcharacters.txt)”) but they’re constantly getting blocked because of an .htaccess file that’s located in the parent of this directory.

I’ve tried renaming this .htaccess file, but apparently there’s a cron file or some other scheduled task that recreates it regularly.

Within the .htaccess file itself are the instructions…

```auto
# BEGIN Gravity Forms
# The directives (lines) between "BEGIN Gravity Forms" and "END Gravity Forms" are
# dynamically generated, and should only be modified via WordPress filters.
# Any changes to the directives between these markers will be overwritten.
# Disable parsing of PHP for some server configurations. This file may be removed or modified on certain server configurations by using by the gform_upload_root_htaccess_rules filter. Please consult your system administrator before removing this file.

```

I am not familiar enough with filters to know what to do with this instruction. Can anyone provide input on _what_ kind of instruction needs to be put _where_ so that I can open up access to that logs directory via the filter referenced above?

---

<div class="post-metadata">

**Author:** ![jlpeifer](https://avatars.discourse-cdn.com/v4/letter/j/f9ae1b/32.png) [@jlpeifer](https://community.gravityforms.com/u/jlpeifer)\
**Post date:** [May 22, 2024, 8:51am UTC](https://community.gravityforms.com/t/htaccess-found-in-wp-content-uploads-gravity-forms/17509/2 "2024-05-22T08:51:56Z")

</div>

My apologies to the forum. I’m guilty of not researching better before I posted. The answer, it seems, is explained in the GravityForms online documentation [**found here**](https://docs.gravityforms.com/security/#h-the-htaccess-file).

I added the following to the functions.php file of my theme.

```auto
add_filter( 'gform_upload_root_htaccess_rules', '__return_false' );

```

I don’t know how often these files get regenerated, so I don’t know if the “fix” worked. If not, I’ll follow up again. Otherwise, it’s the work-around I was seeking.

I’m answering my own question in case anyone else runs into the same issue.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex020/uploads/gravityforms1/original/2X/f/fef63f0599c45e0218c30d9f5d7ca8bff9b00189.png) [@system](https://community.gravityforms.com/u/system)\
**Post date:** [May 23, 2024, 8:52am UTC](https://community.gravityforms.com/t/htaccess-found-in-wp-content-uploads-gravity-forms/17509/3 "2024-05-23T08:52:25Z")

</div>

Closed on May 23, 2024, 8:52am UTC

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.
