Closed (won't fix)
Project:
Content Taxonomy
Version:
5.x-1.x-dev
Component:
Documentation
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
5 Sep 2007 at 17:31 UTC
Updated:
1 Sep 2010 at 10:16 UTC
Jump to comment: Most recent file
Comments
Comment #1
armand0 commentedNobody?
Cannot one make?
or does perhaps nobody know how?
Comment #2
armand0 commentedFor Taxonomy Field (active select) maybe:
and anything works me. I hope somebody gives me an example of like it should be the syntax.
Thank you
Comment #3
jhedstromI solved this problem by returning an array of this form:
// for example, if I want tid 44 as the default:
return array(array(44 => 44));
This seems contrary to the description presented by cck:
array(0 => array('value' => value for value),
...
);
so I don't know if this is a bug in content taxonomy or not. I traced the problem all the way to the content_taxonomy_options_widget() function, where it calls array_keys to get the value, rather than looking for an array element "value"...
Comment #4
sittard commentedThis worked for me:
global $user;
return array(
0 => array('value' => $user->mail)
);
Comment #5
jeff h commentedI can vouch for jhedstrom's post in #3... can we get the help text changed to reflect reality? :)
Comment #6
Vuds commentedJust to let documented (because this one was giving me pain to be found),
The PHP Code Default Value that works with CT Autocomplete field widget is
return array (array ($TID => taxonomy_get_term($TID)));Comment #7
magnus commentedCleanup of old issues. According to maintainer: "active development is only done for the 6.x branch! 5.x is not supported any more".
Open a new issue if problem still exist.