Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

(OT) How to apply style (font color, etc) to button

by anbutechie (Sexton)
on Aug 28, 2009 at 11:42 UTC ( [id://791884]=perlquestion: print w/replies, xml ) Need Help??

anbutechie has asked for the wisdom of the Perl Monks concerning the following question:

This node falls below the community's threshold of quality. You may see it by logging in.

Replies are listed 'Best First'.
Re: (OT) How to apply style (font color, etc) to button
by Fletch (Bishop) on Aug 28, 2009 at 12:10 UTC

    As with the other two questions you've posted this morning in rapid succession it has pretty much nothing to do with Perl and very minimally anything to do with CGI. You need to actually bother to read the information people have suggested to you about CSS and maybe look at the documentation for the -style parameter to the HTML generation subs in CGI. However it's better practice to separate presentation (the HTML) from code and use something like Template Toolkit instead which makes this even less of a Perl problem.

    The cake is a lie.
    The cake is a lie.
    The cake is a lie.

Re: (OT) How to apply style (font color, etc) to button
by Gangabass (Vicar) on Aug 28, 2009 at 14:22 UTC

    Just add id or class attribute to your button element and add this rules to your CSS:

    /*this is for id*/ #yourID { color: green; ....; } /*this is for class*/ .yourClass { color: green; ....; }
Re: (OT) How to apply style (font color, etc) to button
by Sinistral (Monsignor) on Aug 28, 2009 at 15:12 UTC
Re: (OT) How to apply style (font color, etc) to button
by marto (Cardinal) on Aug 29, 2009 at 08:55 UTC

    I'd suggest removing HTML from Perl by using something like HTML::Template. This means you can edit the HTML/CSS/JavaScript in the template files as normal, then populate it with dynamic data using HTML::Template within your Perl code.

    Martin

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://791884]
Approved by planetscape
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (4)
As of 2024-03-29 02:11 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found