Support

Account

Home Forums Feedback Problem with save & loading data on custom field type

Solved

Problem with save & loading data on custom field type

  • hi @elliot,
    tnx for creating awesome plugin
    i have added a new type for using ace editor (http://ace.c9.io/).
    i am newbie in PHP programming but with documentations and acf-field-type-template created this field.
    and my problem is about saving and loading field value. could you please give me some information and review my code.

    tnx a lot

  • Hi @Navid Kashani

    The issue is on line 169 where you define the textarea. The name of the textarea is important and must be left as $field['name'], not my-<?php echo $field["editortype"]; ?>-editor

    The is so that ACF can save the data correctly!

    Thanks
    E

  • Thanks @elliot, this solved my problem but create another question! 😀

    if my field has more than one option for saving, what should i do in this situation?

    Thanks
    Navid

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

The topic ‘Problem with save & loading data on custom field type’ is closed to new replies.