
joefish
-
Posts
35 -
Joined
-
Last visited
Posts posted by joefish
-
-
Looking at what you have in your first post, it seems like something like...
><?php wp_list_categories('orderby=id&exclude=55,56,57,58&title_li=&hierarchical=0'); ?>
...would generate what you're looking for. Order by ID, exclude the specified categories, no heading or outer list item, no nested lists for subcategories.
-
The template tag wp_list_categories() is a fairly recent function, one that's intended to replace the older wp_list_cats(). Both functions work in a very similar way. One problem I can see is that you're using arguments intended for wp_list_cats() with wp_list_categories() instead.
To sort by id with wp_list_cats:
><?php wp_list_cats('sort_column=id'); ?>
To sort by id with wp_list_categories:
><?php wp_list_categories('orderby=id'); ?>
What's that `depth=1` argument you're using? I can't find any documentation on that for either function. What's your intended effect? A flat list, instead of nests for subcategories?
-
I agree that sounds like a missing or incomplete file. get_private_posts_cap_sql() is part of wp-includes/post.php and is new to 2.2.
-
My site also uses a tree structure, with just “Page titles” linking to the pages, does WP allow this type of linking, as in not having a brief summary of the page in the link? (hope this question is understandable, It looks to me like WP uses "brief summary" internal linking)
I don't follow. Are you talking about the main page containing only links to content stored on other pages?
Is WP compatible with Dreamweaver 8 (which is what I am currently using, I was thinking about keeping my structure I already have and just use WP to remake my “content-filled” pages)?As far as I know, Dreamweaver doesn't have the capability to interact with WordPress at all. You can still use Dreamweaver to help you with creating layouts, but you'll have to get your hands dirty to make them into proper WP themes.
I also have a few Google Questions,1. Some of my pages are already indexed (although nowhere near SEO standards), so would I lose the pages that are already indexed (Plus some of them are in "Supplemental Hell" for reasons I do not know of)?
2. Would it be better to recreate the website from scratch so Google can recrawl everything with WP structure (I currently used Dreamweaver 8 to make everything)?
Thanks Again
The best thing to do would be to recreate your content in WordPress, then delete the old files and use 301 redirection to send all visitors (including search engines) to the new WP content. Search engines will usually update their listings when they encounter a 301.
-
I hate to dispute the plugin author, but he's incorrect. The plugin is in fact hardcoded for configurations where WordPress is stored in the site root.
Line 128 of pluginst.php defines the variable $toggle, which is then output on line 148 as part of the Uninstall table. Here's line 128:
>$toggle = "<a href='/wp-admin/plugins.php?page=".$_GET['page']."&uninstall=".$plugin_file."'>".__('Uninstall')."</a>";
As you can see, the link will always point to your website's root. To get the plugin to work properly, change line 128 to this:
>$toggle = "<a href='" . get_bloginfo('wpurl') . "/wp-admin/plugins.php?page=".$_GET['page']."&uninstall=".$plugin_file."'>".__('Uninstall')."</a>";
get_bloginfo('wpurl') will return the location of the WP installation, as you've defined it under Options -> General in the "WordPress address (URL):" field. I'm not sure, but I believe 'wpurl' is only available in WP2.1 and higher. For older versions, you'll need to use something like get_bloginfo('siteurl').
Anyway, I made this change and was able to use this plugin to both install and uninstall other plugins under WP 2.2RC1.
Edit: fixed typo. Oops.
-
All those views and no responses? Ok, I'll bite. I'll take a look at the plugin.
What version of WordPress are you using?
-
Sure, just when I'm excited everything is working....
I'm now looking into how to fix that....
EDIT: Okay, it was really easy, just remove "feed:" from the href in sidebar.php. Is it very hard to add the Atom and other RSS types as links there?
Nope, that's not hard at all.
><a href="<?php bloginfo('atom_url'); ?>" title="<?php bloginfo('name'); ?> Atom 0.3 Feed">Atom Feed</a> <a href="<?php bloginfo('rss_url'); ?>" title="<?php bloginfo('name'); ?> RSS 0.92 Feed">RSS 0.92 Feed</a> <a href="<?php bloginfo('rdf_url'); ?>" title="<?php bloginfo('name'); ?> RDF/RSS 1.0 Feed">RDF/RSS 1.0 Feed</a>
Of course, you'll want to adjust that as required to match your theme and your tastes.
-
I just did a quick check in PHP, and you can remove the folder that way as long as you have permissions on that directory and it's parent directory.
Oh, duh. I forgot to give appropriate permissions to the parent directory. Yeah, my first idea does work, so long as I give the parent of the folder to be removed temporarily higher permissions.
Have you tried it like this?>exec("rm -r -f /home/secret_name/public_html/blog/wp-content/backup-db");
The rmdir() command worked just fine for me. I'll try this one next time I break something.
Thanks, guys!
-
you can always open a help desk ticket to the techs
if you can't get a script to work.
Understood, but if it's possible to resolve this myself, I'd like to. This issue pops up now and again among my TCH-using friends and I'd like to be able to offer a better solution than simply "the help desk can fix it."
-
I allowed a PHP script (plugin for WordPress) to create a directory. Now the directory is owned by a different user ID. I can't read from it, write to it or change permissions. I've tried using a simple PHP script to remove the directory (thinking if PHP created it, PHP can remove it), but that doesn't work.
The part of the original script that created the directory is:
>if ( !is_dir( ABSPATH . 'wp-content/backup-db' ) ) { mkdir( ABSPATH . 'wp-content/backup-db' ); }
and the command I've tried to remove the directory is:
>rmdir('/home/secret_name/public_html/blog/wp-content/backup-db');
But this returns the error:
>Permission denied in /home/secret_name/public_html/blog/wp-content/New1.php on line 1
So. How can I remove this folder?
-
That looks pretty slick. That BBCode thing is a smart feature.
I use something different for comment status management: Extended Comment Options. It has some nice options for advanced control, but it doesn't do anything automatically.
-
Joefish,
Thank you for mentioning those plugins and the Blog Herald. I have been hearing about that place but hadn't checked it out yet. I didn't think it was a TCH issue, either, but I figured I had to ask before going back to Akismet. For anyone who might be interested, I did file a Help ticket and the answer was:
http requests are open bi-directional on the server, the issue is something else. Kindly get more feedbacks from the script vendor so that we can check it out in detail.That sounds like a rotten response. More feedback from the script vendor? So should you contact Automattic, makers of Akismet, or Automattic, lead developers of WordPress?
But I believe the "get tag suggestions" part of Ultimate Tag Warrior stopped working at the same time (earlier this week). When I click on that button underneath the Write Post box, I get this error:Warning: fsockopen() [function.fsockopen]: php_network_getaddresses: getaddrinfo failed: Name or service not known in /home/***/public_html/wp-content/plugins/UltimateTagWarrior/ultimate-tag-warrior-ajax.php on line 108Warning: fsockopen() [function.fsockopen]: unable to connect to api.search.yahoo.com:80 in /home/***/public_html/wp-content/plugins/UltimateTagWarrior/ultimate-tag-warrior-ajax.php on line 108
Permission denied (13)
The first time I got that error, I figured Yahoo timed out or something. Now I'm not so sure.
My next steps will be to submit the problem to Akismet and UTW and to deactivate all my other plugins and reactivate them one by one.
I've never used that feature before. I tried it out just now and it worked just fine me. Which really only tells you that you're cursed and I'm not.
Deactivating plugins to troubleshoot is a great next step. There's definitely something squirrelly going on.
What kind of errors? I've been using Spam Karma since the day I found it 3 years ago and never had any errors. I did have issues with two people being blocked from commenting but once I whitelisted their IP the problems went away.They seemed to be plugin conflicts, mostly. Usually they were some variation of "headers already sent," but the errors were in a wide variety of scripts. I was a lot more attached to the other plugins than I was to Spam Karma, so out it went.
-
It's strictly coincidental that I knew about that outage. I just started subscribing to the WordPress category at the Blog Herald.
I hate to muddy the waters any further, but I'm really not a fan of Spam Karma. I tried it for a while and found it troublesome. For me, it was prone to mystery errors and had a very high rate of false positives.
I use Akismet, Bad Behavior and Trackback Validator. I also use another plugin that stictly speaking isn't a spam fighter, but is probably more effective than all the others combined. Extended Comment Options provides a handy interface for closing comments and trackbacks on old posts. About once a month I use it to close comments on posts more than 30 days old. That by itself reduces the volume of spam, at least as I see it in my spambox, by around 90%.
Of course, you don't really need a plugin for that. The same thing can be accomplished by typing a command into an SQL box in phpMyAdmin, but that's hardly convenient.
I'm sorry I don't help more relevant to the problem at hand. All I can say is that I don't think this is a TCH issue. I'm on server 121 and I don't have that problem. I also manage site for people on servers 120 and 14 and there's no problem with Akismet there either. You might want to either contact Akismet or keep an eye on the Akismet tag at the WordPress forums.
-
This probably wasn't related to TCH at all, Kathy. Akistmet has been having downtime issues today.
-
You're upgrading to 2.1, right? From what version?
-
Sociable is a social bookmarking plugin. It creates that little row of icons at the bottom of that post. I'm not a fan of it. I much prefer the unobtrusiveness of Alex King's Share This.
-
Works a treat, click. Thanks!
-
I use my domain primarily to host a blog, which is located in http://foo.com/blog/. I use a redirect from http://foo.com/ to http://foo.com/blog/. Everything works great with this until I add a subdomain. When I access the subdomain http://subdomain.foo.com/, that also redirects to http://foo.com/blog/.
The redirect rule I'm using is one I created through the cPanel wizard:
>RedirectMatch temp ^/$ http://foo.com/blog/
How can I redirect root to a folder without breaking subdomains?
Edited to add: BTW, I'm certain it's the redirect rule that's causing the problem. When I remove the root-to-folder redirection, subdomains work just fine.
-
You're welcome, both of you.
-
Ooh, so they did release today. I wasn't sure they were going to make their self-imposed deadline.
-
I won't be upgrading, at least not for a while.
I've been testing 2.1 for about six months and I've watched it grow and mature. There are some very nice new features, but even with the newest version (beta 2), I'm having issues that will prevent me from upgrading my live, primary blog. 2.1 itself is very nice, but plugin issues are a problem for me. Currently, two plugins I consider indispensable aren't working well under 2.1. Post Levels randomly populates the loop with duplicate content (to be fair, this is not a widespread issue) and Ultimate Tag Warrior has problems with tags being erased when comments are placed.
It's disappointing that I've tested 2.1 for so long and I may never end up using it, but I'm comfortable sticking with the 2.0.x line. The WordPress dev team has announced that they will continue updating the 2.0.x line for security and bug fixes for at least the next two to three years. I'll miss out on wizbang features, but not updating won't leave me any less secure.
-
That's actually a theme issue. Somewhere in your sidebar template will be something like:
><a href="feed:<?php bloginfo('rss2_url'); ?>" title="<?php _e('Syndicate this site using RSS'); ?>"><?php _e('<abbr title="Really Simple Syndication">RSS</abbr>'); ?></a>
Just remove the "feed:" bit. Some feed readers support that convention, some don't. That extra bit is in the WordPress default theme, so many themes based on it will have that as well.
-
The main index.php for WordPress is not a commonly customized file. Can you just reinstall the original index.php from the installation package for whatever version you're using? You can find archived downloads of many versions of WP here: http://static.wordpress.org/ If you're looking for a specific version, I've got quite a few recent version saved.
The newest version 2.0.7 is also available through the website. Installing that update would replace all system files.
Is that a viable solution, or am I misunderstanding the problem?
-
Glad to help.
That function is easy to miss. All those extra conditionals make it a tough read.
Re-order Pages Plugin?
in WordPress
Posted
Right, what Bruce said. Depending on the version of WordPress you're using, you may also need to make sure the template tag generating your list of pages is set to observe your manual ordering. The default tag is usually:
But that doesn't always do what you want it to do. If `wp_list_pages()` is the tag you're using, you'll need to make sure you're setting the `sort_column` argument:
There are other tags that can generate lists of pages and you might be using something different than this, but `wp_list_pages` is probably the most common.