Viewing 7 replies - 1 through 7 (of 7 total)
  • Thread Starter DanInManchester

    (@daninmanchester)

    I fixed it for my version.
    You need to make the post_id null by default

    function wptr_supress_title($title, $post_id = null) {
    global $id;
    $hide_title = get_post_meta( $post_id, ‘wptr_hide_title’, true );
    if (!is_admin() && is_singular() && intval($hide_title) && in_the_loop())
    return ”;
    return $title;
    }<

    Thanks for this tip, just added to my site using Tesseract theme and it work a treat.

    Where do you add this:

    $post_id = null

    to fix this problem? I am also using Tesseract

    Thanks

    Thread Starter DanInManchester

    (@daninmanchester)

    You need to find “wptr_supress_title”

    function wptr_supress_title($title, $post_id)

    so I changed to this :

    function wptr_supress_title($title, $post_id = null)

    Thanks, I got the error to go away. Oddly, the title remover doesn’t have any effect on my forum webpage, but that is a question for the forum page forum…
    Thanks

    Hi. I had the same error on the Forum page of my website, with the error line not appearing on any other pages. It seemed too much work to try and edit the plugin code ( I am a doctor, not a software developer) therefore, I just deleted the suppress title plugin, installed the Hide-title plugin and activated it on the homepage. The title is now hidden and the error line is gone. Thanks very much.

    @daninmanchester you are brilliant! Thank you so much ??

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Warning: Missing argument 2 for wptr_supress_title()’ is closed to new replies.