wordpress

Overriding wp_get_archives for a theme in Wordpress

I am working my way through customizing the Worpress default theme. I came up against an issue of formatting archive links. The default theme uses wp_get_archives function defined in general-template.php. The output of the function is customisable, but not customisable enough for me. I can achieve everything I want to do by basically ...

Showing specific categories

I'd like to show only specific wordpress categories (with their sub-categories nested), so for example: Main Category 1 Sub Category 1.1 Sub Category 1.2 Main Category 5 Sub Category 2.1 Sub Category 2.2 ... I can hardcode it inside the sidebar template, but I'd like to know if there's any existing plugin/widget that allows thi...

Wordpress site painfully slow...

Hi, What tools are there out there for determining why a site takes so long to load pages? I'm using a very simple theme that I changed to fit my needs, it's a brand new site with only two test posts and it takes a while to load. I used YSlow for Firebug and it gives the site a Grade A (90) so that doesn't really help. Is there anythi...

Making JQuery LightBox Plugin work with multiple galleries

Hi guys... I'm trying to make this jquery plugin => http://leandrovieira.com/projects/jquery/lightbox/ work with multiple galleries on the same page. The problem is, everytime I click on a picture from a certain gallery, I get all the pictures from all the galleries on the same page. Let's say i've got 2 galleries of 6 photos each. If I...

How to make Wordpress plugin first plugin to be run?

Hi Stackoverflowers, I am writing a Wordpress plugin that does string processing whenever 'the_author' filter event is fired. Obviously, there are more plugins that might respond to this event. I know that you can set the priority of your plugin but for example the Disqus plugin is called before my plugin even when I set my priority to ...

wordpress - how to make a page with no parent appear in a subnav menu

I have a page with a Parent of Main Page (no parent), so that it appears in the main navigation of the site. However, I also want to get to this page through one of the options on a drop-down menu. If I set the parent to that Nav page, it appears in the drop-down but then disappears from the main nav list. For example: Main Nav: Dogs C...

How to get wordpress page id after looping posts?

I have a page in Wordpress that loops posts in a specific category. In sidebar.php, I want to get a list of sub pages and display them as a menu. However, when using get_the_ID() or $post->ID, it returns the ID of the last post that was looped, not the page. How do I get the ID of the page in the side bar after I have looped posts in t...

Pull data from WordPress

Hi, What's the best way to pull data from Wordpress database? I think creating a plugin would be nice. Is there a tutorial out there that do the job? Or a plugin that does it? Pull content of the page via JSON/XML. Cheers, Mickey ...

bit.ly links in wordpress twitter status updates leads to 404

All the twitter status updates on the wordpress sidebar have bit.ly links. When I click on them, I get the 404 page because instead of going bit.ly/uniquenumber it tries to go www.domain.com/blog/"http://bit.ly/uniquenumber/" with www.domain.com/blog being the homepage for the wordpress blog. Is there an easy way to stop it from adding ...

WordPress Monthly Archive by Year

WordPress extraordinaires, I need your help! I need to be able to list the archives, but in a slightly different way than the WP codex, or an hour of Googling will show me. I need the months of the year, as the generic archive function, but only for one year at a time. So, list all the months in 2007. I'll need to be able to use this m...

How to Build WP Site with Hierarchical Content and Using Custom Design?

A client asked me to redesign her web site, built several years ago in WP by another developer. Although I've never worked with WP before, I'm pretty comfortable with html, css, and php, and I more or less understand how WP stores content and dynamically builds pages. But I'm wondering how to approach these challenges: My client's sit...

Remove escaped quotes from Wordpress posts

In my content I'm giving my <h3> tags id's for the sake of direct linking. This is how it looks in the post editor: <h3 id="h3-title">H3 Title</h3> So that I can directly link to it like this: <a href="http://example.com/page#h3-title"&gt;H3 Title</a> However, the double quotes are getting escaped somehow, with the html output on...

Serve wordpress blog from subdirectory with django and wsgi

Hi, I'm currently on shared hosting plan with dreamhost and have installed Django as per http://wiki.dreamhost.com/Django . However, I also have a wordpress blog that I wish to keep running in a subdirectory, i.e, site.com/blog. Is it possible to do this. Installing Django results in a passenger_wsgi.py file in the Django root directory...

Wordpress menu of categories

I have a horizontal menu for wordpress site and the menu items are categories. On clicking each menu item , I should show latest post for respective category. e.g. Item_1 Item_2 Item_3 Item_4 are my menu items. So on clicking Item_2, I should show latest post for that category of Item_2. Is this possible in Wordpress? I am just a n...

List custom categories

I want to display custom categories with their sub-categories in a nested list. This seems to works: <?php wp_list_categories('hide_empty=0&depth=2&hierarchical=1&title_li='); ?> but if I include some custom categories it doesn't: <?php wp_list_categories('hide_empty=0&depth=2&hierarchical=1&title_li=&include=7,8,1,4'); ?> ...

add column to wordpress database

If i add a column to the wp_posts table in wordpress may i have problems in upgrade of wordpress?? ...

Wordpress Custom Options In Admin Area

I would like to create an custom option so that the user in the admin area could be able to select a alternative css that I will provide. I have made a custom page using the add_menu_page function in the functions.php. How could I retrieve all the .css files contained in the directory "/css" to make it easier for the user? ...

PHP Localizing with gettext

I am localizing some PHP/XHTML using the gettext() function in a WordPress plugin. WordPress has 'aliases' for these functions such as __() and _e(), the latter of which automatically echoes the arguments. Now, most of my localization has gone pretty straightforward, such as: <h3><?php _e('Authentication', 'domain'); ?></h3> However,...

Change wordpress navbar to link straight to post or page

The template I am using is techified and I would like to change the navbar to link directly to the post, not the category as it does now. Here is the code for header.php. I'm assuming this would be where the change would be made. <div id="navigation_area"> <ul id="nav"> <?php wp_list_categories('exclude=1&hide_empty=0&orderby=name&show...

User permission - triggering code on user role (Wordpress)

I'm developing a custom plugin in PHP so existing plugins are not usable. What I want to achieve is that I want to display different url within a post for some users . For users that are registered in wordpress, contacted me and are 'approved'. I want to set up this extra user profile field so I can use this field in a condition. So gues...