logMessage()

From Hack Wars Wiki

Jump to: navigation, search


Function information for logMessage()
Function logMessage(string message)
API Watch, HTTP
Cost $50
Level 1
CPU Usage 1
Description Puts a message in your logging database.


Watch Example

This function is often used to log information about why the watch was fired:

logMessage("The watch observing port " + getPort() + " was fired by " + getTargetIP());


This code would put a message in your database telling what port the watch was monitoring and the IP which caused it to fire.

See getPort(), getTargetIP().

HTTP Example

This function is often used to log who visits your website:

logMessage(getVisitorIP() +" has visited your website.");


This code would put a message in your database telling the IP that visited your website.

Personal tools