Jump to content
TNG Community

Cannot connect to admin panel anymore...


stillman

Recommended Posts

Bonjour,

I'm developing my TNG v.12 site with MAMPPRO 4 locally.
I made changes yesterday and today I can not access the admin panel anymore.
I connect well to my local site but as soon as I enter a user with his password (even as an administrator) the connection process blocks
The page called ../processlogin.php blocks and sends me a blank page.
I do not understand why because everything seems to be OK

In fact I cannot login anymore to my website as a user aven as administrrator.

I am not abble to find the solution myself, so could you help me ?

Great thanks in advance

 

Link to comment
Share on other sites

Chris Lloyd

I would expect that you have access to the DB - try access the users table and adding a new admin user directly into the table. That may allow you to get back into the site.

Link to comment
Share on other sites

19 hours ago, stillman said:

The page called ../processlogin.php blocks and sends me a blank page.
I do not understand why because everything seems to be OK

If this is a local site, you should be able to look at the PHP error log and post what the error is here.

Link to comment
Share on other sites

19 hours ago, stillman said:

Bonjour,

I'm developing my TNG v.12 site with MAMPPRO 4 locally.
I made changes yesterday and today I can not access the admin panel anymore.
I connect well to my local site but as soon as I enter a user with his password (even as an administrator) the connection process blocks
The page called ../processlogin.php blocks and sends me a blank page.
I do not understand why because everything seems to be OK

In fact I cannot login anymore to my website as a user aven as administrrator.

I am not abble to find the solution myself, so could you help me ?

Great thanks in advance

 

If you have only created one or two users, then perhaps easier might be to go to the tng_users table and delete all of the users from there. Then you can log in and create a New Admin user.

As Ken said too, you should be able to find an error listed in the error_log for your site.

Roger

Link to comment
Share on other sites

Thanks to all of you !

I can tell you that I am quiet sure that it is not a problem of user.

My local site is a mirror of my online website (and same configuration and same mods). The files are strictly the same and I can connect to my online site but not anymore on the local one...???

I am really stupid because I have not even thought to look the PHP error log (forgive me Ken and Roger 😕)

So, here is the PHP error log. Those two files are stricly the same on local and online wesite....???

If it can help, when it's happened I was trying to adjust the configuration of my fourth menu with custom_menu_hook_v10.0.0.0.cfg

Chrsitophe

local_php_error_log.rtf

Link to comment
Share on other sites

Thank you Ken,

I have verified my customconfig.php on your link and the result is "No syntax errors detected in CODE"

I do not understand ...

Link to comment
Share on other sites

Well there are 2 files you cannot copy from host to WampServer or in the other direction - config.php and subroot.php if you use Config Path to move your configuration files elsewhere.

If you can access the Admin screen go to Setup > General Settings and change your local TNG root path.  Save the file.  Re-open it and update your Genealogy URL to point to your local server and save again.

If you cannot access the Admin screen, open the config.php file in an ASCII text editor like Notepad++ (not any of the Microsoft editors) and change the $rootpath

$rootpath = "";

You should now be able to open it in TNG admin,  If not then we need to know what error you are getting on your screen and PHP error log

Just copy and paste it directly in the post using the <> icon in the edit bar

 

Link to comment
Share on other sites

 Marqueur - 28 juin 2018 14:50:56
[28-Jun-2018 14:51:03 Europe/Paris] PHP Warning:  session_start(): Cannot send session cookie - headers already sent by (output started at /Applications/MAMP/htdocs/potie/gene/config/customconfig.php:114) in /Applications/MAMP/htdocs/potie/gene/begin.php on line 26
[28-Jun-2018 14:51:03 Europe/Paris] PHP Warning:  session_start(): Cannot send session cache limiter - headers already sent (output started at /Applications/MAMP/htdocs/potie/gene/config/customconfig.php:114) in /Applications/MAMP/htdocs/potie/gene/begin.php on line 26
[28-Jun-2018 14:51:03 Europe/Paris] PHP Warning:  Cannot modify header information - headers already sent by (output started at /Applications/MAMP/htdocs/potie/gene/config/customconfig.php:114) in /Applications/MAMP/htdocs/potie/gene/ajx_login.php on line 11
[28-Jun-2018 14:51:06 Europe/Paris] PHP Warning:  session_start(): Cannot send session cookie - headers already sent by (output started at /Applications/MAMP/htdocs/potie/gene/config/customconfig.php:114) in /Applications/MAMP/htdocs/potie/gene/begin.php on line 26
[28-Jun-2018 14:51:06 Europe/Paris] PHP Warning:  session_start(): Cannot send session cache limiter - headers already sent (output started at /Applications/MAMP/htdocs/potie/gene/config/customconfig.php:114) in /Applications/MAMP/htdocs/potie/gene/begin.php on line 26
[28-Jun-2018 14:51:06 Europe/Paris] PHP Warning:  Cannot modify header information - headers already sent by (output started at /Applications/MAMP/htdocs/potie/gene/config/customconfig.php:114) in /Applications/MAMP/htdocs/potie/gene/processlogin.php on line 149

