WoW:API GetChannelName: Difference between revisions

m
no edit summary
No edit summary
mNo edit summary
Line 7: Line 7:
----
----
;''Arguments''
;''Arguments''
:(Number id or String id)


:;id : The id of the channel you want to query, either as a number (1) or as a string ("1"). It seems that ("Trade") also works.
:;id : The numeric id of the channel you want to query, or a string containing the name of the channel.


----
----
Line 15: Line 14:


:;id : a number containing the id of the channel, e.g. 2, or 0 if the channel is not found
:;id : a number containing the id of the channel, e.g. 2, or 0 if the channel is not found
:;name : a string containing the name of the channel, e.g. "Trade - Stormwind", or nil if the channel is not found.
:;name : a string containing the name of the channel, e.g. "Trade - Stormwind", or nil if the channel is not found or the id parameter was a name.
----
----
;''Important''
;''Important''


If the channel argument is the channel name (ie "testchan1"), then the returned channel name is a nil value.<br>
If the channel argument is the channel name (ie "testchan1"), then the returned channel name is a nil value.
If the channel argument is the channel number (ie 6 or "6"), then the returned channel name is correct.<br>
If the channel argument is the channel number (ie 6 or "6"), then the returned channel name is correct.
The channel id returns correctly in both cases.<br>
The channel id returns correctly in both cases.
   
   
----
----