How to create widget
-
I want to create a sidebar from GreatFire.org (to appear as the last widget on my sidebar). It says to “Paste this code anywhere on your website to create a widget, but instead of this website, the widget will automatically display the latest status of your website [in China]: blocked, restricted or fine”:
<div class=”widget24372835796″ data-widget-type=”gf_this_site”></div>
<script type=”text/javascript”>
(function() {
var ns = document.createElement(‘script’);
ns.type = ‘text/javascript’;
ns.async = true;
ns.src = ‘https://s3.amazonaws.com/all_widgets/widget.js’;
var fs = document.getElementsByTagName(‘script’)[0];
fs.parentNode.insertBefore(ns, fs);
})();
</script>The blog I need help with is: (visible only to logged in users)
-
Hello there,
This type of code will not work on a WordPress.com site. It cannot be installed.
You can create a widget here at WordPress.com, but it won’t have the same functionality.
Here’s information about how to create widget:
http://en.support.wordpress.com/widgets/create-your-own-widget/If creating your own widget at WordPress.com doesn’t work, and this widget is important to the functionality of your site, you may consider self-hosting your site via another server. If you aren’t yet familiar with the difference between WordPress.org and WordPress.com, here are some details:
http://en.support.wordpress.com/com-vs-org/Please let us know if you have any other questions. Thanks much!
- The topic ‘How to create widget’ is closed to new replies.