• Resolved viwiv

    (@viwiv)


    Hello. I look for a way to use conditional tags in Widgets, without using “Widget Logic”.

    So, in ‘function form($instance)’, I use a field ‘$conditional’. In Widget Panel, I use a value example like ‘if (is_single())’.

    Before ‘echo $before_widget’, I write ‘if ($conditional)’: my script verifies the condition (‘yes’/’no’), but does not apply it! The value of ‘$conditional’ passes correctly, because I can display it in Widget to test.

    Any help would be greatly appreciate. Thank you.

    Vincent

Viewing 1 replies (of 1 total)
  • Thread Starter viwiv

    (@viwiv)

    Hello,

    1. I am sorry for the spelling mistakes in the title of the question.

    2. I eventually found my personal, but functional solution, to implement the conditional tags in Widgets of my theme under construction. ??

    So my problem is solved.

    Thank you.

    V.

Viewing 1 replies (of 1 total)
  • The topic ‘Condtional tags in Widget’ is closed to new replies.