petterrogstad
Forum Replies Created
-
Forum: Installing WordPress
In reply to: My webhotel doesnt support crone jobsFound this in installation wordpress readmee version 1.5
“Post via Email
You can post from an email client! To set this up go to your “Writing” options screen and fill in the connection details for your secret POP3 account. Then you need to set up wp-mail.php to execute periodically to check the mailbox for new posts. You can do it with Cron-jobs, or if your host doesn’t support it you can look into the various website-monitoring services, and make them check your wp-mail.php URL. “This is really my problem:
1. my host do not support cron-jobs
2. I do not understand how to make my website-monitoring services check my wp-mail.php url
3. Is this neccessary for posting via email?If wp-cron solves the problem how do I insert the command that is I understand something like:
http://domain.com/blogurl/wp-mail.php > /dev/null
Please be patient with mee. I have no unix knowledge whatsoever but really want wordpress up and running with email posting.
I have pasted the wp-cron php file if somebody is so point out what needs to be done.
<?php
/*
Plugin Name: wp-cron
Plugin URI: http://www.skippy.net/
Description: periodic execution of actions
Version: 1.0
Author: Scott Merrill
Author URI: http://www.skippy.net/Copyright (c) 2005 Scott Merrill (skippy@skippy.net)
Released under the terms of the GNU GPL
*/add_action(‘plugins_loaded’, ‘wp_cron_init’);
///////////////////////
function wp_cron_init() {
// first, get the current time
$wp_cron_now = time();
// fetch the timestamps
if ( (FALSE === get_option(‘wp_cron_15_lastrun’))
|| (FALSE === get_option(‘wp_cron_hourly_lastrun’))
|| (FALSE === get_option(‘wp_cron_daily_lastrun’)) )
{
update_option(‘wp_cron_15_lastrun’, $wp_cron_now);
update_option(‘wp_cron_hourly_lastrun’, $wp_cron_now);
update_option(‘wp_cron_daily_lastrun’, $wp_cron_now);
}
$wp_cron_15_lastrun = get_option(‘wp_cron_15_lastrun’);
$wp_cron_hourly_lastrun = get_option(‘wp_cron_hourly_lastrun’);
$wp_cron_daily_lastrun = get_option(‘wp_cron_daily_lastrun’);if ($wp_cron_now > ($wp_cron_daily_lastrun + 864000)) {
update_option(‘wp_cron_daily_lastrun’, $wp_cron_now);
add_action(‘shutdown’, ‘wp_cron_daily_exec’);
}
if ($wp_cron_now > ($wp_cron_hourly_lastrun + 3600)) {
update_option(‘wp_cron_hourly_lastrun’, $wp_cron_now);
add_action(‘shutdown’, ‘wp_cron_hourly_exec’);
}
if ($wp_cron_now > ($wp_cron_15_lastrun + 900)) {
update_option(‘wp_cron_15_lastrun’, $wp_cron_now);
add_action(‘shutdown’, ‘wp_cron_15_exec’);
}
}//////////////////////////
// these execute the various hooks
function wp_cron_15_exec() {
do_action(‘wp_cron_15’);
}function wp_cron_hourly_exec() {
do_action(‘wp_cron_hourly’);
}function wp_cron_daily_exec() {
do_action(‘wp_cron_daily’);
}?>