Welcome to the Question2Answer Q&A. There's also a demo if you just want to try it out.
0 votes
3.1k views
in Q2A Core by

after installing new version i m getting the error - The config file could not be found. Please read the instructions in qa-config-example.php.

1 Answer

0 votes
by
rename qa-config-example.php to qa-config.php and fill database details it should work.
by
i have already done rhat, but still getting the same error. All the database details are correct
by
Do you want to post a link so I can take a look?
by
Hi Gidgreen,

The following is the link of the website:

http://www.managementstudyguide.com/qa

Just to give you some more idea.

This started happening after i installed the updated version.

Also, when I installed the first version there were some problems which I had to correct as you advised.

I have also made the same corrections after installing the new version.

Following is the link of the solution that you provided me last time.

http://www.question2answer.org/qa/599/installation-error#600

Please let me know what should I do next.

Thanks a ton for all your help and support.

Himanshu
by
OK, we will try debugging the same way. In qa-base.php, insert this at the top:

echo __FILE__."\n";
echo QA_BASE_DIR.'qa-config.php';

Then let me know and I'll take a look.
by
After inserting the above 2 lines, now i m getting the following error:

C:\inetpub\vhosts\managementstudyguide.com\httpdocs\qa\qa-include\qa-base.php C:\inetpub\vhosts\managementstudyguide.com\httpdocs/qa-config.phpThe config file could not be found. Please read the instructions in qa-config-example.php.
by
Thanks. It seems your server is setting $_SERVER['SCRIPT_FILENAME'] differently from Apache, and this is tripping Q2A up. You should be able to fix this by changing the first line in qa-index.php to:

define('QA_BASE_DIR', dirname(__FILE__).'/');
by
Hi,

I have made the above changes but still getting the same error - "C:\inetpub\vhosts\managementstudyguide.com\httpdocs\qa\qa-include\qa-base.php C:\inetpub\vhosts\managementstudyguide.com\httpdocs/qa-config.phpThe config file could not be found. Please read the instructions in qa-config-example.php."
by
In this case, I'm not sure what is happening, but you can simply hard-code the root path as follows:

define('QA_BASE_DIR', 'C:\inetpub\vhosts\managementstudyguide.com\httpdocs\qa\');

You should also remove the two echo statements you added earlier, since these were just for the purpose of debugging.
by
Hi Gidgreen,

I was able to fix the error, but there are some more issues.

Now I am able to get the initial page with all the questions, but whenver i click on - Ask a Question', or 'Login' etc it says - No Input File Specified.

The following page works

http://www.managementstudyguide.com/qa/?qa=

But, when i click on login, it takes me to -

http://www.managementstudyguide.com/qa/index.php/login?qa=login&to=%3Fqa%3D

Which says - No Input File Specified.

But if i manually type the following link, it takes me to login window

http://www.managementstudyguide.com/qa/?qa=login

 (if i type - "register" after "?qa=", it takes me to register window...so on and so forth).

similarly all links work if typed just after "?qa=". But when we click on the LOGIN or REGISTER buttons - there is a different url and it does not work.

I also want to know one more thing, I want to include - LOGIN and REGISTER buttons on other static pages of my site, can you tell me the script or code that i can use and copy in my HTML files and get these options if possible,

Thanks a lot for all your help
Himanshu
by
Hi,

Please can anyone help me on the above mentioned matter.

Thanks
by
It seems like paths are being added twice for you, in two different ways, which should never happen. Have you made any other changes to the source code apart from the QA_BASE_DIR definition? If so please try undoing them.
by
thansk for your response

I also want to know one more thing, I want to include - LOGIN and REGISTER buttons on other static pages of my site, can you tell me the script or code that i can use and copy in my HTML files and get these options if possible,
by
Hi,

please can you let me know if there is an easy way to include login and register button on other HTML pages of my website.

Thanks
Himanshu
...