Forum Replies Created

Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter estetson

    (@estetson)

    This is what I already tried adding into the KB Advanced RSS plugin, which failed:

    <?php
    function filter_KB_RSS_output_format($output_format) {
    	ob_start();
    	eval("?>$output_format<?php ");
    	$output_format = ob_get_contents();
    	ob_end_clean();
    	return $output_format;
    }
    add_filter('widget_text', array(&$this, 'filter_KB_RSS_output_format'));
    ?>

    $output_format is what the KB Advanced RSS plugin uses to store the user-entered HTML and code for how to format the display of the RSS feed being accessed.

    I looked at the existing Exec-PHP plugin code to see how it works, and it uses a filter similar to the above.

    One problem I found out is that the filter ‘widget_text’ can ONLY be used for the WordPress Text Widget and apparently cannot be used for other widgets in which users enter fields of text, such as the one I want to modify. So I don’t know what filter hook name to use, since there doesn’t seem to be any that will work.

    Also, since I’m a beginner with coding, there might be other problems with the code I wrote which I don’t realize.

    I would very much appreciate any comment from somebody who knows what they’re doing. Am I at least on the right track, or is using a filter not the way to accomplish what I want to do?

    Thread Starter estetson

    (@estetson)

    I’ve been able to get it to display the title of each page superimposed over the header masthead image, but I need it to only do that for blog post pages and for some specific static pages. For some other static pages, I need it to display the site title. For an author archive page, it needs to display the name of the author.

    Also, if a page has a parent page, I want it to display not only the page title but also the parent page title, like this: “Parent Title > Current Page Title”

    How can I specify each of these things in header.php using if statements?

    Thread Starter estetson

    (@estetson)

    Anyone interested?

    I’m willing to pay someone for code that will do what I need, if nobody wants to look at this without compensation.

Viewing 3 replies - 1 through 3 (of 3 total)