Jump to content

PW doesn't see Templates in site/templates


kuba2
 Share

Recommended Posts

Hello

I installed PW on my server and linked it to an existing database.

I copied existing templates on the server into site/templates, but when I login to the backend in PW the templates do not appear. I can add them ( add new ) , but I want to duplicate an existing website and usually when I copied .php files in site/templates they would appear as templates in the backend.

 

Has something changed with the new PW?

 

I am very confused right now

Thanks for any help

Link to comment
Share on other sites

Thanks

I have another issue

A website I made has suddenly a "404 Not Found" message and I can't login to my backend.

I changed only the password to the database, but put the new one into the config.php file.

PW did an update....is it possible, that because of the update I can¨t login anymore?

 

It is strange and I have no idea what is going on.

 

Link to comment
Share on other sites

The template files in /site/templates are for the frontend. The templates in the backend are created in the Processwire backend and are written into the database. You then assign the frontend template to the backend template.

If you have no templates in your backend appearing, it means that they are not found in the database. So your problem may be the database.

Link to comment
Share on other sites

7 minutes ago, kuba2 said:

Thanks

I have another issue

A website I made has suddenly a "404 Not Found" message and I can't login to my backend.

I changed only the password to the database, but put the new one into the config.php file.

PW did an update....is it possible, that because of the update I can¨t login anymore?

 

It is strange and I have no idea what is going on.

 

Did you have a look at https://processwire.com/docs/start/install/upgrade/ for the upgrade?

I suggest you add 

$config->debug = true;

to your config.php to get more specific alerts.

Link to comment
Share on other sites

13 minutes ago, kuba2 said:

I installed a new PW on the server and liked it to the existing database.

Could it be, that it changed/deleted something in the existing database?

If you used the install process at some point there appears a message, that the database has fields that get overwritten. In fact it is very red and clear. If you followed the process through, you deleted your existing templates in the database. Time to import a database backup I guess.

Link to comment
Share on other sites

If you want to move an existing PW site to another server I suggest http://modules.processwire.com/modules/process-export-profile/. I just used it for a site and it worked perfectly, copied all files, database, templates, modules and assets. And it's just about fool proof simple.

I used Soma's install script (https://processwire.com/download/core/), easiest way to get going.

  • Like 1
Link to comment
Share on other sites

On 1/14/2019 at 9:34 PM, psy said:

@kuba2 after copying your files to the new location, did you change the $config->httpHosts array so PW knows were to look for the files?

Yes I did. I deleted my templates in the database. 

Most elaborate and unnecessary way to learn about databases i guess

😉

  • Like 2
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...