I'm using Wordpress. I'm trying to add Recent Topics or Recent Posts to my sidebar widgets.
I added this to the top of header.php in wordpress. <?php require("SSI.php"); ?>
In the siderbar widgets, I have a few instances where I'm calling stuff via SSI.php from my forums.
I need to get the Recent Topics or Recent Topics formatted properly. I'm using <?php ssi_recentTopics(); ?> in the widget for topics, as an example.
Please see the sidebar at https://www.TMLfans.ca (https://www.tmlfans.ca)
Thoughts?
You want to use the output method property
https://www.simplemachines.org/community/ssi_examples.php
Which you can set to return an array in php which you can then format how you wish.
Unless I'm missing something (which is very possible), I was using that?!
You were using the defaults you would do something like this
$data = ssi_recentTopics(8,null,null, 'return');
print_r($data);
That shows the contents of the array which you can then format as needed.
Ahhh, thanks. I'll try to figure that out. Cheers!
Thanks vbgamer45.
It's odd that the first four widgets on the TMLfans.ca sidebar that are using SSI.php have output formatted perfectly. And they're just using standard calls:
<?php ssi_boardStats(); ?>
<?php ssi_whosOnline(); ?>
<?php ssi_topTopicsReplies(); ?>
<?php ssi_topBoards(); ?>
Sorry, I thought I understood this better than I obviously do ;)
It does depend on theme and how it is display. Recent topics is normally very wide which is why it does not look good in your sidebar.
Quote from: vbgamer45 on November 21, 2018, 10:18:35 PM
It does depend on theme and how it is display. Recent topics is normally very wide which is why it does not look good in your sidebar.
That makes sense. It is really wide.