WordPress.org

Ready to get started?Download WordPress

Forums

Custom Field Template
Before and After Option not working in Custom Field Template (2 posts)

  1. mfuchs
    Member
    Posted 3 years ago #

    Hi together,

    I am using the Custom Field Template plugin and am using the following code to upload a file.

    [BookSpread_2]
    type = file
    relation = true
    before = <span class="pic-thumb">
    after = </span>
    label = Upload Book Spread 2

    I then display the file through the following code in my page template:
    <?php
    $BookSpread_2 = get_post_meta($post->ID, 'BookSpread_2', true);
    echo wp_get_attachment_image($BookSpread_2, 'Book Spreads');
    ?>

    But the before and after option don't seem to work. The code is not output. Any ideas what the issue is?

    Any help would be appreciated!

    Thanks,
    Martin

    http://wordpress.org/extend/plugins/custom-field-template/

  2. simonprice24
    Member
    Posted 3 years ago #

    Hi Martin

    I am having exactly the same problem, did you manage to solve it?

    Multiple uploads are not shoeing either, I am wondering if you need to add something to functions.php.

    Will let you know if I crack it.

    Thanks

    Simon

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic