Support Forum

Advanced Search
Forum Scope


Match



Forum Options



Minimum search word length is 3 characters - maximum search word length is 84 characters
general-topic
Template Tag Shortcode list
Avatar
Paul Smith
Member
sp_UserOfflineSmall Offline
Jun 6, 2012 - 1:43 am

Hi there,

I want to add SP template tag shortcode to a sidebar linking to the forum home page and maybe including some of the hot topics. What code do I use? Is there a list anywhere?

Paul

Avatar
Yellow Swordfish
Glinton, England
SP Master
sp_UserOfflineSmall Offline
Jun 6, 2012 - 4:04 am

No list yet - we are still working on it - sorry!

You will need to install and activate the SP 'Template Tags' plugin which has them all in. (http://codex.simple-press.com/.....g-plugins/)

If you look on our footer here you will see two being used. A 'Hot Topics' and a 'Recent Posts'. These are available as standard WP style template tags; as ShortCodes and, in the case of Recent Posts, a Widget.

The short code for the hot topics one is 'sp_hot_topics'. We can help you with the options etc., when you are ready...

andy-signature.png
YELLOW
SWORDFISH
Avatar
Paul Smith
Member
sp_UserOfflineSmall Offline
Jun 6, 2012 - 4:34 am

Yellow Swordfish said
No list yet - we are still working on it - sorry!

You will need to install and activate the SP 'Template Tags' plugin which has them all in. (http://codex.simple-press.com/.....g-plugins/)

If you look on our footer here you will see two being used. A 'Hot Topics' and a 'Recent Posts'. These are available as standard WP style template tags; as ShortCodes and, in the case of Recent Posts, a Widget.

The short code for the hot topics one is 'sp_hot_topics'. We can help you with the options etc., when you are ready...

Thanks for the reply. I have installed the plugin already. I wanted to see what shortcodes are available so that I could decide which to use. I dodn't want to bother anyone on the forum if there was a list of shortcodes I could refer to. Is there such a list?

Avatar
Yellow Swordfish
Glinton, England
SP Master
sp_UserOfflineSmall Offline
Jun 6, 2012 - 6:22 am

No as I said - no list yet. Sorry but sadly the codex is behind us - it is a matter of finding the time! But it is getting written up slowly.

You could take a look at the code. The file /template-tags/sp-template-tags-plugin.php does list all of the shortcodes and tags available (look for the 'add_shortcode' statements).

We are more than happy to explain any you may be interested in and to help you with using them.

andy-signature.png
YELLOW
SWORDFISH
Avatar
Paul Smith
Member
sp_UserOfflineSmall Offline
Jun 6, 2012 - 7:15 am

Thanks for the information so far. Can you help me out with the process of adding recent posts to a sidebar? I tried adding the hot topics shortcode to a text widget but that didn't work, but adding the shortcode to a post did. What shortcodes work with a sidebar widget and how do I get them to work?

Paul

Avatar
Yellow Swordfish
Glinton, England
SP Master
sp_UserOfflineSmall Offline
Jun 6, 2012 - 7:33 am

I will need to ask Steve (Mr Papa) about the shortcode usage - who will be around later.

But if you want to use the Recent Posts tag why not just use the supplied SP widget - it uses the same code as the shortcode and tag. You will find it in your WP widgets admin panel.

andy-signature.png
YELLOW
SWORDFISH
Avatar
Mr Papa
Simi Valley, CA
SP Master
Free Members
sp_UserOfflineSmall Offline
Jun 6, 2012 - 8:34 am

all the shortcodes work in the sidebar though they might not be ideal
for that. certainly the recent posts is just fine for that. make sure
they are outside of php tags. please post your entire content of that
particular sidebar widget so we can review.

Avatar
Mr Papa
Simi Valley, CA
SP Master
Free Members
sp_UserOfflineSmall Offline
Jun 6, 2012 - 8:34 am

all the shortcodes work in the sidebar though they might not be ideal
for that. certainly the recent posts is just fine for that. make sure
they are outside of php tags. please post your entire content of that
particular sidebar widget so we can review.

Avatar
Paul Smith
Member
sp_UserOfflineSmall Offline
Jun 6, 2012 - 11:57 am

Mr Papa said
all the shortcodes work in the sidebar though they might not be ideal
for that. certainly the recent posts is just fine for that. make sure
they are outside of php tags. please post your entire content of that
particular sidebar widget so we can review.

I have to be honest, I don't have a clue what I'm doing when it comes to adding the content to the sidebar widget. Can you give me an example of what the contents should look like in order to display "hot topics" for example?

Avatar
Paul Smith
Member
sp_UserOfflineSmall Offline
Jun 6, 2012 - 12:11 pm

Yellow Swordfish said
I will need to ask Steve (Mr Papa) about the shortcode usage - who will be around later.

But if you want to use the Recent Posts tag why not just use the supplied SP widget - it uses the same code as the shortcode and tag. You will find it in your WP widgets admin panel.

The Recent Post widget is now up and running. Thanks for the suggestion.

Forum Timezone: Europe/Stockholm
Most Users Ever Online: 1170
Currently Online:
Guest(s) 1
Currently Browsing this Page:
1 Guest(s)
Top Posters:
Mr Papa: 19448
Ike: 2086
Brandon: 864
kvr28: 804
jim: 650
FidoSysop: 577
Conrad_Farlow: 531
fiddlerman: 358
Stefano Prete: 325
Member Stats:
Guest Posters: 620
Members: 17365
Moderators: 0
Admins: 4
Forum Stats:
Groups: 7
Forums: 17
Topics: 10128
Posts: 79626