okay, maybe it's just me or my install, but the unanswered questions block removes questions if they have simply been 'clicked on' and not in fact answered (meaning a user just clicks but doesn't answer, then block updates to now show the question as still unanswered)

Comments

nancydru’s picture

Status: Active » Closed (works as designed)

Yes, that's the way it works and that's why the advice is "if you click, you must answer." Once a user clicks on a question it becomes a published FAQ node. The only way to get it back into the queue is to unpublish it again.

zilla’s picture

oh - so i wrote up a bit about using this in the way in which ostatic.com is doing member questions - anybody can answer a question - in this scenario, based on what you've described, i should simply NOT display that block because otherwise users are gonna think they're looking at 'unanswered questions' and as they click through to read them, if they do NOT answer then they'll be removed from the block...

is there an alternate way to produce the block so that it shows simply any (by quantity) unanswered questions, whether or not they've been clicked? ...or is there a path that could be set via a link to 'all unanswered questions' (similar to /faq showing all - but like that with a filter on unanswered)?...or would that still mean the same thing - once clicked it's marked answered?

would requesting a change for this kind of functionality be a reasonable feature request, or too much of a rewrite? (allow questions to be viewed and NOT answered and so remain unanswered if comment count equals zero)

nancydru’s picture

I am still thinking about your other post. BTW, Ostatic is not Drupal.

To see all the unanswered questions, there is the page that is linked to by the "more" link when there are more questions than you choose to show. That is "http://www.example.com/faq_ask/more" which could be made a menu item. Just as with the block, the user sees the whole question, but if they click it, they have to answer it. They should not even be able to save the question without an answer.

To be more specific about the logic, when a user clicks on the question link, the Faq_Ask module marks the question published (not answered) and transfers to the Faq module. At this point Faq_Ask is totally out of the picture.

However, we are still left with your issue of clicking on a question and having it marked published. I can think of two ways to deal with this: 1) a major rewrite that uses a second content type and replicates much of Faq's code; or 2) Allowing Faq to operate as it does today and come back at the next cron interval and see if it really got answered, if not, leave it as is, otherwise mark it published then. Neither is terribly appealing to me as a user of this module. Complications: 1) Faq now allows extra long questions; this would not only require replicated code, but probably a duplicate database table, which is really unappealing; 2) Depending on your Cron schedule, this could mean a major delay in seeing the answered question. With the feature request to notify the asker of an answer, this delay could be twice as long.

If you can think of other ways to deal with this, I'm open for discussion.

zilla’s picture

i'll definitely mull it over - i wonder if it might be a simple 'show all unanswered' as you mention - as i'm using it now, the recent faq's block does show both answered and unanswered - and that alone may be more than useful enough for a launch

the idea of using cron is great - simply set back - but it does require serious effort

of course, the alternative (complete alternative) is to simple do it without faq at all and use nodes as usual (custom content type perhaps with CCK fields and all of that) and simply style that way...

as for ostatic - yes, it is drupal. http://changingway.org/2008/03/04/ostatic-gigaom-on-open-source/

vkareh’s picture

I think it could be an option in the settings. Let the admin choose whether they want the answer Published at click or at submit. In one of my websites, the "experts" actually go into the question to analyze it and perhaps forward it to others for discussion before even thinking of submitting it. What I did was changing part of the code for the Drupal 5 version so that it's published at submit. Shouldn't be hard to make it an option and port it to D6. I can work on this if you are interested in that functionality.

enboig’s picture

I think #5 is the way to go.

And AFAIK it one way of doing this would be:
1) create the question; and tag it as "unanswered" in a table (a views filter would be nice)
2) when FAQ is edited, using form_alter_hook a checkbox could be added to check is the question is answered.
3) when faq is saved, using nodeapi_hook the question could be marked as answered or again as unansered.

nancydru’s picture

In 6.x-2.x-dev, the faq_ask/unanswered page shows all the unanswered questions as a node list. You may review them and then decide which ones you might want to answer.

All these other suggestions require a major change to the structure and design of Faq_Ask. This module is purely a front-end to FAQ. When you click a question to answer, this module marks the node published and transfers control to FAQ. After that Faq_Ask is totally out of the picture. If someone can come up with a better way to handle things that doesn't change that flow or add any more tables, then go ahead and work up a patch. Otherwise "by design" stands.