Support » Plugins » How could I go about using Snippets with my stylerheet?

  • How would i go about converting my stylesheet to a .php file from a .css file and then placing the snippet code within stylesheet to be able to dynamically change the css vales?

Viewing 1 replies (of 1 total)
  • This isn’t working?
    1. I renamed my stylesheet to style.php
    2. I then changed this in the header too
    3. I created a snippet called “name1” and gave it a value of “red”
    4. I placed this code in the style.php as below…

    #headerleft h1 {
    	font:32px Georgia,Times New Roman,Trebuchet;
    	color: <?php snippets_value( 'name1' ); ?>;

    5. I get this error message in my style.php

    <b>Fatal error</b>: Call to undefined function snippets_value() in <b>/home/abc/public_html/abc/wp-content/themes/xyx/styles/stylen.php</b> on line <b>12</b>

    6. none of my style.php now works (it worked without the snippet code)

    Any hints in what i need to do to get the snippets to work in my style.php file?

Viewing 1 replies (of 1 total)
  • The topic ‘How could I go about using Snippets with my stylerheet?’ is closed to new replies.