Support » Plugin: YOP Poll » Multiple bar colors

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author YOP

    (@yourownprogrammer)

    Hello

    Please send us a link with a poll so we may assist.

    Best
    YOP Team

    Hello,

    I am using the basic white theme with slightly edited styling. All I need now to do are the multiple colors.

    Url

    Plugin Author YOP

    (@yourownprogrammer)

    Hello

    Edit the template you are using for your poll and in the css section add the code below

    #yop-poll-answer-%POLL-ID% {
     display:inline !important;
    }
    #yop-poll-result-bar-div-1{
     background-color: blue !important;
    }
    
    #yop-poll-result-bar-div-2{
     background-color: red  !important;
    }
    
    #yop-poll-result-bar-div-3{
     background-color: yellow !important;
    }
    
    #yop-poll-result-bar-div-4{
     background-color: green !important;
    }

    Let us know if it does the job.

    Best
    YOP Team

    Yes it does but unfortunately I have to consider polls with less or more options so this solution works only with 4 options that change colors.

    I am thinking more about:
    – choose a color for each bar, or select options for red and green color
    – ability to set that number somewhere in the settings

    I thought that I would create a option field right in the poll editor (is there a wp filter to add a new option?) which would generate a CSS output via PHP that would be placed right in the <head> as <style>.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Multiple bar colors’ is closed to new replies.