• Resolved dogeofshibe

    (@dogeofshibe)


    Hi Jeroen,

    I read your FAQ and I understand that .name_directory_name_box refers to the individual name boxes of the entries. However, I am having trouble with styling the font colours for each individual unique box entry. Take this site in your FAQ for example: https://goutu.org/cuisine-alimentation/lexique-de-cuisine/ the first box says “Appareil
    Préparation servant de base à la confection d’une pâte.”

    and the second box is

    Beurre en pommade
    Beurre ramolli jusqu’à prendre la consistance d’une pommade.”

    How do I make the first box RED and the second box BLUE for example?
    I tried using child selector in CSS to select there 2nd, 3rd child from the .name_directory_name_box element but it breaks whenever users search for the actual box since it takes the absolute child instead of changing the actual box in the database.

    Sorry If im not clear enough, and also thanks it advance!
    Also just gave you some coffee money in donation for the wonderful widget (=

    • This topic was modified 6 years, 3 months ago by dogeofshibe.
    • This topic was modified 6 years, 3 months ago by dogeofshibe. Reason: Formatting for clarity
Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Jeroen Peters

    (@jeroenpeters1986)

    Hi @dogeofshibe,

    Thank you for your kind words and your donation. I am really glad that you did!

    Just to check, you stated that you used CSS colors. Didn’t this work, or do you want every name to have their own color (no matter if a users searched).

    Kind regards,

    Jeroen Peters

    Thread Starter dogeofshibe

    (@dogeofshibe)

    Hi,

    The colouring worked, but however, what I want is exactly what you mentioned, for every name to have their own colour (no matter if the user is searched). For example, I want the 1st listing to have red and if I typed in the first listing in the search box it will bring out the first listing that is red. If I coloured .name_directory_name_box red with CSS it will just repeat red for the entire directory.

    Plugin Author Jeroen Peters

    (@jeroenpeters1986)

    Hi @dogeofshibe ,

    thanks for your answer. At the moment, that is not possible without custom work. The classes are all automaticaaly named, but do not take any other parameters into account. The way I see it there should be an extra field per name where you can set the class it needs to generate on the frontend.

    If you know PHP this could be a nice thing to create yourself. The source is free to use. I can do it too if you need it for a commercial project. But the feature would be too specific for use in this version of Name Directory. I like to keep it a simple plugin and the current version seems to suit people very well.

    I’m sorry I don’t have a better answer for you. Let me know if you have any other questions offcourse!

    Kind regards,

    Jeroen Peters

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Customizing Nameboxes with CSS’ is closed to new replies.