ajd777
Forum Replies Created
-
Forum: Fixing WordPress
In reply to: freezes during “save” or “publish”This is probably a PHP memory problem. You may want to increase it.
Forum: Fixing WordPress
In reply to: blogroll database error, anyone know how to fix it?WordPress has changed to use wp_list_categories to display categories now. Just switch whatever function your theme uses now with ‘ wp_list_categories’.
Forum: Fixing WordPress
In reply to: How do I alter the ? character that precedes wp_titlethis is why we shouldn’t try and do support with a 100+ fever and flu.”
Ahah I knew something had to have been wrong.If for some reason you actually need it to show up in other places and only want it to remove just first one:
<?php echo trim(wp_title('»',false), '» ');?>
Forum: Fixing WordPress
In reply to: How do I alter the ? character that precedes wp_titlewp_title automatically outputs the symbol. Just pass the argument ” to the title and it should work.
EG
<?php wp_title('');?>
Forum: Fixing WordPress
In reply to: only x words of a postOpen your current theme’s file named index.php and look for a line with the word the_content in it. Replace the_content with the_excerpt .
Forum: Everything else WordPress
In reply to: Convert to PHP or stay with ASP?All around I prefer PHP: it is faster than asp, cheaper, and has most things already built into it.
Forum: Fixing WordPress
In reply to: HOWTO: Disable blogrollOpen wp-admin/menu.php
For v 2.1 comment out the line:
$menu[20] = array(__(‘Blogroll’), ‘manage_links’, ‘link-manager.php’);
and the lines:
$submenu[‘link-manager.php’][5] = array(__(‘Manage Blogroll’), ‘manage_links’, ‘link-manager.php’);
$submenu[‘link-manager.php’][10] = array(__(‘Add Link’), ‘manage_links’, ‘link-add.php’);
$submenu[‘link-manager.php’][20] = array(__(‘Import Links’), ‘manage_links’, ‘link-import.php’);For V 2.0.X comment out the line:
$menu[20] = array(__(‘Links’), ‘manage_links’, ‘link-manager.php’);And the lines:
$submenu[‘link-manager.php’][5] = array(__(‘Manage Links’), ‘manage_links’, ‘link-manager.php’);
$submenu[‘link-manager.php’][10] = array(__(‘Add Link’), ‘manage_links’, ‘link-add.php’);
$submenu[‘link-manager.php’][15] = array(__(‘Link Categories’), ‘manage_links’, ‘link-categories.php’);
$submenu[‘link-manager.php’][20] = array(__(‘Import Links’), ‘manage_links’, ‘link-import.php’);Forum: Fixing WordPress
In reply to: Large database, Slow performance.Upgrading to 2.1 may help. I don’t have a copy of 2.0.7 handy, but does it add a limit? If not there should be a filter for you to add it in.
Forum: Developing with WordPress
In reply to: Updating permalink-structure crashes my serverYour best bet is to get a dump of the rewrite rules for the pages; then hack the core and have it only create new rewrite rules for pages over a certain ID; then manually include your dump of page rewrite rules.
This way you will cut out a few thousand queries.
Forum: Themes and Templates
In reply to: Help! Navigation questionYes you can. Just open your them files and look for functions named things like: wp_list_pages. One by one (with a little trial and error) take them out.
EDIT: Although looking at your site you seem to have done it.
Forum: Themes and Templates
In reply to: Call to undefined function: bloginfo()@doodlebee: bloginfo is a function that retrieves options form the database. There is no option ‘header’;
@redparade: Are you going directly to the url for the header? Because it seems to me that the rest of wordpress isn’t loading. What happens if you just take bloginfo out?
Forum: Fixing WordPress
In reply to: Redirecting To A New Permalink StructureAdd this to the VERY top of your theme’s 404 page.
Change https://localhost/wordpress to your default wordpress folder.
This just does posts and possibly pages that end in the id (with or without the trailing url) Categories etc will have to be done elsewhere or by hand.
<?php
//Kinda obvious
$rf = $_SERVER[‘REQUEST_URI’];
$rf = explode(‘/’,$rf);
$last = count($rf);
//Filter out regular 404 that arn’t old urls
if(is_numeric($rf[$last-1])){
$post_id = $rf[$last-1];
}elseif(is_numeric($rf[$last-2])){
$post_id = $rf[$last-2];
}
// No sense loading WP if there isn’t an id
if ( $post_id ) {
// Oh fine we will load wordpress
define(‘WP_USE_THEMES’, false);require(‘https://localhost/wordpress/wp-blog-header.php’);
$post = get_post($post_id);
//Well hope it is the right post. If not, ohwell. We tried.
if($post){
//Lets get the new URL
$new_link = get_permalink($post_id);
//We don’t want google to get angry with us.
header(“HTTP/1.1 301 Moved Permanently”);
header(“Location: $new_link”);
}
}
?>Forum: Your WordPress
In reply to: Using WP 2.1 as a CMS@web
Those are pages not categories.You can hackishly remove the category by setting the base to ‘/.’ (sometimes you have to set it to ‘./’). This can cause some conflicts though if you have pages with the same name as the category.
Forum: Installing WordPress
In reply to: problem uploading a local installationMake sure you aren’t getting a javascript error, and that the WYSIWYG is turned on.
Forum: Plugins
In reply to: Days since Birth plugin@otto42
No, that was just an error in my copy and paste. I forgot to change it back. The code itself broke with 2.1 because wordpress now uses a post status of future rather than $now for posts from the past.@cythera
The code itself is correct, the forums gave it a magic quote which invalidated it. if it doesn’t work this time, just manually change type in the quote.
$first_post = $wpdb->get_results("SELECT post_date_gmt FROM $wpdb->pposts WHERE post_status = 'publish' ORDER BY post_date ASC Limit 1")