Wordpress Themes - WP Forum at BFA
There will be no more development for Atahualpa (or any other theme), and no support. Also no new registrations. I turned off the donation system. I may turn the forum to read only if it gets abused for spam. Unfortunately I have no time for the forum or the themes. Thanks a lot to the people who helped in all these years, especially Larry and of course: Paul. Take care and stay healthy -- Flynn, Atahualpa developer, Sep 2021

Wordpress Themes - WP Forum at BFA » WordPress Themes » Atahualpa 3 Wordpress theme » New Versions, & Updating »

Feature Request: Shortcodes in Widgets


  #1  
Old Nov 16, 2010, 05:53 PM
startack's Avatar
startack
 
14 posts · Nov 2010
It's a short bit of code that increases the number of plugins you can use and it saves you from having to find as many plugins with widget options.

You do have to add it to functions.php which is why I'm putting it in as a feature request

http://www.wprecipes.com/how-to-add-...idebar-widgets

All you add is:

Code:
add_filter('widget_text', 'do_shortcode');
  #2  
Old Nov 17, 2010, 08:11 AM
lmilesw's Avatar
lmilesw
 
10,176 posts · Jul 2009
Central New York State USA
I can't be sure but I suspect WordPress has reasons for not allowing this by default. You can alternatively use this plugin.
__________________
~Larry (CNY Web Designs)
This site should be a membership site since it so full of good stuff.
Please consider donating which gives you access to even more good stuff.
  #3  
Old Dec 7, 2010, 05:53 AM
nickcroker
 
13 posts · Nov 2010
I simply cannot get shortcodes to work in sidebar text widgets.

I'm trying to call [highslide] plugin from text sidebar widget (or advanced text widget - tried both).

I've tried adding:
add_filter('widget_text', 'do_shortcode'); to functions.php

I've tried using advanced text widget and numerous other plugins to enable shortcodes in text widgets without luck.

I'm guessing it's a plugin conflict somewhere.

Using WP 3.02 and Atahualpa 3.4.9

Anyone clues very gratefully received.
Nick
  #4  
Old Dec 7, 2010, 07:39 AM
juggledad's Avatar
juggledad
 
23,765 posts · Mar 2009
OSX 10.11.5 WP 4.x Atahualpa(all) Safari, Firefox, Chrome
Wordpress doesn't process shortcodes in text widgets. Try this, add
HTML Code:
<?php add_filter(‘widget_text’, ‘do_shortcode’); ?>
To the end of “functions.php” and see if it works.
__________________
"Tell me and I forget, teach me and I may remember, involve me and I learn." - Benjamin Franklin
Juggledad | Forum Moderator/Support
  #5  
Old Dec 7, 2010, 11:25 AM
lmilesw's Avatar
lmilesw
 
10,176 posts · Jul 2009
Central New York State USA
Also see post #2
__________________
~Larry (CNY Web Designs)
This site should be a membership site since it so full of good stuff.
Please consider donating which gives you access to even more good stuff.
  #6  
Old Dec 8, 2010, 06:02 AM
nickcroker
 
13 posts · Nov 2010
Quote:
Originally Posted by juggledad
Wordpress doesn't process shortcodes in text widgets. Try this, add
HTML Code:
<?php add_filter(‘widget_text’, ‘do_shortcode’); ?>
To the end of “functions.php” and see if it works.
Tried that - no joy.

Also tried various plugins but all I get is the shortcode being displayed [shortcode]blah blah blah[/shortcode] as plain text.

Very frustrating for something I'm thinking should be simple to implement.

I'll keep experimenting.
Thanks,
Nick
  #7  
Old Dec 8, 2010, 06:33 AM
juggledad's Avatar
juggledad
 
23,765 posts · Mar 2009
OSX 10.11.5 WP 4.x Atahualpa(all) Safari, Firefox, Chrome
Highslide uses a tag (<highslide>) not a shortcode ([highslide])
__________________
"Tell me and I forget, teach me and I may remember, involve me and I learn." - Benjamin Franklin
Juggledad | Forum Moderator/Support
  #8  
