From WikiChip
Difference between revisions of "mirc/identifiers/$msgtags"
< mirc‎ | identifiers

(Example)
 
Line 17: Line 17:
  
 
== Example ==
 
== Example ==
<source lang="mIRC">//echo -a $msgtags(0)</source>
+
<source lang="mIRC">
 +
ON *:TEXT:*:#: { echo $chan INFO: $nick -> $msgtags(account) -> $msgtags(msgid).tag -> $msgtags(msgid).key - Total: $msgtags(0) }
 +
</source>
  
 
== Compatibility ==
 
== Compatibility ==

Latest revision as of 08:41, 22 September 2021

$msgtags returns the full @ prefixed tags line (IRCv3 message tags) which are removed from incoming server messages. $msgtags() returns informations about specifics tags


Synopsis[edit]

$msgtags
$msgtags(tag|N)

Parameters[edit]

  • tag - returns the tag if it exists, $null otherwise
  • N - returns the Nth tag, if N = 0, returns the total number of tags

Properties[edit]

If a parameter is provided, you can use the following properties:

  • .tag - returns the name of the Nth tag
  • .key - returns the associated value of the Nth tag or of the given tag

Example[edit]

ON *:TEXT:*:#: { echo $chan INFO: $nick -> $msgtags(account) -> $msgtags(msgid).tag -> $msgtags(msgid).key - Total: $msgtags(0) }

Compatibility[edit]

Added: mIRC v7.42
Added on: 17 Jul 2015
Note: Unless otherwise stated, this was the date of original functionality.
Further enhancements may have been made in later versions.


See Also[edit]