New Landing How can we help? Atelier PHP Warning

Viewing 10 posts - 1 through 10 (of 10 total)
  • Posted in: Atelier
  • #247384
    chanson
    Member
    Post count: 11

    I have been seeing the following error code pop up recently. I am on WP 4.4.2 and my theme is updated to 1.9.4

    [09-Feb-2016 00:14:49 UTC] PHP Warning: Missing argument 2 for sf_audio_post(), called in /swift-framework/content/sf-post-formats.php on line 51 and defined in /swift-framework/content/sf-post-formats.php on line 192

    #247518
    David Martin – Support
    Moderator
    Post count: 20834

    Hi,

    What version on the Swift Framework do you have?

    Thanks.

    #248079
    chanson
    Member
    Post count: 11

    I am on the most current version 1.7.7

    #248652
    David Martin – Support
    Moderator
    Post count: 20834

    Is that sitewide or on a specific page?

    Can you add your FTP details?

    Thanks.

    #248912
    chanson
    Member
    Post count: 11
    This reply has been marked as private.
    #249506
    David Martin – Support
    Moderator
    Post count: 20834

    Thanks for reporting this, lastly please add a WP login for us to take a closer look at your audio post setup.

    Thanks.

    #249662
    chanson
    Member
    Post count: 11
    This reply has been marked as private.
    #250371
    David Martin – Support
    Moderator
    Post count: 20834

    Hi,

    Within your child theme functions, can you test this:

        /* GET AUDIO MEDIA
        ================================================== */
        if ( ! function_exists( 'sf_audio_post' ) ) {
            function sf_audio_post( $postID, $use_thumb_content = null ) {
                $media_audio = "";
                if ( $use_thumb_content ) {
                    $media_audio = sf_get_post_meta( $postID, 'sf_thumbnail_audio_url', true );
                } else {
                    $media_audio = sf_get_post_meta( $postID, 'sf_detail_audio_url', true );
                }
    
                $audio = do_shortcode( '[audio src="' . $media_audio . '"]' );
    
                return $audio;
            }
        }

    Thanks.

    #250484
    chanson
    Member
    Post count: 11

    Ok, function has been added. I will monitor the errors to see if this comes up again.

    Thanks

    #250501
    David Martin – Support
    Moderator
    Post count: 20834

    Great, ok – please let me know.

    Thanks.

Viewing 10 posts - 1 through 10 (of 10 total)

You must be logged in and have valid license to reply to this topic.

License required for one of the following items
Login and Registration Log in · Register