Old Dec 9, 2010, 06:02 AM
nickcroker
 
13 posts · Nov 2010
Quote:
Originally Posted by juggledad
Highslide uses a tag (<highslide>) not a shortcode ([highslide])
I'm using Highslide for WordPress *reloaded*
which uses a shortcode [highslide] if I want to use HTML in my popup - see near bottom of linked page.
  #9  
Old Dec 9, 2010, 08:25 AM
lmilesw's Avatar
lmilesw
 
10,176 posts · Jul 2009
Central New York State USA
Since the sidebar shortcode plugin always worked before I unfortunately assumed it would work with this so I installed Highslide 4 WordPress Reloaded and found out like you that it didn't so I tried what is fast becoming my favorite way to create sidebar content.

I use the Spectacu.la Page Widget plugin. you just create a page with the Highslide shortcode in it. Then you go to Appearance>Widgets and add the Spectacu.la widget to the sidebar and point it to the page you just created. Worked great for me.
__________________
~Larry (CNY Web Designs)
This site should be a membership site since it so full of good stuff.
Please consider donating which gives you access to even more good stuff.
  #10  
Old Dec 10, 2010, 05:38 AM
nickcroker
 
13 posts · Nov 2010
Quote:
Originally Posted by lmilesw
Since the sidebar shortcode plugin always worked before I unfortunately assumed it would work with this so I installed Highslide 4 WordPress Reloaded and found out like you that it didn't so I tried what is fast becoming my favorite way to create sidebar content.

I use the Spectacu.la Page Widget plugin. you just create a page with the Highslide shortcode in it. Then you go to Appearance>Widgets and add the Spectacu.la widget to the sidebar and point it to the page you just created. Worked great for me.
Fantastic! I'll give that a try. Thanks.
  #11  
Old Dec 10, 2010, 07:03 AM
nickcroker
 
13 posts · Nov 2010
The good news - it worked

The bad news - highslide crashes/corrupts pages and posts if the content to be 'highslided' is more than 500 or so words

So I'm still searching for a 'popup' plugin that will show the heading and body content of a page/post when the user clicks a link in my sidebar.

However I do love the Spectacu.la page plugin!
Nick
  #12  
Old Dec 10, 2010, 10:38 AM
lmilesw's Avatar
lmilesw
 
10,176 posts · Jul 2009
Central New York State USA
What was the code you used for highslide to open a page in a window? Have you tried shadowbox js. It will open a url in a modal window.
__________________
~Larry (CNY Web Designs)
This site should be a membership site since it so full of good stuff.
Please consider donating which gives you access to even more good stuff.
  #13  
Old Oct 22, 2011, 09:11 AM
polins
 
3 posts · Nov 2010
I use the extra plugin "Shortcodes in Sidebar Widgets" to solve this problem. It works in the background once installed.
ATA 3.6.4, WP 3.1
  #14  
Old Oct 25, 2011, 03:39 AM
Knut Sparhell
 
34 posts · Jun 2010
Fredrikstad, Norway
FYI: Shortcodes will work for text widgets in WP 3.3

Bookmarks



Similar Threads
Thread Thread Starter Forum Replies Last Post
New Feature Request for Header Images kal New Versions, & Updating 0 Jun 9, 2010 07:01 AM
Feature Request:Page bar include instead of exclude Kadin Page & Category Menu Bars 2 May 11, 2010 03:01 PM
Feature request-Thumbnail support chasapple New Versions, & Updating 1 Jan 9, 2010 05:09 AM
Feature Request georgenoise New Versions, & Updating 0 Dec 31, 2009 09:57 AM
Feature Request Suzie RSS, Feeds & Subscribing 0 Sep 14, 2009 10:12 PM


All times are GMT -6. The time now is 06:13 AM.


Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.