Gossamer Forum
Home : Products : Gossamer Links : Development, Plugins and Globals :

[ ULTRAGlobals ] Format_Select_Field

Quote Reply
[ ULTRAGlobals ] Format_Select_Field
what to make Format_Select_Field to come it selected the value of the Default field in the form od Add page?
Quote Reply
Re: [Janio] [ ULTRAGlobals ] Format_Select_Field In reply to
Should be a simple fix. Just find this in /Plugins/ULTRAGlobals.pm

Code:
sub Format_Select_Field {

...and then find:

Code:
my $schema = $DB->table('Links')->cols;
my $field_vals = $schema->{$field};

...add this below it:

Code:
my $default = $field_vals->{default};
$current_value ||= $default;

Untested, but should do the trick

Cheers

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Quote Reply
Re: [Andy] [ ULTRAGlobals ] Format_Select_Field In reply to
works fine.


thank you very much.