Gossamer Forum
Home : Products : Links 2.0 : Discussions :

Strip those ugly underscores

Quote Reply
Strip those ugly underscores
Hi there... a Perl newbie here.
How [and where] do I strip those ugly underscores from category
names in the category combobox in add.pl?

Thanx in advance.



Quote Reply
Re: Strip those ugly underscores In reply to
Hi

Underscores - I take it you mean the underline for links, easy select no underlining in your browser.

Or make a css and use the tag

text-decoration:none

you could add this into the existing css file



DavyC
http://www.amijet.com
Life's more fun in a virtual world
Quote Reply
Re: Strip those ugly underscores In reply to
I suggest you read the question again as that is not what dindondan meant.


Paul Wilson.
http://www.wiredon.net/gt/
http://www.perlmad.com/
Quote Reply
Re: Strip those ugly underscores In reply to
DavyC, not at all.

Underscores are special chars in directory names in place of spaces: I just don't want them to appear in the combobox in add.pl or whenever the category=directory name is written to a page.

Ex: http://www.tren.to/cgi-bin/linkz/add.pl
Ex: http://www.tren.to/Viaggi_e_turismo/Aree_turistiche/

Thanx anyhow, :DTM.


Quote Reply
Re: Strip those ugly underscores In reply to
Use the following codes in your sub site_html_add_form, and sub site_html_add_error in the site_html_templates.pl file:

--------------------------------------------------------------------------------

my $category = shift;
my $clean_category = &build_clean($category);
$category ?
($category = qq~$clean_category <input type=hidden name="Category" value="$category">~) :
($category = &build_select_field ("Category", "$in{'Category'}"));

--------------------------------------------------------------------------------

Then define "Category" tag in the following manner:

--------------------------------------------------------------------------------

Category => $category

--------------------------------------------------------------------------------

in those subs mentioned above.

(Thanks to AnthroRules)

Mapo
Links Installer
http://www.youthresources.com/services/index.html
Quote Reply
Re: Strip those ugly underscores In reply to
Thanks a lot, Mapo.
That does not work for the combo, though. Ciao, :DTM.