The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
how to make an activity list with php
I am trying to make an activity list sidebar wth php and sql and I have been trying to find a solution for days now....
I would like for it to contain the same content as the activity stream(activity.php) could anyone advise me on how to structure a query to retrieve activity stream info with the respective format so that I can echo it dynamically in a while or foreach loop. Thanks a ton in advance |
#2
|
||||
|
||||
Are you wanting to create a new forum block to contain this information?
I would begin with a query of the "activitystream" table, sorting by dateline in descending order, so that the newest activity is listed first. You will likely want to limit the result to a maximum number of rows. Then, within a while loop that retrieves each row from the returned array, I would use a switch statement on the typeid to determine which table needs to be queried to get the desired content and base the format of that activity accordingly. |
#3
|
|||
|
|||
Where is the serialized format of each activity type located....eg the text that goes with the values retrieved from the activity stream to make complete sentances?
Thanks |
#4
|
||||
|
||||
Your "activitystreamtype" table should look like this:
So, when you are retrieving the rows returned by the query of the "activitystream" table, you can base your actions on the "typeid" column. This will indicate which table you need to query to get the content for that activity item. |
#5
|
|||
|
|||
Thanks for the reply Mark
Additionally : How would I add an event to activity? Thanks |
#6
|
||||
|
||||
I'm not sure I follow...what kind of event is not showing up in the activity stream?
|
#7
|
||||
|
||||
Quote:
I thought I had seen an article on this, but I couldn't find it right now |
#8
|
|||
|
|||
Quote:
etc. |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|