Create a simple widget

The correct question would be “how to create a widget”? No code was initiated. I recommend reading this tutorial: Building Custom WordPress Widgets Anyway… your widget: class widget_simple extends WP_Widget { // Create Widget function widget_simple() { parent::WP_Widget(false, $name=”Custom Simple Widget”, array(‘description’ => ”)); } // Widget Content function widget($args, $instance) { extract( $args ); … Read more

wordpress widgets screen disappeared

This is both a change in WordPress core in 3.5, and a problem specific to your commercial Theme. In WordPress 3.5, if a Theme does not register support for dynamic sidebars (i.e. Widgets), then the WP-Admin does not display the Appearance -> Widgets admin page. So, if the behavior changed between WordPress 3.4 and 3.5, … Read more

New loop vs widget

You should always use widgets when you need to add any kind of content to the sidebar. The reason is very practical – once the project is over the owner of the site will not need to contact you just because he wants to put a banner before your “loop”, and even during development it … Read more

Contact information footer

Another option is to create a new post type called “modules” or something to that effect. Then you can create as many of those as you like, for example, “Footer: Contact Information,” “Footer: Social Media,” “Header: Callout,” etc, and you can use that post’s ID to bring it into the designated spots in your template. … Read more

Remove “Content” and “Discussion” from Right Now Dashboard Widget

Here are two methods: Method 1 You could remove the whole Right Now metabox from your dashboard: function custom_dashboard() { if(!current_user_can(‘manage_options’)){ // only remove it for non-admins remove_meta_box(‘dashboard_right_now’, ‘dashboard’, ‘core’); } } add_action(‘admin_init’,’custom_dashboard’); and then add another custom Right Now metabox with your custom code. You could for example check out the WordPress function wp_dashboard_right_now() … Read more

wordpress widget missing jquery

Your first two problems: $ and jQuery is not defined. $ is just an alias for jQuery. Your first two problems are the same with different names. I think you do not write a plugin or a function in your functions.php. I think you put your code simply in the template file and expect that … Read more

Sticky menu for WP custom menubars

What you could do is the following: 1) Make a javascript-file and put the following content into it: $(function(){ var stickyHeaderTop = $(‘#stickyheader’).offset().top; $(window).scroll(function(){ if( $(window).scrollTop() > stickyHeaderTop ) { $(‘#stickyheader’).css({position: ‘fixed’, top: ‘0px’}); } else { $(‘#stickyheader’).css({position: ‘static’, top: ‘0px’}); } }); }); 2) Save this file in your theme folder as (for example) … Read more