master_kato
Forum Replies Created
-
Forum: Fixing WordPress
In reply to: 400 Bad Request when trying to update permalinksI’ve encountered this same problem after upgrading to WP2.3. Firefox or IE give troublesome replies about Bad Request. I can change to default permalinks but custom permalinks will generate the Bad Request.
I’ve been using WP for years now with 3 websites and I’ll be surprised if this topic even gets any attention. I think WordPress is great but support is about the worst they come. Problems become quickly overwhelmed from the volume of posts. Good luck with this gnurf, If I come across a solution I’ll post back here.
Forum: Installing WordPress
In reply to: Method Not Implemented POST to /wp-admin/post.php not supported.Was this ever resolved? I get the same problem and have scoured through these forums and tried all the suggestions for .htaccess and nothing has worked. I still get
POST to /wp-admin/post.php not supported.whenever I try to edit existing posts. I can create new posts fine.
Forum: Everything else WordPress
In reply to: Searching for accented vowelsWhat accent key??
Forum: Fixing WordPress
In reply to: One page printable formatDuh, Thanks I must have glanced right over that.
What is the best way to include a link to a “printable” format?
Maybe using POST data, then check for it and call query_posts(“showposts=-1”) if the POST data is present?Forum: Plugins
In reply to: MySQL indexingMichaelH, thanks for the reply. I actually did post my query last month but never got a reply – here’s it again:
I wrote a plugin to sort by up to 4 Custom Fields. I use the posts_orderby and posts_join filters. The posts_orderby part of the plugin is straightforward:
$orderby = $sortfield1.’,’.$sortfield2…etc Also has an option for ASC and DESC
The JOIN part goes like this:
LEFT JOIN wp_postsmeta AS $sortfield1 ON ID = post_id AND $sortfield1.meta_key = $sortfield1
This is actually in a loop to create up to 4 JOIN clauses depending on how many custom fields you want to sort by.
The problem is that 1 JOIN is okay, but upon adding the second JOIN my database query goes from < 1 second to 30 seconds or more. Additional JOIN clauses beyond two add a few more seconds.
I’m running MySQL 3.23.
I posted a question on the forums at MySQL and they immediately suggested using an index for the on the meta_key columns.
-matt
Forum: Fixing WordPress
In reply to: WordPress Page Permalink and .htaccessHi nrvx,
I’m not an expert, but I believe the way permalinks are handled have been changed in WordPress 2.0. In 2.0 it will make only one change to .htaccess if you turn on permalinks then everything is handled from within WordPress.
However, it seems lots of folks (and myself) are having problems getting permalinks to work with 2.0. I’d say wait for those to get ironed out then upgrade to 2.0 (or install and test 2.0 yourself)
Forum: Plugins
In reply to: Need help from an MySQL Master for Custom OrderingOk, I figured this out. I need to use two filters
posts_orderby
posts_joinSo I join the metadata table, and use aliases so I can join it multiple times for each field. The problem is that once I add the second LEFT JOIN, my db performance goes through the roof (from 0.5 seconds, to 30 seconds). Turns out MySQL doesn’t like multiple JOINS that much. Anyone have any ideas on how I can optimize this? Here’s a stripped down example:
SELECT DISTINCT * FROM wp_posts
LEFT JOIN wp_postmeta AS Field1 ON wp_posts.ID = Field1.post_id AND Field1.meta_key = ‘Field 1’
LEFT JOIN wp_postmeta AS Field2 ON wp_posts.ID = Field2.post_id AND Field2.meta_key = ‘Field 2’Then this is followed by
ORDER BY Field1.meta_value ASC, Field2.meta_value ASCand so on for however many custom fields you want to sort by. I thought I could combine the multiple JOIN clauses but I don’t know if it’s possible while using alises and JOINS to the same table.
?
Forum: Fixing WordPress
In reply to: Trackback problem – works in some casesI’m so sorry – trackbacks do work with Test Track – I didn’t realize moderation was turned on there so all my trackbacks were in moderation!
Now I just have to get this working with real sites, must be a problem at their end.
Forum: Your WordPress
In reply to: My new WordPress site with galleriesThanks. I wrote the code for the galleries myself. The code would need some work before making it available as a plugin but I would like to get there.
The actual galleries (if you visit the gallery page) are all created on the fly based on whatever directories are present. Thumbnails are created if they don’t exist and stored for later. Viewing sized images (800×600) are also created when requested and stored from the original high res (usually 3K x 2K for the newer digital stuff). So all you need to do is to upload a directory full of any resolution images and it works, though I have a strict naming convention for dating purporses.
The integration with the blog is done with two steps. The first is to create a new post with a custom field that contains the path to the specific gallery. This allows the post to contain one of the small “front” images and a link to the gallery. The second step is for the reverse…to include the post when you look at the gallery and this is done by giving the post slug the same name as the gallery. Since the gallery name includes a date and title this is guaranteed to be unique. When a gallery is requested it looks for a post with that slug name and includes it. If no post exists it will still display the gallery.
I still have to learn about writing plugins but I would like to make a gallery plugin to streamline the process.
Forum: Themes and Templates
In reply to: Page permalinksWhat do your rewrite rules in htaccess look like? I am using the wordpress generated ones and anything with a dash or underscore don’t work. (such as 2005-09). Here is the one of interest.
**************************
RewriteRule ^(galleries)(/[0-9]+)?/?$ /wp/index.php?pagename=$1&page=$2 [QSA,L]Forum: Fixing WordPress
In reply to: Permalinks not working on some pagesOk, so it looks obvious that the problem is that the rewrite rules don’t allow for dashes or underscores I guess….but posts are allowed to have dashes. Why wouldn’t WordPress allow the rewrite rules process any normally valid path?