Welcome to the Question2Answer Q&A. There's also a demo if you just want to try it out.
+13 votes
in Plugins by
edited by

This is a little widget that displays your forum's recent events. It needs the event logger enabled.

Download: https://github.com/echteinfachtv/qa-recent-events-widget

Screenshot Position Sidepanel:



Screenshot Position Main:


Question2Answer Recent Events Widget v0.1


This plugin for Question2Answer displays the newest events of your q2a forum in a widget.


  • considers questions/answers/comments/best-answer-selects as events to show
  • needs plugin "Event Logger" enabled, check Admin > Plugins >Event Logger >options (tick "Log events to qa_eventlog database table")


  1. Install Question2Answer
  2. Get the source code for this plugin from _github, download directly from the project page and click Download
  3. Extract the files to a subfolder such as q2a-revent-events-widget inside the qa-plugins folder of your Q2A installation.
  4. Change language strings in qa-recent-events-widget-lang.php
  5. Navigate to your site, go to Admin -> Plugins on your q2a install.
  6. The event logger plugin must be active, see option Log events to qa_eventlog database table.
  7. Then go to Admin >Layout >Available widgets, and add the widget "Recent Events Widget" where you want it to appear


This is beta code. It is probably okay for production environments, but may not work exactly as expected. You bear the risk. Refunds will not be given!

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.


All code herein is OpenSource. Feel free to build upon it and share with the world.

About q2a

Question2Answer is a free and open source platform for Q&A sites. For more information, visit: www.question2answer.org

Final Note

If you use the plugin: + Consider joining the Question2Answer-Forum, answer some questions or write your own plugin! + You can use the code of this plugin to learn more about q2a-plugins. It is commented code. + Thanks!


Still same problem- check my site: http://qstacks.com/ I will keep it installed for few more minutes until you check and reply
The recent event is in the sidebar
For your Info:
The tooltip shows, when the site is half loaded on browser, but when the site is loaded completely, then the problem comes. So, this might be the malfunction or conflict between 2 plugins or 2 javascripts.
Ah... forgot to add the CSS for the tooltip. Now added to qa-recent-events-widget.php Just update this file again: https://github.com/echteinfachtv/qa-recent-events-widget/blob/master/qa-recent-events-widget.php
Yes, Now working perfect! It will be far better, if it had the live ajax updation! Thanks for the plugin!

3 Answers

+1 vote

Shows why the question mark? Russian language.

edited by
This is probably an html-utf-encoding issue, I added a utf8_encode() to return the $listAllEvents from qa-plugin.php. Could you try the new file and tell me if it works with cyrillic now: https://github.com/echteinfachtv/qa-recent-events-widget/blob/master/qa-plugin.php

Btw, I checked your site http://voprosof.net/ - I see everything correctly displayed.
edited by
I found the issue and tested it: substr() needs to be told that we have a UTF8 string, e.g.: $qTitleShort = mb_substr($qTitle,0,22,'utf-8');

I update the plugin in a couple of minutes.
edited by
Thank you very much, the latest version helped fix the problem. with previous ENT_QUOTES, 'UTF-8' is not quite help.
0 votes
Hi i tested your plugin and it works fine but i have some questions:

1. Can you make it autorefresh with ajax technology?

2. I want to hide the time before the event and add the user avatar image. How i can achieve that ?

Thanks in advance and waiting for your answers
It needs hardcoding ?
Try to read and understand the plugin code how it retrives the information .
implement JQuery ajax functionality with qa funcitons to get the same information at a certain time interval
after getting the data update the DOM element using JQuery
Enjoy . I think it is not so tough as the funhctionality is already there just you need to implement the ajax features with some code tweaks .
0 votes
Is it possible to display only the content which user has favorited( like Q&As and tags)
no, this is not implemented.