alert()
The method outputs a string to the Info block after the server script execution. If there are multiple text output commands used, their results are concatenated.
Parameter(s):
Name | Type | Mandatory | Default |
---|
message | string | | N |
Return:
Type | Description |
---|
Void | This method does not return a value. |
alert('Message');
//Message
echo()
The method outputs one or more string to the Info block after the server script execution.
Parameter(s):
Name | Type | Mandatory | Default |
---|
messages | string | Y | N |
Return:
Type | Description |
---|
Void | This method does not return a value. |
echo('Message');
//Message
json()
The method outputs a string containing the JSON representation of the specified value to the Info block under the server script after the execution.
Parameter(s):
Name | Type | Mandatory | Default |
---|
value | any | Y | N |
Return:
Type | Description |
---|
Void | This method does not return a value. |
json('{"key":"value"}')
//"{\"key\":\"value\"}"
print()
The method is used to display a string in the Info block after the server script execution.
Parameter(s):
Name | Type | Mandatory | Default |
---|
message | any | Y | N |
Return:
Type | Description |
---|
Integer | Returns the number of characters in the transmitted message. |
print('Message')
//Message
print_r()
The method outputs human readable information about the variable in the server script. If a string, integer, or floating point number is given, the value itself will be printed. If an array is given, the values will be presented in a format that shows keys and elements. Similar designations are used for objects.
Parameter(s):
Name | Type | Mandatory | Default |
---|
value | any | Y | N |
Return:
Type | Description |
---|
Void | This method does not return a value. |
print_r({key: 'value'});
//V8Object Object
//(
// [key] => value
//)
sleep()
The method is used to delay the execution of a server script.
Parameter(s):
Name | Type | Mandatory | Default |
---|
seconds | integer | Y | N |
Return:
Type | Description |
---|
Void | This method does not return a value. |
ss.info(new SimpleDateTime().getValue());
sleep(10);
ss.info(new SimpleDateTime().getValue());
// Info: 2022-09-28 09:46:59
// Info: 2022-09-28 09:47:09
If the delay exceeds the server script execution timeout, use the ss.eventQueueScheduled() delayed event to execute the delayed part of the script.
var_dump()
The method accepts a set of parameters of different types, the information about each of them is displayed in the Info block after the server script execution.
Parameter(s):
Name | Type | Mandatory | Default |
---|
value | any | Y | N |
Return:
Type | Description |
---|
Void | This method does not return a value. |
var_dump({key: 'value'});
//object(Object)#835396 (1) {
// ["key"] =>
// string(5) "value"
//}