• I need to apply a custom field that defines a default post thumbnail to a specific category in my theme.

    I use the following code but the default value doesn’t populate. Can anyone help please?

    [post-thumb-280×225] // this is the name of the custom field
    type = textfield
    value = https://url_to_image // this is the URL to the image

    I should add that I’m using WordPress 3.1.1

Viewing 5 replies - 1 through 5 (of 5 total)
  • Thread Starter cybersnac

    (@cybersnac)

    can anyone tell me if I’m doing this right? or why the default value is not being set if I am doing it right?

    Plugin Author Hiroaki Miyashita

    (@hiroaki-miyashita)

    Please use default = https:// for the text type.

    I am also trying to get a default/value in my text field but doesn’t seem to be working for me am I doing anything wrong? Also should the default appear in the field or be blank but still contains the value.

    [summary_title]
    label = Summary title
    type = text
    default = In summary
    output = true

    shoot my bad! It will not work for existing posts. Sorry I am a noob to your superb plugin.

    Thread Starter cybersnac

    (@cybersnac)

    Hiroaki thanks for getting back to me. I’m confused though.
    What do you mean by use default = https:// ?

    I’ve tried adding that line so that my template looks like this but it doesn’t work.

    [post-thumb-280x225]
    type = textfield
    value = https://mywebsite.com/pathtosomeimage.jpg
    default = https://
Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘[Plugin: Custom Field Template] Default Value for textarea?’ is closed to new replies.