Home>Support>Custom widget don’t appear on my front end

Custom widget don’t appear on my front end

Notice: This thread is over two years old; the information may be outdated. Please consider creating a new thread if you require free support. If you have an active SiteOrigin Premium license, you can email our premium support desk at [email protected].

Hello
I started to create my custom widgets, most of elements looks good, I can use my widget, I can enter text etc.
But I have nothing on my page after add it for my site. My first widget should show me just H1 with given text. So, can you suggest me any resolution for this problem?

This is our free support forum. Replies can take several days. If you need fast email support, please purchase a SiteOrigin Premium license.

  1. 6 years, 4 months ago Alex S
    Hi, I Work Here

    Hi Paweł,

    Are you using the SiteOrigin Widgets Bundle to create your widgets?
    If you are, please give the section on HTML Templates a read.

    If you aren’t, I would take a look at a few tutorials on developing WordPress widgets as they’ll outline how to output widget data.

  2. 6 years, 4 months ago Paweł Kobylarski

    There is all, that i have

  3. 6 years, 4 months ago Paweł Kobylarski

    There is all what I wrote (at the left, you can see my folder structure – its default)

  4. 6 years, 4 months ago Alex S
    Hi, I Work Here

    Hi Paweł,

    The code in the provided screenshot looks correct. Can you please send me the complete plugin so I can run some tests against it?

  5. 6 years, 4 months ago Paweł Kobylarski

    Of course, can I send by dropbox? It’s a link: https://www.dropbox.com/s/5emevgtt8bmjwan/hello-world.zip?dl=0

  6. 6 years, 4 months ago Alex S
    Hi, I Work Here

    Hi Paweł,

    Thanks. The siteorigin_widget_register function needs to pass a valid widget id to function correctly. The widget id you’re setting isn’t correct. Please change:

    siteorigin_widget_register('hello-world', __FILE__, 'Hello_World_Widget');

    To:

    siteorigin_widget_register('hello-world-widget', __FILE__, 'Hello_World_Widget');
  7. 6 years, 4 months ago Paweł Kobylarski

    So stupid mistake :P

    You are awesome, thank you so much :)))

  8. 6 years, 4 months ago Alex S
    Hi, I Work Here

    Hi Paweł,

    No worries mate. Great to hear it’s working without issue for you now! :)
    Please be sure to post another thread if you have any other questions.

Replies on this thread are closed. Please create a new thread if you have a question, or purchase a SiteOrigin Premium license if you need one-on-one email support.

Get The Most Out of SiteOrigin with SiteOrigin Premium

Find Out More