We use cookies to improve your experience. No personal information is gathered and we don't serve ads. Cookies Policy.

ExpressionEngine Logo ExpressionEngine
Features Pricing Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University
Log In or Sign Up
Log In Sign Up
ExpressionEngine Logo
Features Pro new Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University Blog
  • Home
  • Forums

Fieldtype development

Development and Programming

jcowen's avatar
jcowen
66 posts
13 years ago
jcowen's avatar jcowen

Hi All,

I’ve made my own fieldtype which is all working correctly as far as i can see, although I’m having a problem when saving entries.

If I select a category and press submit (when editing), everything seems to work as it should, and when clicking on the categories tab, I can see the category selected.

If I then reload the entry, the category then isn’t selected any more? Does anyone have any ideas? I’ve checked that none of the form fields ive created are conflicting in terms of their names

Thanks in advance…

       
Bhashkar Yadav's avatar
Bhashkar Yadav
727 posts
13 years ago
Bhashkar Yadav's avatar Bhashkar Yadav

can you confirm if same issue is arising when channel doesn’t have this custom field.

       
jcowen's avatar
jcowen
66 posts
13 years ago
jcowen's avatar jcowen

Admittedly, categories are selectable and retain their selection when editing items within another channel which doesn’t have my fieldtype assigned

       
Bhashkar Yadav's avatar
Bhashkar Yadav
727 posts
13 years ago
Bhashkar Yadav's avatar Bhashkar Yadav

Hi John,

i think, you need to check fieldtype code properly if its resetting category during save, validate or display_field.

       
jcowen's avatar
jcowen
66 posts
13 years ago
jcowen's avatar jcowen

Hi Bashkar,

I’m not setting / resetting the category in any of those methods. I just can’t understand why it’s doing this. I’ve no need to have validate method, so I’ve simply removed it from my class.

       

Reply

Sign In To Reply

ExpressionEngine Home Features Pro Contact Version Support
Learn Docs University Forums
Resources Support Add-Ons Partners Blog
Privacy Terms Trademark Use License

Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.