• Resolved ngospelmedia

    (@ngospelmedia)


    Hello greetings, I just viewed a post at my site front end and I saw this error messages on it.

    Notice: Undefined variable: post in /home/************/public_html/wp-content/plugins/advanced-ads/classes/ad_type_plain.php(154) : eval()'d code on line 6

    I have removed the plugin and installed it again still the error still there…

    The page I need help with: [log in to see the link]

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Support schmidt25

    (@schmidt25)

    Hi ngospelmedia,

    Thanks for reaching out.

    It could be that you have inserted custom code into your ad and enabled the “Allow PHP” option for that ad. This can lead to such an error message in the frontend. Can you please check if this is the case?

    Best regards,
    Joachim

    Thread Starter ngospelmedia

    (@ngospelmedia)

    Yes that is the case, and here is the php code below:

    <?php the_terms( $post->ID, ‘artiste’, ‘<b>Song Artiste:</b> ‘, ‘, ‘, ‘ ‘ ); ?> <br />
    <?php the_terms( $post->ID, ‘country’, ‘<b>Artiste Country Origin:</b> ‘, ‘, ‘, ‘ ‘ ); ?> <br />
    <?php the_terms( $post->ID, ‘language’, ‘<b>Song Language:</b> ‘, ‘, ‘, ‘ ‘ ); ?> <br />
    <?php the_terms( $post->ID, ‘genres’, ‘<b>Music Genres:</b> ‘, ‘, ‘, ‘ ‘ ); ?> <br />
    <?php the_terms( $post->ID, ‘music_type’, ‘<b>Music Group:</b> ‘, ‘, ‘, ‘ ‘ ); ?> <br />
    <?php the_terms( $post->ID, ‘album’, ‘<b>Artiste Musical Album:</b> ‘, ‘, ‘, ‘ ‘ ); ?> <br />

    I have been using your plugin to run this php codes for more than 2years now on my site, but now the code is no more working.

    The above codes are php codes to display custom taxonomy on front end. That is what is does.

    But this has been working well for long, but I don’t know why it stopped and start showing error on front end.

    Thanks…

    Plugin Support schmidt25

    (@schmidt25)

    Hi ngospelmedia,

    I suspect that the ad code is loaded somewhere where $post does not exist. This happens with Advanced Ads, for example, when loading the ad via AJAX cache-busting. But if you don’t use Advanced Ads Pro then it must come from somewhere else.

    Best regards,
    Joachim

    Plugin Support schmidt25

    (@schmidt25)

    Hi ngospelmedia,

    Did you have the chance to test the integration with disabled cache-busting meanwhile if using Advanced Ads Pro?

    Best regards,
    Joachim

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Error on Front end with your plugin’ is closed to new replies.