Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
After adding a custom field (various types) they do not appear in the available fields list (Manage Display). The custom fields do appear on the manage fields page.
Note: I am using a two column stacked layout.
Comments
Comment #1
swentel CreditAttribution: swentel commentedI'm confused. Custom fields from DS can't appear on the manage fields, it should be otherwise.
Comment #2
Dean Mortimer CreditAttribution: Dean Mortimer commentedLet me clarify...
1) I can setup new custom fields such as Code fields and Dynamic fields and they DO appear on the fields tab so I know that they have been setup ok.
2) The created custom fields DO NOT appear in the list of fields on the Manage Display tab.
As a point of reference the "Display Suite for Drupal 7 - Part 3: Fields" tutorial on utube is a good example of what I am trying to achieve. From 1 minute 50 secs (add custom field) field to 3 minutes 40 secs where the custom field called "Custom Display Field" is listed in the disabled region. Essentially I can not see the "Custom Display Field" described in the tutorial.
I've got Eclipse setup so will attempt to debug this tomorrow. If you can point me at any specific pieces of code it would help me provide you with more specific info.
Thanks for responding so quickly.
Comment #3
swentel CreditAttribution: swentel commentedOw, okay I was confused. You probably haven't selected a layout yet - see the vertical tab at the bottom. DS fields only show up after that, not before.
Comment #4
Dean Mortimer CreditAttribution: Dean Mortimer commentedI have already selected a layout "Two column stacked" (i saw that this might cause a problem on a forum post).
Comment #5
Dean Mortimer CreditAttribution: Dean Mortimer commentedComment #6
swentel CreditAttribution: swentel commentedStill can't reproduce this, setting to needs more info.
Comment #7
sreynen CreditAttribution: sreynen commentedI'm seeing this same problem. Layout is selected, but it's just like there is no layout selected. What other info would be useful?
Comment #8
sreynen CreditAttribution: sreynen commentedThe problem in my case was that module_implements('ds_fields_info') wasn't picking up the .inc files for some reason. I'm not sure why this problem doesn't come up on all sites. I've only seen it once. Adding the .inc files to the .info file made it work for me.
Comment #9
sreynen CreditAttribution: sreynen commentedScratch that, I was just looking at the wrong site. I did track the problem down to another module that had an include_once() call to a file that wasn't there. This was for some reason causing ds to be missed in the hook_info cache_bootstrap, so it wasn't finding the ds_fields_info hook implementations. This was coming up as a PHP warning in my case, so I'd suggest others having the same problem check for PHP warnings and/or make sure ds_fields_info is part of the result when you call cache_get('hook_info', 'cache_bootstrap');
Moving this to fixed, hoping this fixes it for others. If not, move it back.
Comment #11
Louis Bob CreditAttribution: Louis Bob commentedSorry, I have the same issue and I don't understand the solutions to solve it.
I have no specific PHP warning.
How do I practically see the results of "call cache_get('hook_info', 'cache_bootstrap');" ?
This issue seems related to http://drupal.org/node/1808994 ?
Comment #12
Louis Bob CreditAttribution: Louis Bob commentedooops...
Fields ARE displayed under NODES display management page, but not under VIEWS DISPLAY, which is normal (I think).
So everything is OK, sorry.
Comment #13
tjmoyer CreditAttribution: tjmoyer commentedI'm having this same issue. Custom fields are not showing up. Strangely, they do at times. I'll work on this for hours and then suddenly they show up, but then they disappear again. @sreynen, what module had the call to include_once() for a non-existant file? I'm working through our list of modules trying to see if that's the case here, too.
Comment #14
sreynen CreditAttribution: sreynen commentedtjmoyer, sorry, I don't remember the specific module, but I believe it was a custom module so we were able to fix it directly. I guess there's a chance you have the same custom module, as we have shared code, though I'd hope we would have fixed the problem on your copy as well in that case. Unfortunately, I don't remember the details now.
To answer the question in #11, there are several ways to do it, but I think I called cache_get('hook_info', 'cache_bootstrap') from /devel/php and dpm() the results.
Comment #15
tjmoyer CreditAttribution: tjmoyer commentedThanks, sreynen. I figured it was a custom module, but was hopeful it wasn't and was one that we're using, too. I've been trying to figure this issue out for several weeks, with no success yet.
I can definitely see that ds_fields_info is missing when I call cache_get('hook_info', 'cache_bootstrap'). When I use dpr() to print out data for debugging the custom field suddenly shows up again, at least until I remove that line and clear cache, at which point it disappears again.
Comment #16
Anonymous (not verified) CreditAttribution: Anonymous commented*Edit* This is for Drupal 6 only:
I thought I had the same problem, wasn't the first time that this happened, but, under the field settings the content types are where the fields are EXCLUDED. Check that you didn't select the content type where it should be visible.
Comment #17
tjmoyer CreditAttribution: tjmoyer commentedThanks, Deraynger. When you say field settings, I presume you mean under a specific display in Manage Display if you click the "Field display" link? I don't have that because the field doesn't show up in the list. Or do you mean in Display Suite Extras (admin/structure/ds) somewhere? I'm just not finding what you're referring to. Please clarify.
Comment #18
Anonymous (not verified) CreditAttribution: Anonymous commentedSorry tjmoyer, my bad. Was referring to Drupal 6, in 7 it's apparently how I expected it to be in 6 :)
I was referring to /admin/build/ds/modules/nd/fields, then editing any of the fields.
Comment #19
Hanpersand CreditAttribution: Hanpersand commentedThis is happening to me, in 7.x-2.4. I intermittently lose my custom fields in my "Manage Display" list. It's very frustrating. Here's my hacky fix, which seems to work fairly consistently:
1. Change the DS layout to something else.
2. Drush CC all (clear all caches)
3. Change layout back.
Sometimes I have to repeat this 1-3 times before the fields show up again. I have no idea what causes it. I'm usually just arranging fields, and then at some point I hit save and when the page reloads, the custom fields are gone. I am using fieldgroup and I know there have been issues between these two modules before. If I notice consistent behavior, I'll report back.
Comment #20
Hanpersand CreditAttribution: Hanpersand commentedI think I know what causes them to vanish in my case. I customized a template... ds-1col--node-blog-post.tpl.php
When I make an HTML change to the template, all my fields vanish. I can do the steps above to get them back. I think that's the cause.
As long as it's not random willy-nilly that they vanish, I can live with that.
Comment #21
Hanpersand CreditAttribution: Hanpersand commentedNope, it seems more random than a template change. I'm not sure what causes it. Sometimes I've only uploaded CSS, and the fields vanish. Or just vanish. But I don't have to change the DS layout to get the fields back. Just Drush CC all twice or three times and the fields return.
Perhaps I should start a new issue in case others are experiencing this.
Comment #22
zmove CreditAttribution: zmove commentedSame problem here. I had custom fields, stopped working on the project for about 15 days. Then returned to the project, updated some modules (but not display suite that is 2.6) and now, I don't see any display suite custom fields on my manage display tabs whereas I selected a display suite layout (the reset one).
Comment #23
SimonMartineau CreditAttribution: SimonMartineau commentedI think the documentation have to indicate clearly that we have to choose a layout to show the custom fields. For me, it two differents logics: fields and layouts: I dont want to use layout so I never activated one. I search my new field in the regular field list.
I'm really happy to solve my problem.... It a so fabulous module!
Comment #24
aspilicious CreditAttribution: aspilicious commentedThis issue is about the behaviour that the fields disappear AFTER selecting a layout. I still can't reproduce it but enough people are reporting this to leave this issue open.
Comment #25
Hanpersand CreditAttribution: Hanpersand commentedYes, as @asplilicious says, my trouble has definitely been happening with layouts in use.
Comment #26
zilla CreditAttribution: zilla commentedditto - i added a custom code field on type node for a flag:
when i go to DS fields, i can see it, but there is no way to see it or control it via manage display - though oddly, has anybody tried to simply place the field in a block to see if it's rendering correctly?
Comment #27
seanrSame problem here. I do see ds_fields_info in the result when I run dpm(cache_get('hook_info', 'cache_bootstrap')); but it doesn't show my field in the manage display UI even though I am using a custom layout. Interesting, after reloading the Manage Display page after running the above, I got this:
Maybe that could shed some light on this?
Comment #28
seanrAhah, found that error documented in an issue. Perhaps others with this problem are running into this issue: #1623590: Notice: Undefined offset: 1 in _ds_field_ui_fields()
Comment #29
faizalluthfi CreditAttribution: faizalluthfi commentedI had the same problem after enabling other module. In my case, I had enabled pdf module. It is the first time I had enabled pdf module in my production site. If I disable pdf module, the custom fields are available in manage display page. I had tested to enable pdf module before selecting a layout in my local development site, the problem did not happen again. I am very confused as the differents of these cases are I had enabled pdf module after custom fields are created for ds layout on my production site and I had enabled pdf module before selection a layout on my local development site.
Comment #30
MO-2 CreditAttribution: MO-2 commented"Comment Easy Reply" module also causes custom fields to disappear: https://drupal.org/node/2171483
Comment #31
aspilicious CreditAttribution: aspilicious commentedSo this is probably related to other modules interfering with DS. Closing for now as there are no new reports.
Comment #32
aspilicious CreditAttribution: aspilicious commentedComment #33
manuel.adanI had the same issue becouse a custom field with same id as core (author). After delete and create custom field again with other id (now custom_author instead of author) it works.
Comment #34
cravecode CreditAttribution: cravecode commentedI'd just like to confirm for others seeking help. @arcovia's comment (#33) was what helped me.
I named a custom field "Title" by accident, then tried to rename it to something unique. However, the machine name cannot be changed so the ambiguous "title" machine name remained and must have conflicted with the core "title". Deleting the field and recreating it with a nonconflicting name fixed my issue.
Comment #35
karltud123 CreditAttribution: karltud123 as a volunteer commented#3 solved my problem. Thanks!
Comment #36
Graham Knight CreditAttribution: Graham Knight commented#33 worked for me too.
Comment #37
dendreten CreditAttribution: dendreten commented#3 is correct indeed.