Hi Derek
It seems you have been following this thread the most. I have been trying to install the FAQ module today and have come up with all the same issues everyone has been having from the 1064 syntax error, duplicate key error and when overcomming that the FAQ sidebox would only work in the left column. As soon as you put it on the right side and hit anythin in the catagory, document box it would come up with a p. error that everyone was getting as well. Just so you all know I have no exp with PHP but have been playing with various ways of installing this today and have come up with the following: Hope it helps you out. If anyone sees what I have done will make a mess of something else please let us know as I have no idea.
Step 1:
Follow the instructions to install the files in the Admin and Include files as per the insatll guide.
Step2:
In order to stop the first error you get when using the cart Install SQL patches to run the faq_manager.sql patch (which is a syntax error) you need to change the last section of the script: Lines 2- 6 and line 8. All the end bits that say (array('true', 'false'),'); change to (array("true", "false"),'); and all the (array('0', '1'),'); change to (array("0", "1"),'); this should sort out the syntax error.
Step 3:
If you have installed a previous version or tried this version already and had problems , you must remove all the FAQ files that were created in the database before going to step 4 or you will get the duplicate error.
Step 4:
before running the scrip you need to go tp MyPHP and to the _configuration table. click on the configuration_group_id, press the edit button or pencil. Now go to the "Null" field and change the "NOT NULL" to "NULL" Click on save
Step5:
You can now go to the admin panel in your Zen cart and go to the Tools Menu and click on "Install SQL patches" In the upload file section at the bottom , browse for the faq_manager.sql you changed and select this file. now click on UPLOAD. The scrip should run fine now without any errors.
Step 6:
Now do as in step 4 above and change the "NULL" back to "NOT NULL"
Step 7: Derek this is where u come in plse
I found that if you goto the tpl_faq_catagories.php in the directory includes/templates/template_default/sideboxes and add to // in front of the code in lines 98,99,100 as shown
//$show_this = $db->Execute("select p.faqs_id
// from " . TABLE_FAQS . " p
// where p.faqs_status = 1 " . $display_limit . " limit 1");
You should be able to place the Sidebox on the right hand side without anymore issue.
I must stress that I have no idea what this piece of code does but once eliminated the side box works. Derek as this is now narrowed down perhaps you or someone else can help. Unfortunately if you are using other languages there is still a graphic issue but probably not to difficult to sort out.
Step8: FAQ Send Button
If you go to the includes/modules directory and edit the faqs_all_listing.php and the faqs_new_listing.php both at around line 122 from zen_image_button('BUTTON_IMAGE_SUBMIT_FAQ', BUTTON_SEND_ALT) change to zen_image_button('button_ask_a_question.gif', BUTTON_SEND_ALT)
This should give you the "Ask a question" button supplied in the module.
I hope this was clear enough for all to achieve. Derek or anyone else please come back on the remmed code above if possible. I will keep testing to see if anything else still goes wrong. Any other feedback would also be appreciated.
Good Luck!!! hope it helps