[HELP] Syntax colored code:

If you want to help us or give some corrections / codes, put it here :)

Moderators: osRose dev team, ospRose dev team, osiRose dev team, Moderators

[HELP] Syntax colored code:

Postby lmame on Mon Aug 06, 2007 7:15 pm

If you want to insert (and see) syntaxed colored code, use "code" bbcode:

Example for C / C++ code:
  1.  
  2. [code=c]
  3. int main(int argc, char *argv[])
  4. {
  5.     srand( (unsigned)time(NULL) );
  6.     srand( rand()*time(NULL) );        
  7.     StartSignal( );
  8. }
  9. [/code]
  10.  


Gives:
  1.  
  2. int main(int argc, char *argv[])
  3. {
  4.     srand( (unsigned)time(NULL) );
  5.     srand( rand()*time(NULL) );        
  6.     StartSignal( );
  7. }
  8.  



For PHP:
  1.  
  2. [code=php]
  3. <?php
  4. /**
  5.  * test
  6.  *
  7.  */
  8. define('DIR_AUTH', dirname(__FILE__));
  9. echo("this is a test");
  10. ?>
  11. [/code]
  12.  


Gives:
  1.  
  2. <?php
  3. /**
  4.  * test
  5.  *
  6.  */
  7. define('DIR_AUTH', dirname(__FILE__));
  8. echo("this is a test");
  9. ?>
  10.  
The world is full of love and peace ^_^
Image
User avatar
lmame
Admin
Admin
 
Posts: 8997
Joined: Mon Aug 06, 2007 4:42 pm
Location: July City

Return to Submit Code

Who is online

Users browsing this forum: No registered users and 4 guests

cron