(I do use subroot.php and the link is ok, I never change it))

Link to comment
Share on other sites

2 hours ago, stillman said:

(I do use subroot.php and the link is ok, I never change it))

How can that link be OK.  You are not on your host.  I suspect that you are getting errors in that the subroot location is not reachable.  The PHP error posted does not show the error that is being outputted that is causing the PHP error shown.

I do now know Apple products, but on Windows WampServer my root path is

D:/wamp/www/tng/

and config path is

D:/wamp/config/tng/

Try editing subroot.php so that it has the TNG default code, or copy the file from a TNG zip file extract.

Edit your config.php file so that it has

$rootpath = "";

TNG will determine your root path when you initially access.  So once you can get into Admin.  Go to Setup > General Settings and the root path will contain the correct value.

You also need to edit your Genealogy URL so that it points to your local computer.  Mine is

http://localhost/tng

I don't know what it needs to be on the MacIntosh

Link to comment
Share on other sites

Christophe,

Did you resolve this problem, or just abandon it to open new problems on other topics?

It is difficult to debug problems on a local computer.

Link to comment
Share on other sites

Hi Ken,

My answer is no I did not give up.
I would like to understand what could happen because I like to learn from my mistakes and understand.

That said, it does not matter much because my problem is right on my local computer.

I have made a local backup of my online site for security and I will see if I can reproduce my problem and try to determine where it may come from. I suspect a formatting error of one of my original files. If I find I would tell you the cause so that it can eventually be used by others.

Thanks Ken

Regards

Christophe

Link to comment
Share on other sites

Did you clear the TNG root path in config.php and Config Path in subroot.php as I recommended?

Link to comment
Share on other sites

Yes Ken, I have done as you tel

Message :

Error: TNG is not communicating with your database. Please check your database settings and try again. Settings can be found under Admin/Setup/General Settings/Database, or at the top of your config.php file.

It seems normal isn't it ?

Link to comment
Share on other sites

Ok, now we are starting to get somewhere.  Your database name on your local computer will not be the same as your production host database.

If you have not yet created a database on your local computer, see Database - Creating  If you have created a database for your MAMP environment, then see Setup - Database and expand the Local Server section

Link to comment
Share on other sites

OK, but your database connection user and password will be different on your MAMP environment than it is on your host.  So you need to update the config.php file to show the correct connection username / password

Link to comment
Share on other sites

My site is private. We must have an identifier to connect and view the content.
There is no return on the login page for the user to declare ....
just a blank page !

Link to comment
Share on other sites

24 minutes ago, stillman said:

My site is private. We must have an identifier to connect and view the content.
There is no return on the login page for the user to declare ....
just a blank page !

Sorry, I am not understanding what you are trying to say.  Are you saying that you still cannot login? 

Based on your previous reply I thought you were up and running on your MAMP server.

Link to comment
Share on other sites

Yes Ken.

I do confirm that my problem was on my MAMP environnement and any user cannot connect to the local site (that is a mirror site).

BUT

On my MAMP environnement, I took the begin.php file from the package of TNG original files (who seems to be strictly similar) and...I have manage to connect on the admin panel of my local site....

I do not understand at all what happen.

May we consider that the problem is solve ? in a certain way yes but I don't how and why !!!

Link to comment
Share on other sites

When you copy files from your host to your MAMP environment or in the other direction, there are 2 files that should not be copied - subroot.php that identifies where your configuration files are, and config.php which defines where your TNG database and other parameters that will be different on a local computer than on a hosted web site. 

mapconfig.php should not be copied either if you have a Google Maps API key which will be different

Users should not be able to login to your local computer.

Link to comment
Share on other sites

Thanks Ken, I do understand.

In fact I am using "Beyond compare" for comparing and editing folders or files between my MAMP environnement and my hoster.

I can see easily the difference between the two environnements.

I suspect a problem of "encodage de fichier" one file was in UTF-8 UNIX the other one in UTF-8 PC, I am not qualified to know if it could be the cause of the trouble.

And don't worry Users could not login on my local computer, it is because my english is not fluent enough for explaination.

In this case that was a local mirror site from the site online, so I have all the users from the on line website in the TNG base.

Great thanks for your help and wish you a good week end.

Kind regards

Christophe

Link to comment
Share on other sites

Hi Ken

