Forums

Category error in blog-by-mail (2 posts)

  1. lofcom
    Member
    Posted 5 years ago #

    I'm getting a consistant error in blog-by-mail - it appears that wp-mail.php doesn't have a category set:
    SQL/DB Error:
    [You have an error in your SQL syntax near ')' at line 1]
    INSERT INTO wp_posts (post_author, post_date, post_content, post_title, post_category) VALUES (1, '2004-02-20 09:30:31', 'This is the important post I\'m making via email... And this is the continuation of the posting over here.', 'A test post for WordPress', )
    This then obviously causes another error:
    SQL/DB Error:
    [You have an error in your SQL syntax near '' at line 1]
    SELECT * FROM wp_post2cat WHERE post_id = 0 AND category_id =
    I have a default category set in the Options, so I assume the fault is in wp-mail.php, but I haven't had time to wade through it all yet (Hint: Self-Commenting Code Ain't) - anyone else run into this problem and have a simple solution?

  2. lofcom
    Member
    Posted 5 years ago #

    Pulled the file, dropped it into the test blog as wp-mail.php, sent a test message, and perfect success - although this doesn't output any information on success, which kinda threw me for a sec.
    I <EM>do</EM> want to compare the two and drop the setup code into the original wp-mail.php file (changing the default set from a hard-coded 1 to the value of wp_options->default_post_category), since the debug code in the distro wp-mail.php outputs much better information, but this works fine for now - much thanks!
    Wonder how this got dropped, and if it is the cause of all the other folks having problems blogging via email?

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.