Welcome to the Question2Answer Q&A. There's also a demo if you just want to try it out.
+1 vote
2.0k views
in Plugins by

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
by
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.

2 Answers

0 votes
by
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)
0 votes
by
I encountered the same error in V1.8.

The reason was that user's surname (Login using Google) was defined under:

Administration center - Users:
Disallowed usernames - separate by spaces or commas:
...