0
votes
0answers
17 views

is_page_template() doesn't work with excerpt_length filter

I am tring to set a different excerpt lenght for the pages that use an specific page templates using excerpt_length filter. This is the code: add_filter( 'excerpt_length', 'nmd_excerpt_length', 999 ...
4
votes
3answers
139 views

the_content and is_main_query

I am filtering the content with the the_content filter. Everything works perfect, excerpt that my changes are applied to custom queries as well. My changes appear in the sidebar as well if the widget ...
0
votes
1answer
33 views

How to add a filter conditionally based on page related Conditional Tags

I am developing a WordPress plugin and can't conditionally add filters based on the conditional tags. This is my code: add_Action('init', 'determine_location'); function determine_location() { $d = ...
1
vote
1answer
215 views

Filter out some plugin action in wp head / wp_footer

I am using a plugin called "syntaxhighlighter". I know not to ask for plugin specific questions but rather how to filter out action added to the wp_head / wp_footer conditionally... This is a ...
0
votes
0answers
67 views

Diffrent search templates for different post types

I have a site with diffrent post types. Two of them are the 'post' post type and the other one is 'charity', for both pages I have an index, the normal index.php and a diffrent page template for ...
0
votes
1answer
342 views

Remove CSS & JS files from Wordpress Main Page For Increase Pagespeed?

With the reference of http://stackoverflow.com/questions/12463304/wordpress-load-plugin-css-js-in-functions-php-w-conditional-tags answered by @maiorano84 i am using cforms, FancyBox, WP Page ...
1
vote
1answer
432 views

Using Conditional Statement in functions.php

I've got this code below in my functions.php and I'd like to add two filters with conditional statement not to effect every query_posts. Something like this if(!is_admin() && ...
0
votes
1answer
238 views

Exclude custom function content from certain pages

I have added a small custom function to display a little author bio blurb at the bottom of each blog entry in my functions.php file inside the current theme that I am using. So far so good, it is ...
0
votes
1answer
181 views

How do I assign this filter to a variable? (Appending php & markup to the_content)

===I HAVE SOMETHING THAT WORKS NOW, JUST NOT CORRECTLY. PLEASE READ THE WHOLE POST, I AM GOING TO LEAVE IT ALL UP HERE BECAUSE OTHERS MAY BE ABLE TO BENEFIT FROM ME BUMBLING THROUGH THIS PROCESS!! I ...
1
vote
2answers
87 views

Same Conditionals Not Working on Two Different Hooks

Everyone! I am new to WP and trying to build a plugin. I have the following codes working properly: add_filter('the_content', 'say_hello'); function say_hello($content){ if(is_single() || ...