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 Q2A Core by

I copy all files in directory 

mysite.com/qa

rename file qa-config-example.php in qa-config.php

line: define('QA_WORDPRESS_INTEGRATE_PATH', '/PATH/TO/WORDPRESS');

change: 

define('QA_WORDPRESS_INTEGRATE_PATH', '/');

and: define('QA_WORDPRESS_INTEGRATE_PATH', '/public_html');

and: define('QA_WORDPRESS_INTEGRATE_PATH', 'http://mysite');

and: define('QA_WORDPRESS_INTEGRATE_PATH', 'http://mysite/public_html');

and: define('/'); and: define('http://mysite'); and other variants

Nothing works....

when open in browser mysite/qa, there write: 

Warning: mysql_connect() [function.mysql-connect]: Access denied for user 'your-mysql-usern'@'localhost' (using password: YES) in/home/abicte/public_html/qa/qa-include/qa-db.php on line 66

Could not establish database connection. Please check the username, password and hostname in the config file, and if necessary set up the appropriate MySQL user and privileges.

How to specify the path to the wordpress?

wordpress is the root of the site, and Q&A need install in directory

2 Answers

0 votes
by

It needs to be the full file path on disk of your WordPress installation, perhaps starting with /var or something like that.

+2 votes
by

go to your to your index.php file and write this at the end of the file before ?>

echo realpath(dirname(__FILE__));

then refresh and at the bottom of your website page you'll be able to see the real path that you have to write there as /PATH/TO/WORDPRESS

one more thing, bare in mind that the whole define('QA_WORDPRESS_INTEGRATE_PATH', '/PATH/WORDPRESS/'); IS in a comment line so you have to put the */ before the define line.

It's worked for me just fine, i hope you'll manage it.

by
answered Jul 17, 2012 by mihai_blueeyez  your solution worked for me also, thanks !!
...