Masz, skleiłem Ci coś takiego:
<?php
/* Some settings */
$path_to_board = 'C:/xampp/htdocs/312_4d';
/* Load IP.Board stuff */
define( 'IPS_PUBLIC_SCRIPT', 'index.php' );
define( 'IPB_THIS_SCRIPT', 'public' );
require_once( $path_to_board . '/initdata.php' );
require_once( IPS_ROOT_PATH . 'sources/base/ipsRegistry.php' );
require_once( IPS_ROOT_PATH . 'sources/base/ipsController.php' );
$reg = ipsRegistry::instance();
$reg->init();
/* Try send PM message */
try
{
/* Load messenger class */
require_once( IPSLib::getAppDir( 'members' ) . '/sources/classes/messaging/messengerFunctions.php' );
$messenger = new messengerFunctions( $reg );
/* Set up some data */
$toID = 1;
$fromID = 12;
$title = 'message_title';
$msg = 'message_content';
/* Send */
$messenger->sendNewPersonalTopic( $toID, $fromID, array(), $title, $msg,
array( 'origMsgID' => 0,
'fromMsgID' => 0,
'postKey' => md5( microtime() ),
'trackMsg' => 0,
'addToSentFolder' => 0,
'hideCCUser' => 0,
'forcePm' => 1,
'isSystem' => FALSE
)
);
}
catch( Exception $error )
{
#
}
Oczywiście ID lub treść/tytuł do zmiany.
Efekt: