Welcome to the Question2Answer Q&A. There's also a demo if you just want to try it out.
  • Register
Welcome to the Q&A for Question2Answer.

If you have questions about the platform, click here to ask and please use English.

If you just want to try Q2A, please use the demo, which also grants admin access.

Apr 29: Q2A 1.5.2

facebook login error on my page and question2answer.org too

+1 vote

Dear All,

Facebook login on my page not work.

A get an errors:

Question2Answer fatal error:

Could not create a valid and unique handle from: xx

Stack trace:

require() /chroot/home/xx/html/bug/index.php:31
require() /chroot/home/xx/html/bug/qa-include/qa-index.php:163
qa_check_login_modules() /chroot/home/xx/html/bug/qa-include/qa-page.php:751
check_login() /chroot/home/xx/html/bug/qa-include/qa-page.php:102
qa_log_in_external_user() /chroot/home/xx/html/bug/qa-plugin/facebook-login/qa-facebook-login.php:93
qa_handle_make_valid() /chroot/home/xx/html/bug/qa-include/qa-app-users.php:293

 

How can I solve it?

What I need setup on facebook developers page for working fb login?

Q2A version: 1.5
asked Jan 22 in Plugins by sevoir
I got this message which is different but seems related: Fatal error: Call to undefined function qa_log_in_external_user() in /home/content/c/h/i/chin3983/html/qa/qa-plugin/facebook-login/qa-facebook-login.php on line 84.

Evidently for me, this happened when I was logged into Facebook already (but not into the Q/A) and clicked on the login button and logged in.

1 Answer

0 votes
I've the same error, that's how I fixed it:

1. search the text "Could not create a valid and unique handle from" in q2a codes, you'll find it in qa-include/qa-app-users-edit.php

2. type echo before row $error=$filtermodule->filter_handle($handle, null);

echo $error=$filtermodule->filter_handle($handle, null);

3. Refresh page, I've got error "maximum length is 20 characters". This means that I put big users handle name in function qa_log_in_external_user()

4. Solution is substr( handle, 0, 20) or try to make handle bigger:

mysql> ALTER TABLE `qa_users` CHANGE `handle` `handle` VARCHAR( 30 ) NOT NULL;

in the file qa-db-maxima.php change constant QA_DB_MAX_HANDLE_LENGTH to 30 (for example)
answered Feb 22 by BubkaGob