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 ...
1
vote
1answer
52 views

Injecting a custom sql query into a page/theme

I have written a custom sql query for our WordPress website (fairly elaborate and not achievable with the standard wordpress code) and I've got it to run via $pageposts = $wpdb->get_results($query, ...
0
votes
1answer
27 views

How to replace settings in WordPress plugin from a theme

I created an array with some default settings in a plugin, and want to allow it to be replaced from functions.php in a theme without using stored data (eg. add_option). I want this to be just a hook ...
0
votes
2answers
97 views

Why I can't load my JavaScripts using an hook inside my functions.php file?

I am pretty new in WP (I came from Joomla) and I have the following problem: I am carrying this pure HTML theme (that use BootStrap CSS framework) into a WordPress theme. This is the original pure ...
0
votes
1answer
50 views

Single-level menu option? Another way?

I'm developing a child theme of Twenty-Thirteen for a client. My theme contains a second navigation menu properly registered through my functions.php file. This second navigation menu is fully ...
0
votes
2answers
199 views

Dynamic menu links after header title

I am using Parabola theme of Wordpress, and i would like to display few dynamic menu links for logged in users, just at the right of the header title. As shown in the below image, Menu 1 and Menu 2 ...
1
vote
1answer
95 views

Should I use function_exists() and/or add_action() in theme development?

I'm trying to get my theme ready for publication on WordPress.org I got this feedback: function_exist() it is not preferable 3.0 design Now I wonder what I'm doing wrong. In the current ...
0
votes
1answer
127 views

Add content after get_header

I'd like to add content directly after the div#main (end of header.php) and before /div#main (beginning of footer.php). I'm using an own child-template (of twentythirteen), that contains only ...
0
votes
1answer
88 views

Why enqueue styles on hook

Why do we need to enqueue styles on a hook, why not just enqueue them straight in like this? wp_enqueue_style( $handle, $src); the codex page gives an example of using a hook but doesn't explain ...
0
votes
2answers
291 views

Theme not calling Jquery properly

I am developing a theme and I have called jquery along with other JS files from a theme-enqueue.php file. For some reason only the Jquery file that is hosted on googles servers is adding the theme URL ...
0
votes
3answers
529 views

Theme Customizer not loading JS for live preview

I am currently working on adding options to the theme customizer. For the last two hours I have been trying to get the live preview working and I am trying figure out why my theme isn't loading the ...
0
votes
1answer
51 views

Which hooks are essential for post templates?

Im in the process of building a very custom theme and Im beginning to work on the post templates, but I dont know which hooks are essential for them. So like, I've seen (but cant remember where)some ...
3
votes
1answer
649 views

How to remove the Theme Customization Button from the dashboard and themes options page?

In my Wordpress theme that I've currently been building I do not take advantage of the Wordpress Theme Customization API. As much as I would like too, I've invested far too much time into my own ...
3
votes
5answers
397 views

How do I make a theme “plugin-ready”?

How do I revise a theme so that I can publish my event hooks and anyone can build a plugin to add new functionality easily to my theme?
0
votes
3answers
1k views

What can I hook into after_setup_theme?

I'm wondering what can I or should I NOT hook to after_setup_theme? I'm wondering because I have been told that I shouldn't hook wp_enqueue_style to it, but I have seen other places using it to hook ...
1
vote
1answer
912 views

How to use filter hook 'post_updated_messages' in coherence with action hook 'save_post'

I am trying to send out e-mail, SMS and IM notifications to group members of this WordPress website, whenever a WordPress page in their user group has been published/updated. I figured using the ...
0
votes
1answer
269 views

How to change database values on theme update

I have a theme released into the wild but have not prefixed the post type appropriately. Yes, I know, it's a shame and I regret it :( So, I am currently using acme as the post type name, but I' like ...
2
votes
2answers
2k views

How do I “unhook” / de-register jQuery so that it's not called as part of wp_footer();?

I need to "unhook" jQuery from my wp_footer() ... it's being called automatically and I'm looking for something I can add to functions.php which prevents it from being called a second time in the ...
1
vote
1answer
408 views

Pass variable to hook. Its possible?

I have this hook created to retrieve user password when he register or update his pass. I dont want my client to touch wordpress core so i was planning to use a hook in wp-includes/user.php All this ...
2
votes
2answers
1k views

Get password when user registers and save it sha1 into database

im working on a website where the users can connect with iphone to some functions of it by using a sha1 encrypted password. In other words the plain password of wordpress encrypted in sha1. In the ...
3
votes
2answers
498 views

Seeking clarification on page request life-cycle

I'm just trying to get my head around the "life-cycle" of a typical page request in WordPress. The Action Reference page lists 38 actions that occur during a typical page load, but two things aren't ...
7
votes
4answers
5k views

Theme Activate Hook

I would like to write a function to email me the URL of the website when my theme is activated. What is the hook initiated when the theme is activated?
11
votes
3answers
1k views

get_template_part vs action hooks in themes

It seems to me both of these afford the opportunity for the end user to modify a theme without actually editing the themes files (via child themes). My question is, is one method preferred over the ...
2
votes
2answers
2k views

Why isn't is_home() working correctly?

I put a if(is_home()) bit in my theme's functions.php and it doesn't seem to work. The function containing this bit is called on init so is_home should work already.