We have always been able to use CODE tags in the forum to give plain monospaced formatting to code snippets in posts. I just finished adding the ability to do syntax highlighting for the following languages:
- PHP (as [PHPS])
- JavaScript (as [JSS])
- CSS (as [CSSS])
- SQL (as [SQLS])
- C++ (as [CPPS])
- HTML (as [HTMLS])
- Java (as [JAVAS])
- Tcl (as [TCLS])
- BASH (as [BASHS])
I will be investigating how to add ActionScript since we use that frequently. The above options were from a forum mod. Here's an example of Java:
Java Code:if (useTwoStepLogin) { // no DB lookup here if (evictGhostUsers && getApi().isUserLoggedIn(userName)) { // we assume that this other user is a ghost. // Evict doesn't really send the evicted user any message. getApi().evictUserFromServer(userName, response); return ChainAction.OkAndContinue; } else if (getApi().isUserLoggedIn(userName)) { response.setString(LoginResultEnum.Status.name(), LoginResultEnum.AlreadyLoggedOn.name()); return ChainAction.Fail; } }


Reply With Quote
