WebSite X5Help Center

 
Stephen L.
Stephen L.
User

Edit .htaccess file prior to upload to Host  en

Autor: Stephen L.
Visitado 74, Seguidores 1, Compartilhado 0  

This Question relates to the .htaccess file and is a tangent from a previous Question. My goal is to edit the .htaccess file before uploading to my hosting service. I already know I can update the file directly on the Host’s File Manager, but the problem with that is, I would assume, the edits would disappear the next time I uploaded my Project to the Host because the existing .htaccess file would be overwritten. Is that assumption incorrect?

Second issue. I know Website X5 automatically generates the .htaccess file. Where does the data exist from which it generates the HTML for the .htaccess file's contents? If I know that, could I then make edits to the htaccess file from there?

Third. I’m able to find the htaccess file listing on the FTP section in the Export Section (Step 5), but I can’t actually open the file contents for editing purposes from there. In fact, I have never been able to locate the file anywhere in the Website X5 generated files for the project.

So, if anyone can help me reach my goal as stated above, I would be grateful.

Publicado em
5 RESPOSTAS
Daniel W.
Daniel W.
User
Usuário do mês DE

If additional code is added to the .htaccess file after the WebSite X5 code, then the additional code should be preserved.

I added additional code to the .htaccess file on my brother's website a while ago, and it's still there even after several "Exports of the website to the Internet".

Ler mais
Publicado em de Daniel W.
Stephen L.
Stephen L.
User
Autor

But was the edit made on the host .htaccess using File Manager or was it made on his website software and then uploaded to the host?

Ler mais
Publicado em de Stephen L.
Daniel W.
Daniel W.
User
Usuário do mês DE

I uploaded the .htaccess file to my hard drive via the FTP window of WebSite X5 (it also works with an external FTP program), added my own code below using the Windows editor, and then uploaded it again.

Ler mais
Publicado em de Daniel W.
Daniel W.
Daniel W.
User
Usuário do mês DE

After editing the .htaccess file in the Windows editor, it can also be saved in TXT format and uploaded to the web server, where it can be renamed to .htaccess with a period at the beginning and without the file extension (.txt).

Ler mais
Publicado em de Daniel W.