Articles of customization

Posts not showing with custom categorybase and subcategories

Edit: Fixed. I had an error in my permlink structure. I have a problem with individual posts not showing with their URL. I have set a custom category base in Permlinks called ‘story’. I have a blogpost category called ‘chapters’, which has a subcategory ‘chapter-1’. Both category pages show fine, but when I want to […]

How do I create a widget that only allows a single instance?

How do I create a widget that only allows a single instance of a widget to be added through the WordPress interface? The default behaviour of widgets allows multiple instances to be added. I am using the Example code from http://codex.wordpress.org/Widgets_API I have seen a similar question where the answer was to use the old […]

Redirect members to custom page upon logging in through WP admin

When a members logs in through WP admin, I would like to redirect them instantly to a custom URL. What will I need to change to make this possible? Respond with step-by-step details would be ideal.

create custom page for statistical data capture and reporting

I am not too comfortable coding in PHP yet, but am currently working on a project where I need to create a custom page for the website, in a member area, where the members of the site can capture certain data, like total income for the day, number of calls made during the day, etc. […]

Publish pages/posts as HTML?

We’re looking to use a plugin or custom setup for authors to create pages or posts and publish them as single HTML files. The file could be saved on the server in a specific directory or have a download button from within the editor. So far we have found 2 plugins that almost achieve this […]

Custom Taxonomy conditionals

So I have setup a custom post type ‘products’ and custom taxonomies / categories ‘defence’ ‘law & enforcement’ and ‘Commercial’. I have using the following conditional to set some specific css and the correct banner for a product: <?php if (has_term( ‘defence’, ‘productcat’, $post->ID )) { ?> This works fantastic if the product is in […]

custom session variables being lost in FF

for whatever reason firefox is dropping my custom session variables. the variables are for a custom user system that is built into my custom theme. this only happens in firefox, the user system works perfect in all other browsers. heres the top of my header.php: <?php session_start(); global $errors, $success, $u_cache; include ‘sub-user-auth.php’; ?> here […]

Prevent duplicate posts in wp_insert_post using custom fields

My source links are something linke this : http://sample.com/entertainment/default.aspx?tabid=2305&conid=102950 http://sample.com/entertainment/default.aspx?tabid=2418&conid=104330 http://sample.com/entertainment/default.aspx?tabid=2429&conid=104264 http://sample.com/entertainment/default.aspx?tabid=2305&conid=102949 . . . I cache content form links.I use wp_insert_post to post cached content from source site to wordpress: $my_post = array( ‘post_title’ => “$title”, ‘post_content’ => “$content”, ‘post_status’ => ‘draft’, ‘post_author’ => 1, ‘post_category’ => array(1), ); wp_insert_post( $my_post ); I want […]

Multiple homes for multiple languages

I want to have multiples homes, for use multiples languages. For do for example: if($_SERVER[‘SERVER_NAME’] == ‘en.bz6.org’) defime(‘WPLANG’, ‘en’); else efime(‘WPLANG’, ‘es’);

wp_query to display custom taxonomy terms

I have a custom post type named ‘tours’ and custom taxonomy named ‘tourtypes’ so i can categorize it into terms like ‘cultural tour’, ‘sports tour’ etc. I’m not the original author of this theme and don not know much about dealing with taxonomy. But I want to extend it so that instead of outputting all […]