[theme-reviewers] How to Implement CSS Dependant on User Input?
Srikanth Koneru
tskk79 at gmail.com
Sun Sep 15 06:07:35 UTC 2013
You are allowed to output css code. Create a function and hook it to
wp_head.
On Sun, Sep 15, 2013 at 11:35 AM, Rohit Tripathi <rohitink at live.com> wrote:
> Most themes implement a functionality, where users are allowed to select
> link colors, and other features, etc for their themes. But, WordPress
> requires all stylesheets to be enqueued, and I assume we can not pass .php
> files in the wp_enqueue_style(); function.
>
> So, What is the Suitable way to implement this?
>
> One way would be to create multiple stylesheets, and load the one user has
> selected. But, what if I want to implement a feature, where user can
> provide the hex value for the link color. What to do then? I can not write
> <?php get_option('link_color') ?> in the .css files. I will be forced to
> hardcode it somewhere in the theme.
>
> _______________________________________________
> theme-reviewers mailing list
> theme-reviewers at lists.wordpress.org
> http://lists.wordpress.org/mailman/listinfo/theme-reviewers
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.wordpress.org/pipermail/theme-reviewers/attachments/20130915/ca7fc1bb/attachment.html>
More information about the theme-reviewers
mailing list