I want to create a widget for WordPress that anybody can use (for free) which contains some entertaining content (like a gadget for iGoogle in earlier times).
What I did not find out:
Can a (custom) widget be public/listed, so everybody using WordPress can see and use it?
Or do I need to create a plugin in order for other WordPress users to see and use it?
Since I want to let the users decide, where to put this additional content, how can I achieve this? (i.e. integrate this widget behaviour into a WordPress plugin?)
The basic idea is that we have some interesting content, we want to spread on WordPress for free.
It's up to you wether you want to create you widget through you theme (eg: via functions.php) or via a plugin. If you would like everyone to use it independently from a theme, then the best idea would be to do it through a plugin.
Here is a simple tutorial that explains the pieces of code you need to include either in your theme or in a new plugin to create a Widget accessible via the WordPress's widgets panel: http://www.wpbeginner.com/wp-tutorials/how-to-create-a-custom-wordpress-widget
Related
I have a sidebar (test-sidebar) that contains widgets with custom posts.
How can I can get posts from sidebar (widgets)?
I don`t want render post only get their IDs
I am using WordPress Version 4.9.6
In short, you can't with the built in WordPress widgets.
You will need to create your own widget using the WordPress Widget API. From there you will be able to develop a widget to complete whatever task you want. Otherwise it will be a trip to the WordPress plugin repo to see is someone is sharing a plugin doing what you want to do.
On a side note, you may also want to look at building a custom WP Query. This will allow you to pull in whatever posts you want and then manipulate them however, within the body of the page.
I am trying to implement a simple one page -no blog- WordPress theme using a bootstrap template. I have an aside with three social links -facebook, twitter, Instagram- in the header.
I want to be able to make it so not only are these able to put truned on or off in by the user through the wp admin dashboard, but also the links to those sites able to be put in through said dashboard.
I am using udnerscores as a starter theme. How do I go about doing what I am looking to do?
This can be achieved using the Customizer API. That would be my recommendation. There is a lot of really good documentation on how to use that here. It also includes a whole bunch of sample code. Give that a look.
I need to build a dashboard that will allow users to sign in/out and access/update their business account information.
WordPress has its own dashboard for publishing content but this is not what I am looking for.
Would it be easier for me to create a second site using a framework (Ruby on Rails) that makes this type of user access easier? Or is there a solution in WordPress that I am unaware of?
You can easily customize the existing WordPress dashboard. The items shown on the dashboard are determined by the function current_user_can(), so you can hide items by restricting the capabilities of the user using the function add_role(). You can add your own items by the function add_submenu_page().
It has been a while since I customized the WordPress dashboard but if I remember correctly I also had to use JavaScript and CSS to dynamically modify the DOM but this may be because I was doing something unusual. Anyway I think it was quite easy to do.
you can check out the following wordpress plugin for your requirement
https://wordpress.org/plugins/client-dash/
I want to add a google maps widget to Pages on a Wordpress site. They all have the same Template with a Sidebar but the map will be unique for each. I feel like there should be a way to populate the widget from the edit page screen for that Page. Does each Page actually need it's own Template?
This seems limiting maybe I'm missing something. If the question is unclear I let me know but I think this should be something ppl have run up against before.
I would suggest the integration of a wordpress plugin to accomplish this. It will be fairly easy to do.
If you want to do this without purchasing any 'pro' versions of a plugin and don't mind writing some simple code, then I would suggest Simple Google Map. You will have to insert a shortcode into the widgetized sidebar area. Here is the plugin link - http://wordpress.org/extend/plugins/simple-google-map/
In order to customize each page's sidebar area, You need to write some code. Please refer to this article which will explain how http://www.wpbeginner.com/wp-themes/display-different-sidebar-for-each-post-and-page-for-wordpress/
It involves a simple alteration of your 'single.php' file and the usage of 'custom fields' so that you will be able to do this from the edit screen of the page, just like you wanted to do!
Use a plain text widget for each map and Widget Logic to select the page it appears on: WordPress › Widget Logic « WordPress Plugins
I know how to hardcode categories, archives, etc into theme but for one of my projects i would have to hardcode some plugins widgets (especially subscribe2) and i'm not sure how to do this. I know i can add widgets via widgets menu in wp admin, but that's not what i'm trying to achieve, i'm trying to set it up permamently in theme for later reuse. How to do this? Especially with subscribe2?
You can add the widget via the normal means, and check the code on the site using View->Source.
Then, you need to edit the html template for the theme (depending on where you want the widget to appear - main entry, sidebar.html, etc) and add the code there directly.