[SOLVED] Dynamic Headers Plugin & Atahualpa 3.6.7.
Ive been using the Dynamic Headers plugin to give specific pages specific headers in my otherwise atahualpa run site, http://www.itsalltrue.net
I had to update to 3.6.7 (& WP 3.2.1) today because of some sitewide problem that inserted whitespace into tons of PHP files. After patching everything up, the Dynamic Headers plugin no longer works with Atahualpa. Dynamic headers requires that this be inserted where it's called for: <?php if(function_exists('show_media_header')){ show_media_header(); } ?> That used to be able to be placed in the Configure Header Area, but that no longer works. I assume that's because WP's new rules regarding custom php. So, the long way to get to my question is... where in the Atahualpa theme files should I place that custom insert? (This is just the first of many problems today including not knowing how to do two column loops in 3.6.7, placing content above the loop in 3.6.7, etc. This whitespace/php problem and it's solution has really screwed up my entire site today and I still don't know the cause.) Thanks in advance for any help. |
It needs to go in index.php
|
Or you can add a new widget area and put that code in a php aware widget.
|
Thank you for the help so far.
Juggledad, can you be more specific? I had narrowed it down to that file, but I'm not sure of the exact spot. Since the site had a PHP meltdown today, I'm a little gunshy. My index.PHP is a brand new 3.6.7 copy. lmilesw, the widget solution would resist updates to the index file wouldn't? Hmm. I need to (re) add some content above the loop, a widget there would do some good. While I'm here, can either if you give any hint to what might cause several PHP files, some in a phpbb forum and some in the wp/Atahualpa section to suddenly have several spaces added to them? I'm sure could be a million reasons, but it seems like it shouldn't and this is the second time in 8 weeks that our site has been crippled by it. |
You can put the code in index.php, but if you want it in the header, Larry's suggestion is best. Add a new widget area to the ato->Style & edit HEADER AREA->Configure Header Area, then add your code to a text widget - you will also need something like the 'exec-php' plugin. This method will survive updates. (note: doing it this way, you can control where in the header is shows up, by it's location in the order of options)
If you want to put the code directly in index.php, put it right before line 7 HTML Code:
<?php /* If there are any posts: */ Quote:
Code doesn't just change itself, something or someone had edited it or replaced it with a different version. Look at the time stamps on the files also. |
Thanks, I'll shoot for the widget open first.
There were still some corrupted areas of the site - the forum - and sure enough the files with spaces in them were updated over the course of an hour this morning. My hosting company is looking into it on their end. I'll have to dig into my CPanel and see if I can find more info for that timeframe. Things are getting back in order. After I get the header fixed I've just got to figure out how to put the two columns back. Thank you again. Edit... Okay, I tried to solve this one on my own, but I've been unsuccessful. Since this header is now in a widget, it's subject to the widget styling. Can I write something into CSS to suspend those styles from affecting it or would it have to be the other way around, to remove the widget styling from the ATO and then put the styles in the CSS to affect the ones that aren't the header? My id for the header is div id="header" but the class is either class="bfa_widget_area", class="widget widget_text", or class="textwidget". I've tried calling for various ones, but haven't been succesful in affecting the styles. |
You can code CSS selectors to just apply to that area. since you called the widget area 'bfa_widget_area' (I'd use a more descriptive name like 'dynamic_header_widget_area') you can code it like
HTML Code:
div.bfa_widget_area div.widget {.....} |
Thank you! I really appreciate your help (Larry's too!) The header is working great and the widget is free of the styling of the others!
|
All times are GMT -6. The time now is 04:53 AM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.