Forum Replies Created

Viewing 6 replies - 1 through 6 (of 6 total)
  • joelgilmore

    (@joelgilmore)

    Yep, I second that – I work on a collaborative blog, and typically queue up a number of posts ready to go in my Drafts folder. But I like to have the other authors review my posts before they go live, and hence want some way of flagging posts for attention.

    Perhaps one could add an extra field to the posts through the UserExtra plugin, then filter the post titles in Manage according to that? (Perhaps chaning their colours, like the traffic light styling above) I’m happy to hack around for a bit, if anyone could give me an idea of where to start?

    Thread Starter joelgilmore

    (@joelgilmore)

    If you want something done right, you have to do it yourself! I hacked classes.php, and the handle_404 function right at the end, so that if a category or an author currently has no posts associated with it, it still gives me that page (author.php or category.php). The ammended code is:

    if (is_author() || is_category()){
    if ((!$wp_query->get_queried_object()) && !is_404() && !is_search() && ( $this->did_permalink || (!empty($_SERVER['QUERY_STRING']) && (false === strpos($_SERVER['REQUEST_URI'], '?'))) ) ) {
    $wp_query->set_404();
    status_header( 404 );
    } elseif( is_404() != true ) {
    status_header( 200 );
    }
    } else { // If not in an author or category page
    if ( (0 == count($wp_query->posts)) && !is_404() && !is_search() && ( $this->did_permalink || (!empty($_SERVER['QUERY_STRING']) && (false === strpos($_SERVER['REQUEST_URI'], '?'))) ) ) {
    $wp_query->set_404();
    status_header( 404 );
    } elseif( is_404() != true ) {
    status_header( 200 );
    }
    }// End author/cat select

    Just replace the single if statement with this double pack. Apologies for lack of indents, I can work out how to do that in this comment.

    Also, can someone tell me where I should submit these fixes/upgrades/whatever so that they don’t get buried?

    joelgilmore

    (@joelgilmore)

    Heya!

    Very interested, but the download link (https://www.xyooj.com/blog/wp-content/shared/custom-contact.zip) doesn’t seem to work. Can you confirm?

    Cheers!

    Joel

    I also had the same problem – I got to the first upgrade screen, then when I clicked to go on (page1) I just got blank screens, there and everywhere.

    I fixed it by uncommenting the DISABLE_CACHE line (see earlier post). My server runs PHP 4.2.2.

    Everything seems to work now, although if someone could explain what I’ve just disabled, and what I’m missing out on…?

    Cheers,
    Joel

    Thread Starter joelgilmore

    (@joelgilmore)

    Hi Kafkaesqui,

    Thanks for your response. (I did realise that update_category_cache is to store a list of all the categories, but it’s accessed from within get_the_category via update_post_category_cache.)

    Reading the code again now, I realise that get_the_category() calls sort() on the array, which should reduce it to being indexed by 0,1,2 etc. and give the correct documented effect. Sorry for not being more thorough! However, if the array has only one element, it seems that sort (at least on my platform) doesn’t re-index the array. e.g., this
    <?php $test=array(5=>'beetle'); sort($test); echo '0:'.$test[0].'--- 5:'.$test[5].'---'; ?>
    returns
    0:--- 5:beetle---
    For posts with multiple categories, it works fine.

    I tried googling for this effect, and it seems that it was a bug at some time, but has perhaps been resolved. I guess I need to check what version of PhP my server runs. [Checked: It’s 4.2.2.]

    Can anyone else confirm or deny this effect?

    Cheers,
    Joel

    Thread Starter joelgilmore

    (@joelgilmore)

    Well, in solving my own problem (partly) I downloaded the text file, and put it in my wp-content directory, and asked Spam Karma to source its blacklist from there (just gave it an absolute link to that file, which I called blacklist.txt).

    Of course, this means I’ll have to MANUALLY update the blacklist file myself. I tried to tell Spam Karma not to automatically update every three days – but when you switch off that checkbox and update options, it switches back on again AND resets the number of days to 3.

    If anyone can think of a better way of doing all this, or can explain where the problem came from in the first place, I’d love to hear from you ?? Otherwise, hopefully this helps at least a few people in a similar predicament.

Viewing 6 replies - 1 through 6 (of 6 total)