Pour que les choses soient claires, voici la procédure que je suis quand je fais une sauvegarde de mon site en ligne dans mon environnement local sous MAMP :

  1. Copie de mon répertoire complet TNG avec Filezilla sur mon répertoire local crée sous Mamp
  2. Export de ma base de donnée chez mon provider (OVH) via PhpMyAdmin
  3. Création et Import de ma base de donnée (dans la bonne colation) en local sous MAMP via PhpMyAdmin
  4. Modification des fichiers customconfig.php et subroot.php avec Beyond Compare (affectation des changements de répertoire et des accés à la base de données)
  5. Lancement de TNG pour accéder à la page d'accueil : Pas de probléme!

Je vois la page d'accueil, j’accède à tous les pages Publiques mais si je veux me connecter en tant qu'utilisateur pour voir les autres pages réservés aux seuls utilisateurs enregistrés ou pire au menu administrateur...
Dés que je cliques sur le bouton connection, j'ai bien la fenêtre de connection qui s'affiche, je mets mon identifiant Administrateur et mon mot de passe, le script se lance et bloque sur le fichier processloging.php avec comme résultat une belle page blanche ???

Je tiens à préciser que depuis plus d'un an je procède de la sorte et que je n'ai jamais eu de problème... jusqu'à maintenant.
J'ai aussi essayer de créer un nouveau utilisateur avec les droits administrateurs au cas ou...même résultat.

Dernier test effectué : ouverture avec un éditeur du fichier begin.php et changement de $requirelogin = "1"; en $requirelogin = "0"; pour voir ce qui se passe...

Magique ! j'ai accés à tout mon site en local, tous les liens fonctionnent ce qui me semble normal.
Ce qui prouve bien que ce n'est pas un problème de chemin ou d’accès à ma base!!!
Sinon je n'aurais aucun affichage.

Je décide donc de cliquer sur le bouton "Connexion", fenêtre de connexion utilisateur, remplissage etc. ok et enfin "envoyer" = page blanche et blocage sur le fichier processlogin.php

J’espère ne pas vous avoir ennuyé avec ce long descriptif que j'imagine nécessaire pour comprendre ce qui se passe.

En ce qui me concerne comme je n'y connais rien, je suis incapable de comprendre pourquoi la connexion d'un utilisateur bloque et encore moins comment y remédier.

Je vous remercie pour votre patience et vos solutions éventuelles

Google translate
To make things clear, here is the procedure that I am when I make a backup of my website in my local environment under MAMP:

  1. Copy of my complete TNG directory with Filezilla on my local directory created under Mamp
  2. Export my database to my provider (OVH) via PhpMyAdmin
  3. Creation and Import of my database (in the good cola) locally under MAMP via PhpMyAdmin
  4. Modify the customconfig.php and subroot.php files with Beyond Compare (assigning directory changes and access to the database)
  5. Launch of TNG to access the homepage: No problem!

I see the home page, I access all Public pages but if I want to log in as a user to see the other pages reserved for registered users only or worse to the administrator menu ...
As soon as I click on the connexion button, I have the connexion window that appears, I put my Administrator ID and my password, the script starts and hangs on the file processloging.php resulting in a beautiful blank page ???

I want to point out that for more than a year I have been doing this and that I have never had a problem ... until now.
I also try to create a new user with administrator rights in case ... same result.

Last test performed: opening with a begin.php file editor and changing $ requirelogin = "1"; in $ requirelogin = "0"; to see what happens: Magic! I have access to all my site locally, all links work what seems normal.
Which proves that it is not a problem of path or access to my base!
Otherwise I would have no display.

So I decide to click on the "Connection" button, user login window, filling etc. ok and finally "send" = blank page and blocking on file processlogin.php

I hope I did not bother you with this long description that I imagine necessary to understand what is happening.

As far as I'm concerned, I can not understand why a user's connection blocks, let alone how to fix it.

Thank you for your patience and your possible solutions

 

 

 

Link to comment
Share on other sites

35 minutes ago, stillman said:

Pour que les choses soient claires, voici la procédure que je suis quand je fais une sauvegarde de mon site en ligne dans mon environnement local sous MAMP :

  1. Copie de mon répertoire complet TNG avec Filezilla sur mon répertoire local crée sous Mamp

Christophe,

combien de fois dois-je indiquer que vous ne devez pas copier 2 fichiers - config.php and subroot.php

Le fichier subroot.php indique où se trouvent les fichiers de configuration et le fichier config.php indique les paramètres propres à votre site MAMP local ou à votre site serveur hôte.

Si vous copiez ces 2 fichiers, vous aurez toujours des problèmes et vous serez en mode de restauration  sur votre ordinateur local ou sur votre hôte.

How many times do I have to indicate that you cannot copy 2 files - config.php and subroot.php

The subroot.php file indicates where the configuration files reside and the config.php file indicates the parameters unique to your local MAMP or host server site

If you copy those 2 files you will always have problems and be in a recovery mode either on your local computer or on your host

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...