Skip to main content
Search type Search syntax
Tags [tag]
Exact "words here"
Author user:1234
user:me (yours)
Score score:3 (3+)
score:0 (none)
Answers answers:3 (3+)
answers:0 (none)
isaccepted:yes
hasaccepted:no
inquestion:1234
Views views:250
Code code:"if (foo != bar)"
Sections title:apples
body:"apples oranges"
URL url:"*.example.com"
Saves in:saves
Status closed:yes
duplicate:no
migrated:no
wiki:no
Types is:question
is:answer
Exclude -[tag]
-apples
For more details on advanced search visit our help page
Results tagged with
Search options not deleted user 6035

MEANINGLESS tag. Used as a merge target for other meaningless tags. Do not use it on new questions.

5 votes
Accepted

How do I add a promotional message to my posts?

You'll want to hook into the_content to add a message. Something like this: <?php add_filter('the_content', 'wpse51338_filter_content'); /* * Filter the content to add a message before and after it …
chrisguitarguy's user avatar
3 votes

Wordpress if in term*

http://codex.wordpress.org/Function_Reference/has_term So... <?php if ( has_term('products', 'your_custom_taxonomy', $post ) ) { get_template_part('products'); } elseif ( has_term( 'downloads …
chrisguitarguy's user avatar
8 votes

How to Handle Distributed Development Workflow

Caution: very mac/linux/unix centric thoughts ahead. Includes a lot of command line fu. Put All the Code Under Version Control I like git. Mark Jaquith has some good suggestions on keeping an enti …
chrisguitarguy's user avatar
2 votes
Accepted

Multiple sites/domains with content all managed by single installation of Wordpress

This should be doable. First step would be pointing each domain to the same document root/install of WordPress. Next up, use WP_HOME and WP_SITEURL in wp-config.php that change based on $_SERVER['HT …
chrisguitarguy's user avatar
4 votes

How can I display custom post types under multiple views?

What you want is a rewrite endpoint. You're already familiar with these. WordPress' urls that end with feed are simple a rewrite endpoint, and you can add your own! add_rewrite_endpoint takes two a …
chrisguitarguy's user avatar
3 votes

Multiple Blogs on one site. Best Practise

I would go with option 4: A simple SQL statement (UPDATE {$wpdb->posts} SET post_type = 'testimonial' WHERE post_type = 'post' AND post_status = 'publish' or something like that) to move the current …
chrisguitarguy's user avatar
0 votes

Is it possible to create relational metabox values in a custom post?

This tutorial on adding custom meta boxes is also really good: http://webdesignfan.com/custom-write-panels-in-wordpress/ It's all very flexible; you should be able to reuse the code you create.
chrisguitarguy's user avatar
6 votes
Accepted

Is it possible to remove the "standard" post format?

The first thing to remember about the post editing screen is that everything (except for the post title, editors, permalink, etc.) is a meta box. Since you can easily add and remove meta boxes, there …
chrisguitarguy's user avatar
1 vote

What is the best way to handle multiple calls to get_template_directory_uri() and similar fu...

I almost always define my own constants for things involving URLs (pattern 3). The reasons: Enqueueing does not account for child theme files. Using get_style_sheet_directory_uri will obviously …
chrisguitarguy's user avatar
2 votes
Accepted

Where to store the name of a custom table?

As long as... You use $wpdb->prefix (or $wpdb->base_prefix) to prefix the table Your table name is someplace public, and easily available for other plugins, themes and end users to use and extend …
chrisguitarguy's user avatar
1 vote
Accepted

Widget where it can make changes to the container

I would not recommend that. Much easier to use a clearfix hack to force clearing and just add that style to your widget. Clearfix hacks are transparent: it doesn't matter if they happen on all element …
chrisguitarguy's user avatar
5 votes
Accepted

Change post title during post saving process

You can hook into wp_insert_post_data and change things. <?php add_filter('wp_insert_post_data', 'wpse67262_change_title'); function wpse67262_change_title($data) { $data['post_title'] = 'This wi …
chrisguitarguy's user avatar
44 votes

Is moving wp-config outside the web root really beneficial?

The biggest thing is the wp-config.php contains some sensitive information: your database username/password, etc. So the idea: move it outside the document root, and you don't have to worry about any …
chrisguitarguy's user avatar
5 votes
Accepted

Where to put third party PHP library?

If each plugin/theme functions on its own, then you should probably drop the the library in every theme/plugin. Then just check to see if it a class or function from the third-party library exists be …
chrisguitarguy's user avatar
3 votes
Accepted

Can I the caption shortcode to set caption to a data attribute, and with the image's alignme...

Basically the img_caption_shortcode filter allows you to completely replace the default image caption. If you want to do that, you'll need to ask WP to pass all the argument of the filter to your cal …
chrisguitarguy's user avatar

15 30 50 per page