Gossamer Forum
Home : Products : Gossamer Links : Discussions :

Edit_Case global

Quote Reply
Edit_Case global
Who can I use the Edit_Case in a global in the detales page, something g like
<%Edit_Case($Title) %>

to display in every word first sign as upper "Aaa Bbb Ccc"
Quote Reply
Re: [nir] Edit_Case global In reply to
Not sure what you mean? You want a global that will convert a string from "abbbb Bbbbb cbbbb" into "Abbbb Bbbbb Cbbbb" ... etc?

If so, try this:

lowercase_and_capatilize
Code:
sub {
my @string = split /\s+/, $_[0];
my @back;
foreach (@string) {
$_ = ucfirst(lc($_));
push @back, $_;
}

return join(" ", @back);
}

Then call with:

<%lowercase_and_capatilize($Description)%>

..or whatever field you want.

Cheers

Andy (mod)
andy@ultranerds.co.uk


IMPORTANT: I've now moved to ultranerds.co.uk, and the .com will no longer work!
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package (plugins total "value" $3,325 & rising, for just $350)| GLinks ULTRA Package PRO (plugins total "value" $5,625 & rising, for just $500)
Support Forum | Links SQL Plugins | DMOZ Dumps | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Compare our different Plugin packages *new* Free CSS Templates
Quote Reply
Re: [Andy] Edit_Case global In reply to
Thank for that