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

learn more… | top users | synonyms

0
votes
2answers
36 views

Problem dynamically generating an all purpose title tag

The code (below) works fine on all pages but front-page.php in WordPress. Specifically, it adds an extra pipe symbol to the beginning of the title tag. For example, if the following is the homepage ...
1
vote
3answers
48 views

Show excerpt for only first post in query

I'd like to only show the excerpt for the first post in my main query. I was wondering the best way to approach this. What I have tried so far is: Making a custom homepage and using two queries, ...
-2
votes
1answer
23 views

how to move a widget from theme 1 to theme 2?

I bought two themes for two websites but now I can't buy the domain name and host for both and decided to run just one web I try my two theme 1-metro mag 2-Glider I decided to run Glider at least but ...
0
votes
1answer
44 views

Custom Wordpress Theme: Publish Date and Display Date for posts right beside each other

What's currently happening is that for posts that have an 'update' time, the original publish and editor dates are rendering side by side (with no extra information in between, or even a space for ...
1
vote
2answers
59 views

Guidance with The Loop for CMS

Maybe I'm going about this the wrong way but this is my scenario... I would like to use WordPress as a CMS rather than a blogging platform. I have a website that will have somewhere between 25-50 ...
0
votes
1answer
23 views

How to Emulate Default Navigation Menu Behaviour in a Custom Theme?

