Wordpress Themes - WP Forum at BFA

Wordpress Themes - WP Forum at BFA (http://forum.bytesforall.com/index.php)
-   Post-Kicker, -Byline & -Footer (http://forum.bytesforall.com/forumdisplay.php?f=17)
-   -   [SOLVED] How to Add Javascript to Post Footer (or Kicker)? (http://forum.bytesforall.com/showthread.php?t=15055)

LaneLester Aug 10, 2011 07:52 AM

[SOLVED] How to Add Javascript to Post Footer (or Kicker)?
 
I'd like to put some Javascript ad code in the post footer space. I pasted it in the Multi-Post and Single Post Footer fields on the Post Info Items page.

It doesn't show up.

I'm using Ata 3.6.7, and I've applied the four patches.

Lane

lmilesw Aug 10, 2011 11:12 AM

I THINK you can add a new widget area to those boxes and then use a widget for the code.

LaneLester Aug 10, 2011 11:59 AM

Thanks, Larry. I don't know if it's possible to add widgets any more. The "Add Widgets" section says you can, and then when I go to the Style Center Column to add the code, there's no place to put it. Instead, there's this message:

Quote:

Where are the 'Content ABOVE Loop', 'The LOOP' etc. options?They are now 'hardcoded' into Atahualpa's <code>index.php</code>. To edit the loop or to add custom code before/after the loop, manually edit <code>index.php</code>.

Since 3.6.5 custom PHP code isn't possible anymore in the Atahualpa Theme Options.
I guess I'll have to cram it into the single.php and so forth.

Later: I found the Quick AdSense plugin will do the job. I'd rather not mark this thread SOLVED in case someone knows an Atahualpa solution.

Lane

lmilesw Aug 10, 2011 03:51 PM

You can put the widget code in the same place you were trying to put the ad code... I think.

LaneLester Aug 10, 2011 04:10 PM

Quote:

Originally Posted by lmilesw (Post 70512)
You can put the widget code in the same place you were trying to put the ad code... I think.

Well, I did try that. I put:
Code:

<?php bfa_widget_area('name=Post Footer'); ?>
in the "FOOTER: Single Post Pages" field.

In the "Add Widgets" section is this:
Quote:

Note: After you've added new widget areas, you'll need to reload a front end page 1-2 times before they get created and start appearing on the front end. And you'll need to reload WP->Presentation->Widgets 1-2 times before you can see the new widget areas there and start adding widgets.
I'm not sure what a "front end page" is, but I reloaded the home page a couple of times. I also reloaded the Appearance / Widgets page a few times, but only the sidebar widgets are there.

Lane

juggledad Aug 10, 2011 04:18 PM

did you go to dashboard->appearances->Widgets and see if there was a new widget area and add a widget to it?

lmilesw Aug 10, 2011 04:48 PM

I did say "I think" so the widget code may not work there but it looks like you have it figured out.

LaneLester Aug 10, 2011 04:54 PM

Quote:

Originally Posted by juggledad (Post 70519)
did you go to dashboard->appearances->Widgets and see if there was a new widget area and add a widget to it?

I went there, but there was no new widget area. I presume it would be under these, and it would say "Post Footer" since that's what I put in the code:

Quote:

Left Sidebar

Right Sidebar

Left Inner Sidebar

Right Inner Sidebar
Lane

juggledad Aug 10, 2011 05:15 PM

Well, I just copied teh code you have in post #5, put it in the Footer: Content, went and viewed the front page of my site and now when I go to dashboard->Appearances->widgets I see
Left Sidebar
Right Sidebar
Left Inner Sidebar
Right Inner Sidebar
Post Footer

So it works...

LaneLester Aug 10, 2011 05:26 PM

Quote:

Originally Posted by juggledad (Post 70523)
So it works...

I think we have a failure to communicate. I don't want the ad in the footer; I want it in the post footer. That is different from the site footer, isn't it?

But I'm encouraged by your success. Please try putting the code in Post Info Items / FOOTER: Single Post Pages and see if it shows up.

Lane

juggledad Aug 10, 2011 05:53 PM

Agh, sorry. Nope it won't go there you need to edit index.php and put it in there

LaneLester Aug 10, 2011 06:02 PM

Quote:

Originally Posted by juggledad (Post 70528)
Agh, sorry. Nope it won't go there you need to edit index.php and put it in there

OK, thanks for checking.

The Quick AdSense plugin provides good control of just what kinds of posts and/or pages the ads appear on. It also provides options for where on the page: above/below the post or even inside it.

Lane


All times are GMT -6. The time now is 02:04 AM.

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