Is there a way to to upload .htaccess file to local host directories?

  • Welcome to Babiato Forum! All Resources are 100% clean and Safe to Use

S

serplord

Guest
Usually I can upload via ftp or directly from cpanel to a remote/live server but how can I upload the .htaccess files to inner directories within a local development site?

Thanks
 

Mrsam_1

Well-known member
Administrative
Trusted Seller
Jul 25, 2018
57,189
62,432
120
Usually I can upload via ftp or directly from cpanel to a remote/live server but how can I upload the .htaccess files to inner directories within a local development site?

Thanks
Just copy and paste the files into the directories on your local machine using File Explorer?
 
  • Like
Reactions: serplord
S

serplord

Guest
Just copy and paste the files into the directories on your local machine using File Explorer?

OK thanks
Just to clarify what it is i'm trying to achieve here - i'm trying to disable php execution. It was always recommended that I add a .htaccess file with:
<Files *.php>
deny from all
</Files>
into the /wp-includes/ and /wp-content/uploads/ sub-directories.

I have simply copied and pasted the file seperately into the two above directories like you've kindly suggested.

I can see now I have a main .htaccess file with all the autogenerated stuff on it and now these two additional files i've created. I'm only a beginner so i'd be really thankful if anyone can tell me:
- Is there any reason why what i've done above will not work? I'm not a php scripter so don't know how to test if php execution has been disabled in these directories or not.
- Is there anyway I can harden my backend further based on the above implementation?
 
Last edited by a moderator:

About us

  • Babiato Forum - The webmaster community has been around for many years and pride ourselves on offering unbiased, critical discussion among people of all different backgrounds. We are working every day, updating Daily resource to make sure our community is one of the best.

Quick Navigation

User Menu