I'm trying my hand at developing a custom theme, and I've got navigation menus working (with the help of this walker, but only if they're explicitly defined in the menu settings. The default themes ...
0
votes
0answers
41 views

Lessphp auto-compiling issue in WordPress

I'm using Lessphp to auto compile my style. After reading the document ( http://leafo.net/lessphp/docs/#compiling_automatically ) and some research, I got this code: function autoCompileLess() { // ...
0
votes
3answers
39 views

How can I see what template parts are being called for rendering the viewable page?

I have a theme where the developer used get_tempalate_part() a lot, and these parts are scattered across theme subdirectories as well as in directories in a plugin that was created to assist with the ...
1
vote
2answers
51 views

Apply different Class for each element in a foreach()

sorry for the silly question, but I am really lost. I want to apply the following CSS to the even elements of my foreach. CSS .blogArticles a { float: left; max-width: 250px; width: 25%; ...
0
votes
1answer
19 views

How to make a theme unable to be used on a multisite network?

I have run across a WordPress theme that the developers intentionally set to not be usable on a multisite network. The theme was installed on my single site and then when I configured it to be a ...
0
votes
1answer
24 views

Dynamic meta description

I am trying to make the <meta name="description" content=""> pull the content from single posts, but I am running into a snag. Currently I am using this: <meta name="description" ...
0
votes
0answers
10 views

Adding custom URL rewrite rules

I want to use 2 custom post queries on the author profile page, both of the queries uses pagination. With the following pagination function, I get this URLs structure: ...
4
votes
3answers
123 views

How to add custom “Menu Settings”

I want to be able to tell the wordpress menu's on what page to show. The way my menu is shown now: I want to have the option in the menu settings like so: But I cannot find any documentation ...
0
votes
1answer
31 views

3 x 3 grid of posts on the home page

I'm using Wordpress as more CMS than blog, and I want to create a theme that uses 9 specific posts on the home page. I don't want those posts to show up in other lists. I don't want other posts to ...
0
votes
3answers
40 views

Allow different <span> tags in widget titles

How can I make widget titles allow HTML? I want to add icons from an iconfont to the titles like <span class="icon-someicon">Widget Title Here</span> I tried the following but it does ...
0
votes
0answers
33 views

Extend walker - navigation, adding data attribute to a tag

I would a data attribute to the a tag in the menu, like have <a href="#example" data-attribute="attribute">CLICK</a> I know that I have to extend the Walker BUT I tried in several times ...
0
votes
0answers
14 views

Sharing a database amongst multiple local installs/connect to multiple databases?

My team is looking to improve our Wordpress Theme development workflow, and one of the main concerns is battle-testing our themes with all forms of data in all possible environments. For the most part ...
0
votes
0answers
19 views

Update WordPress Theme Review Ticket

I added a WordPress theme to the WordPress repository for review 9 days ago. It is now listed on the queue but it is not taken for reviewing. I noticed that I have done a small mistake with my theme. ...
-1
votes
1answer
36 views

Forms won't submit

I have a brand new theme that I just built out using _s's (underscores) that won't submit forms. Here are the errors I get in the console: On submit: Uncaught Typeerror: cannot read property: ...
0
votes
1answer
57 views

How can I show a different theme for admin users? WP 3.8+

I've been searching around for a long while now. There seem to be plugins available for this, but hardly anything that is current. Many of the plugins I have already tried do not work correctly with ...
0
votes
1answer
29 views

Can't use admin_enqueue_scripts or wp_enqueue_script

I've suddenly had an issue that neither admin_enqueue_scripts or wp_register_script are working properly, they were working fine for a while but suddenly stopped working. In the following function, ...
0
votes
1answer
13 views

How to make javascript work on theme options page

Gentlemen! I'm composing a theme options page for my WP theme. And I bumped into the problem of finding the proper way to introduce inline jQuery interactions to the page. Ideally for me in the ...
3
votes
1answer
129 views

Enqueue Stylesheets After Theme's “rtl.css”

I am currently developing a theme with internationalization support, and would like to load stylesheets after my theme's rtl.css (an alternative style.css loaded for languages with a right-to-left ...
1
vote
3answers
90 views

How to create .pot files with POedit?

I've spent hours today on what seemed like something really simple, which is to create a .pot file for a Wordpress theme that I'm creating. I've read the Smashing Magazine article, the Tutsplus ...
0
votes
2answers
51 views

Fatal error in comments.php

I am using customized theme for my development. The site was working fine and in last few days started seeing this error Fatal error: Call to a member function is_singular() on a non-object in ...
0
votes
0answers
32 views

Theme Development : License help

I'm developing my WordPress Theme. Is Theme required to use Copy Right when its does not have registered in Copy Righted list? is themes images directory required Copy Right declaration? I checked ...
0
votes
1answer
26 views

featured content: which area does this cover [closed]

new to wp just wonder how to get content into the center of the theme note ive installed wp 3.9.1 choosed the theme 2014 with child-theme and run the plugin fourteen colors what makes me wonder : ...
0
votes
2answers
48 views

show posts in different styling

I would like to show categories in the front page with different behavior: categories to show posts in two styles [Three posts having the same style and then another two with the same style] ...
1
vote
1answer
22 views

Using My Own Classes On Wp Unit Tests

(I'm trying to solve style problems of code samples) I'm developing a theme but I have some classes which developed for this theme. I want to run unit tests on my theme. I've followed this steps: ...
1
vote
1answer
42 views

When to use _e and __ for the translation?

What is difference between _e() and __() functions for the translation? In what cases e() and __ ()should be used?
0
votes
1answer
29 views

Extending a theme: build new features as plugin or core modules?

I have developed my own WordPress theme based on the Roots starter theme. Because of my clients needs, I'm often required to develop custom features (what I refer to as "modules") that are added to ...
0
votes
1answer
293 views

contact form in template with jquery,validate and ajax

I have a page-contact.php for my contact form in my template. I wanted to add jquery validation and some fancy ajax action to my form. This is already a working code in a simple PHP page, but getting ...
1
vote
3answers
92 views

multisite: global menu containing network site links?

Can I create one single menu that appears on every page within the network and contains every site and page that exists within the network? I'm talking about the following structure: Main Site ...
0
votes
1answer
16 views

How to count posts of a category and of a category limited by a tag

I have two urls, and I want to know how many posts will be displayed there, when I click them. The goal is to show the visitor in the navigation of those urls, how many postings are found there. As ...
0
votes
1answer
36 views

Horizontal Navigation

Hi. I been fighting with this problem for couple of weeks now. Trying various approaches. From CSS styling to a custom walker. I want to render each level as its own element. The navigation ...
0
votes
1answer
26 views

wpdb->insert adds too many rows

I have the following code in my functions.php $ar = array( 'price_content' => 'hello' ); $result = $wpdb->insert('hs_prices', $ar); // insert 'hello' into 'price_content' This should ...
1
vote
0answers
29 views

Limit number of users a role can create

Just wondering if there is a way to limit the amount of users a specific role can create? For example, if Editors can create new accounts, I only want them to be able to create 20, and then they ...
0
votes
1answer
30 views

Why am I getting a white screen without a slash at the end of the address?

I am currently building a custom Wordpress theme for my rugby team. I just noticed something and I can't work out whether this has been happening for a while and I have only just noticed it or it is a ...
0
votes
1answer
135 views

Call to undefined function get_current_screen() on my localhost

I'm using Wordpress 3.9.1 and I get the Fatal error: Call to undefined function get_current_screen() if I put the following in my funcitons.php or in any file of my theme: $screen = ...
0
votes
1answer
34 views

get_option() returning empty

I'm building a settings page for a theme and the get_option() that I'm using to retrieve the settings returns only string(0) "" even though there is a checkbox field. What I want is to retrieve the ...
0
votes
0answers
32 views

WP_Query to get all posts with specified category in priority

Now I have a query to get all posts in the specific category featured. $today = date('Y-m-d'); $args = array( 'post_type' => 'event', 'event-categories' => 'featured', ...
0
votes
0answers
39 views

Post label “new!” in wp_nav_menu using class?

I'm looking for a function to add a "new" label in front of my custom post type name in my navigation menu. The code is : <?php $args = array( 'numberposts' => '1' ); $recent_post = ...
-1
votes
1answer
49 views

Loading jQuery library from WordPress admin

When we are developing Themes, we are taught to enqueue the jQuery library if necessary, because no jQuery library is available on the front-end of WordPress (if I'm not wrong). But when we are into ...
0
votes
0answers
18 views

How to set separate “lang” attribute for post or page titles

I am creating a multilingual website in English and Hindi on WordPress. Half of the site is in English and rest is Hindi. In a previous question asked by John Doe here at stackexchange s_ha_dum ...
0
votes
1answer
48 views

How to make an sql query to exclude everything but custom taxonomy terms in table wp_terms?

Problem Summary: I am trying to write a SQL query that returns only my custom taxonomy terms, but the table (wp_terms) contains all of the terms, even ones that I don't want (such as category terms, ...
0
votes
1answer
36 views

Replace all media (images)

I created a new theme for my Wordpress site and I need to replace all the media (images) on the site, since I am using all new image sizes (which are larger than the largest on my current site). 98% ...
0
votes
2answers
37 views

How is the `get_sidebar` function meant to be used to call a 2nd sidebar?

What's the proper way to call a second sidebar in the main home of my blog? And I mean 2 sidebars at the same time.... I might edit the question when I get further info, but now I'm feeling ...
0
votes
3answers
35 views

Is it safe to register a taxonomy without using any hooks?

I'm creating a Wordpress site in which I wanted to use a custom taxonomy in my theme options, which I had registered using the 'init' hook. But the problem was that the 'init' hooks gets fired after ...
0
votes
2answers
97 views

How to add font in wordpress

I have a oswald.woff font file downloaded from some free fonts site. Using ftp i have created folder called fonts in the themes folders. (i.e /wp-content/themes/esplanade/fonts). In the fonts folder ...
0
votes
1answer
79 views

best practices for updating wordpress theme

Need to use a new theme for one of my Wordpress websites, but at the same time I need to also keep the current theme live whilst I make changes. What is the best practice? Should I develop the theme ...