Wordpress Themes - WP Forum at BFA

Wordpress Themes - WP Forum at BFA (http://forum.bytesforall.com/index.php)
-   Sidebars & Widgets (http://forum.bytesforall.com/forumdisplay.php?f=14)
-   -   Follow up on Widget on pages thread (http://forum.bytesforall.com/showthread.php?t=21549)

EasyHiker Feb 22, 2014 09:06 AM

Follow up on Widget on pages thread
 
Hello all,

I have been working on having widgets on pages in my site, first trying to do it in the ATO Creating widgets and dowloading WP plug-ins, with no success.

I've searched high and low in the forum and been reading this thread here: http://forum.bytesforall.com/showthread.php?t=330

However, when I copy and paste what I need to put on the functions.php file of Atahualpa (in the theme's folder via FTP), my Admin interface disappears and I get an error telling me there's a syntax error. (I'm using the latest versions of WP and Atahualpa 3.7.13.)

What could I be doing wrong?

Also, is there a summary of these steps somewhere of what I need to undertake to have widgets on post and pages (what I should add to the theme's functions.php, index.php, and the CSS inserts necessary, etc.)?

(I've managed to put in the Quote's widget, by the way.)

Thanks for any help!

:confused:

juggledad Feb 22, 2014 10:18 AM

That thread is ancient history, it's from 2009!

You can now (as of 3.7.12) add a widget area to the top or bottom of the center area, just look at the onscreen documentation.

EasyHiker Feb 22, 2014 01:32 PM

Thanks, JuggleDad. I had suspected as much but I thought I'd give it a go. By onscreen documentation, you mean in the ATO, no need to dig in via FTP?

I tried that too. I created the widgets, they are in the Appearance>Widget area but I just don't know how to put the widgets on the Page or on a Post. I've got widget logic. What code do I need to put on the post or page to get the widgets?

I want to put in 3 widgets on a page that will be made static, as in an About page. How do I do that with the Widgets now created?

Sorry if I seem such a dork about this, but I've been at this for the last 3 days now and I've not advanced in any way.

lmilesw Feb 22, 2014 02:03 PM

Did you try looking for a plugin to put widgets on pages. Here is one I found in a quick search of wordpress.org which MAY do what you want but I have not tested.

juggledad Feb 22, 2014 02:22 PM

Lets say you want widget 'A' to show on pages and widget 'B' to show on single posts. You create a widget area called …oh heck, lets call it 'EasyHikers center widget area'.

Now when you go to dashboard->appearances->widgets, you wil see your new widget area. Now you put both widget 'A' and widget 'B' into the area.

If you looked at a post or page you would see both widgets and this is where Widget Logic comes in. For widget 'A' in the widget logic section of the widget, you would add
HTML Code:

is_page()
this would tell the widget to only show on 'page'pages
in widget 'B' you would add
HTML Code:

is_single()
so the plugin would only show on single post pages.

The logic can get complex or not. Lets say you want widget 'A' to show on 'page' pages and widget 'B' to show on ALL other pages (archives, categories etc). You would use the same logic for widget 'A' and for widget 'B' you would use
HTML Code:

!is_page()
Which says, show this on anywhere it is NOT a 'page' page.

You could aslo try the plugin 'Widget Logic Visual' whigh gives you check boxes to use.

EasyHiker Feb 23, 2014 12:04 AM

Thanks, Larry, Juggledad,

I'll see what I can do with the advice you've given and come back if I get lost again somewhere. Have just donated for this cry for help and will donate more if I get this sorted out, because I have at least 3 sites running on Atahualpa (that's how much I like the theme) where I want to use this function on.)


All times are GMT -6. The time now is 11:09 AM.

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