I'm hoping that someone can point me in the right direction. I have a drupal 6 installation with a number of modules installed however the behaviour of the site isn't always as i'd expect and increasingly there are odd behaviours which i can't explain.

For example, i have a content type which has a field added to it. I then have views which display this field. All of the other fields in this view and content type can be displayed but this field in particular can't be displayed. I can edit the field and see the data that has been saved within it but just can't see it on any of the views!!!

This is so frustrating and similar odd issues happen in other places in the site, and with other modules. I don't think its the fault of one of modules, but perhaps the modules when put together.

What i'm looking for is some help with debugging this ( take the example above to start with ). My problem is that i'm not sure i understand how permissions work and where i'd normally dive into the MySQL i can't seem to find the right place in this case. Can someone point me in the right direction as to why these fields clearly can't be displayed.

I should at this point make it clear that the 'Permissions' page has the right boxes ticked and so should in theory allow me to view the field data.

Thanks in advance.

Andy.

Comments

danny englander’s picture

If you are logged in as user 1, you should be able to see all fields on the front end no matter what. The true test is to then go to the site in another browser as an anonymous or authenticated user and test things out.

The other thing you could do is install the Masquerade module and then you can switch users / roles on the fly and then use one browser. The key with custom fields is the "view" permission for each role. Have you had a look at that? When you say "i have a content type which has a field added to it" do you mean to say a custom CCK field? -- Just wanted to clarify that.

An addtional issue is that you can perhaps see the data for a field in a node but when it's in a view you can't. I am willing to wager there is an issue with the way the view is set up so not so much a permission issue as an issue with the view.

af199’s picture

Hi there & thanks for the reply.

As always, a couple of things i should have mentioned to start with...
- i am currently logged in as uid = 1. :(
- I do indeed have a custom CCK field, in this particular case a 'date' field.
- the global settings for this field ( manage fields, then configure the field in question ) shows Field permissions to be ticked for "Edit Date, regardless of node author.", "View Date, regardless of node author.", "View own Date on node created by the user."
- The 'display fields' for this content type do not have the 'exclude' box ticked when looking at this field.
and lastly
- although the field isn't visible in a view, its also not visible when looking at the node by itself, ie node/308.

I'm really at a loss here.

danny englander’s picture

Can you check one more thing?

Go to edit your content type and look at the "Display Fields" area and see what it says for the custom CCK fields?

It's located at:

admin/content/types/[your content type]/display

and see what it says for "Basic"? Is anything set to be hidden?

Also are you using any custom .tpl.php pages that perhaps are not rendering your custom CCK fields?

af199’s picture

Have checked those settings and on the Basic page all of the fields either show 'inline' or 'above', none of them show ''. Unfortunately i've not created any .tpl.php files that might be rendering these differently.

Really appreciate the help.

danny englander’s picture

I guess as another test, can you create a new content type from scratch and then a custom field for that type, then create a node from the newly created type and see what happens. Probably a wild goose chase but worth a shot.

af199’s picture

Nice Idea but unfortunately i got the same result with the new content type as i did with the old - specifically i can edit the field, but i can't see it when looking at the node.

af199’s picture

I'm still working on this issue and in sheer desperation i've created another field which i've added to both an existing content type as well as the new 'test' content type which i was advised to create in one of the previous comments. Unfortunately although once again i'm able to set the field, i'm not able to view the entry in either a view or when looking at the node itself.

One perhaps possible issue is that i've noticed when i go to -> admin/settings/date-time/formats -> then the drop down for ALL of the format options are empty. I say empty, but there is no values in the drop down fields even though the length of the lists seem to be correct. Could this just be a formatting issue ?