alanft
Forum Replies Created
-
Forum: Plugins
In reply to: WP_DEBUG throws lots of warnings with Widget LogicI will take a look at this and update the code as soon as i get a chance and work out what the problem is. Thanks for bringing this up
well i haven’t checked, but the template shouldn’t have any bearing on the conditionals used to separate the home page (is_front_page) and the blog page (is_home). there may be something else going on in the widgets you are using. see the suggestion in the older topic you linked to.
(i only missed that other topic cos for some reason the ‘widget logic’ tag on that is widget-logic-3. weird!)
Forum: Plugins
In reply to: [Plugin: Widget Logic] Sequence of WP widgets alters page type behaviorinteresting. one guess would be that the recent posts widget is messing up the main page query conditions, so you’d have to do a reset query after that widget has run.
you could try that a couple of ways. one hack WL do do the reset after every widget instead of just the once (as it currently does)
OR (perhaps more sensibly) do the reset in the following widget’s WL code. if the code is currently
!is_front_page()
change it to
wp_reset_query(); return !is_front_page();
note the final ;
see if that changes things.
Forum: Plugins
In reply to: Widget Logic Not Working Since Upgradedid you get this sorted?
Forum: Plugins
In reply to: [Plugin: Widget Logic] Parse errori’m definitely not seeing that the way i change stuff and save. if you can replicate this and give me click by click directions, i’ll see what i can find.
Forum: Plugins
In reply to: [Plugin: Widget Logic] Parse errorha ha, yes! i will! thanks 🙂
“I edited it, fixed the error, then when I went back to edit the widget text the old widget_logic value got saved again”
let me check on this – my install is subtly different…
Forum: Plugins
In reply to: [Plugin: Widget Logic] Parse errorassuming you’ve copied and pasted your code above, there is a ) missing off the end.
Forum: Plugins
In reply to: Attachments to pages slow down the site – how do you deal with it?to answer my own question, i have now restored the hacked rewrite.php and put this in my functions.php instead:
add_filter('page_rewrite_rules', 'my_page_rewrite_rules'); function my_page_rewrite_rules($page_rewrite) { return array_filter($page_rewrite, 'my_page_rewrite_rules_callback'); } function my_page_rewrite_rules_callback($var) { return (strpos($var,"?attachment=")==false);}which has reduced my rewrite rules from 780 to 196, i.e. a quarter of the size!
this removes every attachment-based URL (where the re-written form includes the string “?attachment=”) from pages (via page_rewrite_rules filter).
Forum: Plugins
In reply to: Widget Logic on 2.8without testing it, try adapting the last example in the http://wordpress.org/extend/plugins/widget-logic/other_notes/ but add a ! (to make NOT). something like:
global $post; return !(is_page(13) || ($post->post_parent=="13"));Forum: Plugins
In reply to: [Plugin: Widget Logic] ‘wp_reset_query’ fix option does not stickwhich if it looks good i will commit and update the repository this evening (i’m still working out why it works…)
Forum: Plugins
In reply to: [Plugin: Widget Logic] ‘wp_reset_query’ fix option does not sticki think i’ve fixed this, which would be awesome
line 46 should read:
$regd_plus_new=array_merge(array_keys($wp_registered_widgets),array_values((array) $_POST['widget-id']),array('widget_logic-options-filter', 'widget_logic-options-wp_reset_query'));Forum: Plugins
In reply to: [Plugin: Widget Logic] ‘wp_reset_query’ fix option does not stickdo you know what, i think i’ve finally got it.
if i refresh the page after a change to a widget (or just click save in a widget), the option is undone.
woo.
thanks!
trouble is that i overlook this option as i don’t need it. which is why it’s slipped past me so easily.
ok will look for a hack and then later get it updated. been a while!…
Forum: Plugins
In reply to: [Plugin: Widget Logic] ‘wp_reset_query’ fix option does not stickno, you shouldn’t have to do this.
i get report of this from time to time, but i’ve not (as yet) been able to reproduce it with any of my wp installs.
i’ll try your description later. until then if you have a step by step recipe that does this i’d be grateful.
i suspect it’s not a theme-based issue, but maybe to do with other plugins – but it’s hard to ask you to list/deactivate other plugins.
i’ll get back to you…
Forum: Plugins
In reply to: Widgets not displaying with Widget Logicthe filter is called widget_content, not the_ttftext, so you need to change your add_filter line to:
add_filter(‘widget_content’, ‘ttftext_widget_title’);
i’ve just noticed though that I should update http://wordpress.org/extend/plugins/widget-logic/other_notes/ because my example function, like yours, has a second $widget_id parameter — but it’s not used so should be removed. when that parameter is removed you can remove the extra ‘2’ in your add_filter (as that specs the number of parameters the function should expect).
Hope this helps
A
Forum: Themes and Templates
In reply to: Atahualpa Incompatible with Widget Logic?i’m out of straightforward ideas, but…
if it is the theme (as you say, all is well if you switch to a default) and the wp_reset_query options isn’t enough perhaps atahualpa needs resetting many times – Widget Logic just does one reset per page. (i’ve downloaded atahualpa and skimmed through it and it *seems* harmless, but who knows…)
so you could try hacking WL. find ‘$wp_reset_query_is_done=true;’ (line 152) and change true to false. this results in resetting the query before every sidebar widget