Themes create the public (front-end) interface for a WordPress site.

learn more… | top users | synonyms

1
vote
1answer
479 views
0
votes
1answer
4k views

How to add “Template” option in page attributes panel?

I am new in WordPress. In my theme, I do not have "Template" option in 'Page Attributes panel'. I want to add this option. I tried to solve this problem from the following post. But It did not work ...
0
votes
1answer
12 views

Filter URL and shortcodes from the_excerpt

I just noticed a weird behavior on a theme I'm working on. If I have a post with just one link or shortcode, the_excerpt will print that URL or shortcode. But if I have some text in the post, below or ...
0
votes
1answer
12 views

Changes to template not showing up unless ?reset=1 added to URL

As title states, I added something to a template file: echo '<img src="'. get_site_url() . '/wp-content/themes/enfold/images/leverage.png" />'; But on firefox and IE, the addition won't show ...
-3
votes
0answers
13 views

How to create a drop down field in custom theme option menu? [on hold]

I am making a theme in wordpress and want to add some fields to the option menu example: dropdown,Text fields etc. but i want to do it using array like: $options = array ( array( "name" => ...
4
votes
4answers
644 views

Any walker causes blank menu?

Using the following, or any other custom Walker_Nav_Menu seems to cause a blank navigation menu, I tried specifying the default to make sure I wasn't going crazy yet it still blanks the output... Any ...
0
votes
1answer
17 views

Check if redirected from a specific page template

I have a page template, which redirects to the homepage using this: wp_redirect( home_url() ); Now, on the homepage is it possible to check if it has been redirected from a specific page template ...
0
votes
1answer
18 views

Wordpress pulling in random page themes

I have a website that has multiple custom templates -- a variety for pages and a couple for custom post types. However, WP is now screwing it all up. For instance: All of the pages that were setup ...
0
votes
1answer
26 views

Let user to add input fields on theme option page

I'm creating a Theme Option page for my own wordpress theme and I've been trying to create something like this on my option page It means my user(admin) can add any number of input fields (in this ...
1
vote
1answer
37 views

Prevent theme from activating [duplicate]

I am working on a theme that runs code only once on theme activation (using the after_switch_theme hook). I am wondering if it's possible to safely prevent my theme from being activated if certain ...
0
votes
2answers
16 views

wp_post->post_parent object returning 0

I'm developing a Wordpress theme and I've registered a new menu location (called primary menu) and am using a menu with it. In my menu, I have a page called "tier-2 page" under a page called "tier-1 ...
0
votes
2answers
408 views

Creating a Link Text like Submit Button in Admin Page

I'm making an admin page for my plugin and I'd like to make a text link designed like the form button of admin pages. I tried this but didn't work well. <a href="" cless="button-primary" ...
0
votes
1answer
491 views

How to add menu support to a theme?

I tried few tutorials. All i think is i should use register_nav_menus() and then add the menu in header.php Here is the code i tried in functions.php from this help site itself function ...
0
votes
0answers
23 views

Let users to add any number of input fields in the theme option page

I've been creating a custom settings page for my own theme according to this article. What I want to know is how to let users to add any number of input fields. Just like this image I have ...
2
votes
2answers
263 views

Easy WordPress theme creation tutorial? [closed]

I've been looking for a truly simple wordpress theme creation tutorial and haven't been able to find one. I'm specifically looking for something with sample code, a basic introduction to the syntax, ...
0
votes
2answers
393 views

How to add icon over specific thumb

I wanted to do the following, and I know its possible, but I don't know how. I'm looking at in_category, but it doesn't make to much sense. Basically what I want to do, for an example on my homepage, ...
0
votes
1answer
22 views

Following/tracing page construction through theme PHP

What tools and methods will allow me to figure out how a page is being constructed by WP? I have a mix of plugins that are involved in the theme, and starting with the code I can't begin to figure ...
0
votes
2answers
2k views

Get the blog page URL set in Options

I have set the blog to be a different page other than the home page. I want to have a link from single.php to this blog page. Is there any function that pulls out URL for the blog ?
0
votes
0answers
21 views

Iframes are not being showed in customized theme

I've build a customized theme with the client website layout based in twentyten but none of the iframes are being showed. An example can be seen in ...
1
vote
0answers
15 views

Add custom buttons with custom actions in Edit Post screen in WordPress?

I am creating something for a client and I have a Class that I created with a Custom Post Type called 'PuSH Feeds' and when the user adds a new post and publishes it they can then click on one of two ...
-2
votes
1answer
38 views

Learning WordPress Themes [closed]

I would like to learn how to develop a WordPress theme. I've read all the Ressources available : - Book : Wicked WordPress theme (don't remember the exact name) - Codex - Themeshaper - Seen tuts+ ...
0
votes
1answer
18 views

Trouble in enquing all js files under certain directory

I am using _s theme .I have all js files under js folder.My code function _s_scripts() { $js_dir = get_template_directory_uri() . "/js/"; foreach(glob($js_dir.'/*.*') as $file) { $label = ...
0
votes
3answers
41 views

Custom meta box in custom post type not working

As a wordpress newbie I am having problems in adding custom meta box in my "slider" custom post type which I used in some old wp theme. I'm getting a warning: Warning: call_user_func() expects ...
0
votes
0answers
15 views

WordPress Dev Training from the ground up [closed]

What is the best place for a developer who wants to build WordPress themes to start? Are there recommended training programs, tutorials, etc the community recommends or is the CODEX the place to go?
0
votes
1answer
24 views

html5-reset theme does not show the image [closed]

I am started to create a custome theme based on the HTML5-reset theme that a downloaded from GitHub. before touching/modifying anything, just I tried to put an image under the get_header(); and above ...
0
votes
1answer
21 views

Custom HTML structure in wp_list_categories

I am trying to accomplish an Ajax navigation for the categories and for that I need the code to look something like: <ul> <li data-level="1">Parent Category</li> <li ...
3
votes
1answer
676 views

Registering Sidebars and Sidebar Widgets. Sidebar Widgets Not Displaying

I am registering sidebars and sidebar widgets. The theme currently supports two sidebars. Primary and Secondary. add_action('widgets_init', array($this, 'add_sidebars'), 10, 2); public function ...
0
votes
0answers
15 views

Display backend function to frontend?

Hello senior developers i have a problem to display to fontend.. //register settings function theme_settings_init(){ register_setting( 'theme_settings', 'theme_settings' ); } //add ...
0
votes
1answer
20 views

Plugin's required JS not being inserted in my theme

All my plugins and their necessary .js files aren't being inserted in my theme's head. The CSS files are being inserted ok, but not the .js files. Not sure what's wrong. When I switch to a default ...
0
votes
0answers
122 views

How To Display Value from Theme Options Field in Front End Template?

I put this code into my functions.php https://gist.github.com/corvannoorloos/4703066 and it work nice. Now I want to display value from Sample Select Options filed in some front-end templates. How ...
0
votes
2answers
21 views

WordPress HTML5 Gallery Support - Convert HTML4 -> HTML5

As of WordPress 3.9, WordPress generates HTML5 Galleries if HTML5 is supported in the theme: add_theme_support( 'html5' ); Originally in my theme development I did not declare HTML5 support and ...
0
votes
0answers
188 views

Why does has_nav_menu return false when get_registered_nav_menus shows the opposite?

I'm working on a new theme to replace an old one. The existing theme has custom menus and I can't figure out why in my new theme a call to has_nav_menu is always coming back false. In my ...
1
vote
1answer
13 views

Wordpress empty Nav Menu error

i have created Multisite. i have assigned menu for the first sub domain while for the second sub domain i have not assigned Menu. i just enabled the Debug mode and got Following error: Notice: ...
2
votes
2answers
544 views

How to export/import theme customizer settings?

I am wondering if it is possible to export theme customizer settings(theme_mods) to be imported into another install of the same theme. I know that the settings are saved into the database so I am ...
0
votes
1answer
27 views

How exactly *does* unit testing work for themes?

As the majority of material on unit testing focuses on plugin development rather than theme development, I've hit a stumbling block when trying it out for myself. I've installed PHPUnit, grabbed the ...
6
votes
2answers
14k views

How to get the path to the current theme?

This code is used to get the directory of the current plugin: plugin_dir_url( __FILE__ ). What should I use to get the directory of the current theme?
0
votes
0answers
27 views

archive.php not showing the last post queried [closed]

I have this rare issue. When I visit archive page for a category, it shows all posts but not the last one. If there is only one post in the category, it does not shows any entry. I tried with the ...
0
votes
1answer
21 views

Managing Wordpress Theme

A Wordpress theme has following components: theme.zip file demo-content.xml PSD.zip file (contains files such as icon-blog.psd, icon-home.psd, integrity-blog.psd, ... renew-home.psd) Using WP ...
-1
votes
0answers
52 views

Defer loading of Google Analytics Javascript Code [closed]

The below code is what Google recommends. I placed the code in my footer.php just before the </body> tag (near the bottom of the file) to load my self hosted analytics.js (myga.js) code. This ...
1
vote
1answer
279 views

WP Customize refresh problem

Hi I am adding options to WP Customize. Mostly everything works, but One of my variable is not refreshed in the preview window. $wp_customize->add_setting('checkbox', array( 'capability' ...
1
vote
1answer
26 views

Display a list of certain categories by ID

I have a list of custom taxonomy IDs like (1, 2, 3, 10). I want to display a list of these specified categories by names and each should have its childs like: Europe France Germany Africa ...
1
vote
1answer
2k views

Debugging an error: wp_enqueue_style was called incorrectly

I've just uploaded a new, custom theme to find that the container is a fraction of the intended width, and the sections below the home section(this is one single page, long site utilizing ids/anchors ...
2
votes
2answers
1k views

Get category slug and display it on a query_post

I just read "How to create option page for wordpress theme" in wp.tutsplus.com - I have a problem with getting categories . there is two parts to my question - Part A - Get category slug and ...
1
vote
2answers
477 views

redirect does not work in ajax function

I'm using ajax to post the form data. In the end I want to redirect to homepage. I'm trying following code, it does not work. It returns error 302. How can I redirect in the following function? ...
0
votes
1answer
12 views

How to add drop symbol to parent nav items which have child

I have a navigation system like this: As you can see I have two Parent Menus as "Projects" and Plans which they have some sub menus. Now when the result rendered I am getting a navbar like this: ...
0
votes
0answers
28 views

How to convert a theme to responsive? [closed]

My client wants to convert an old theme into responsive. They are using 3.6 version of WP. Their theme is either completely custom built or based on one of the "Twenty xxx" themes - I'm not too sure ...
1
vote
2answers
529 views

Custom header images won't appear when set to random

I'm using a custom theme, developed from Boilerplate (some time ago). I noticed that the header images work fine when set statically, but fail to appear when set to random. I tried switching themes, ...
0
votes
1answer
1k views

How do I implement jPanelMenu?

I have serious problems trying to implement jPanelMenu to the theme I'm building. The theme is nearly finished, I'm just trying to figure out this menu and I can finally start using it. Anyways, if ...
0
votes
4answers
67 views

Theming Using Bootstrap Glyphicons and WordPress Dashicons

I use a mixture of both Bootstrap Glyphicons and WordPress Dashicons in my WordPress themes. However, something which really bugs me is how the WordPress Dashicons don't seem to scale appropriately ...
2
votes
2answers
460 views

Add custom field to existing meta box?

First off, I have been able to successfully implement custom fields within a custom meta box in Wordpress. I understand how this works. My question is, is there a way for me to add a custom field to ...