This article is a mirror article of machine translation, please click here to jump to the original article.

View: 11379|Reply: 1

[Program beautification] Discuz!

[Copy link]
Posted on 6/5/2017 11:20:41 AM | | |

This function is used to send short messages (including private messages, system messages, reminder messages, etc.)

The function is defined at:\source\function\function_core. PHP
Called helper_pm assistant, file: \source\class\helper\helper_pm.php
sendpm($toid, $subject, $message, $fromid = '');

Parameter meaning:

There are four parameters, the first three are mandatory parameters, and the last one is optional;

The first parameter is the user UID of the person receiving the short message;

The second parameter is the title of the short message;

The third parameter is the body content of the short message;

The fourth parameter is the user UID of the person sending the short message;

Note: When the first parameter $toid is 0, the message type is public message, and when the $fromid is 0, the message type is system message, $message the parameter of this message content, HTML is not supported, but Discuz! code is supported.





Previous:Simulates Apple's waiting circle interface
Next:discuz standalone php file to get the uid of the login
 Landlord| Posted on 6/5/2017 12:15:14 PM |

Discuz function to send reminders: notification_add
Calling method: notification_add(2, 'system', $system_notice, $notice, 1);

You can replace the value in .$system_notice by adding variables to $notice by defining an array
For example, $system_notice = "I am {name}"
$notice = array(
‘name’ => ‘www.itsvse.com
);
The result after entering is "I."www.itsvse.com”.

Disclaimer:
All software, programming materials or articles published by Code Farmer Network are only for learning and research purposes; The above content shall not be used for commercial or illegal purposes, otherwise, users shall bear all consequences. The information on this site comes from the Internet, and copyright disputes have nothing to do with this site. You must completely delete the above content from your computer within 24 hours of downloading. If you like the program, please support genuine software, purchase registration, and get better genuine services. If there is any infringement, please contact us by email.

Mail To:help@itsvse.com