JavaScript Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsWeb DesignJavaScript Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old August 9th, 2005, 02:45 PM
ChiefWigs1982's Avatar
ChiefWigs1982 ChiefWigs1982 is offline
Cunning Linguist
Dev Shed God 10th Plane (9500 - 9999 posts)
 
Join Date: Jul 2003
Location: I used to live at home, now I stay at the house
Posts: 9,852 ChiefWigs1982 User rank is Brigadier General (60000 - 70000 Reputation Level)ChiefWigs1982 User rank is Brigadier General (60000 - 70000 Reputation Level)ChiefWigs1982 User rank is Brigadier General (60000 - 70000 Reputation Level)ChiefWigs1982 User rank is Brigadier General (60000 - 70000 Reputation Level)ChiefWigs1982 User rank is Brigadier General (60000 - 70000 Reputation Level)ChiefWigs1982 User rank is Brigadier General (60000 - 70000 Reputation Level)ChiefWigs1982 User rank is Brigadier General (60000 - 70000 Reputation Level)ChiefWigs1982 User rank is Brigadier General (60000 - 70000 Reputation Level)ChiefWigs1982 User rank is Brigadier General (60000 - 70000 Reputation Level)ChiefWigs1982 User rank is Brigadier General (60000 - 70000 Reputation Level)ChiefWigs1982 User rank is Brigadier General (60000 - 70000 Reputation Level)ChiefWigs1982 User rank is Brigadier General (60000 - 70000 Reputation Level)ChiefWigs1982 User rank is Brigadier General (60000 - 70000 Reputation Level)  Folding Points: 50746 Folding Title: Beginner FolderFolding Points: 50746 Folding Title: Beginner FolderFolding Points: 50746 Folding Title: Beginner Folder
Time spent in forums: 3 Months 2 Weeks 4 Days 12 h 23 m 32 sec
Reputation Power: 698
Facebook
New Syntax Highlighting...

Hey everyone, the admins have implemented a new hack to the
forums, allowing you to post your code with nicely coloured text
rather than just the normal black or the old php stuff.

More details can be found here:
http://forums.devshed.com/t279108/s.html

Html code:
[highlight=html4strict]your code here[/highlight]

For example:
html4strict Code:
Original - html4strict Code
  1.  
  2. <?xml version="1.0" encoding="iso-8859-1"?>
  3. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
  4.    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
  5. <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
  6. <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
  7. <title>Untitled Document</title>
  8. </head>
  9.  
  10. <h1 class="header_text">
  11.     Nice One!
  12. </h1>
  13. <p id="main_content">
  14.     <span style="color:red;">Lorem ipsum</span> dolor sit amet, consectetur
  15.     adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore
  16.     magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco
  17.     laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in
  18.     reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur.
  19.     Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia
  20.     deserunt mollit anim id est laborum.
  21. </p>
  22. </body>
  23. </html>

The same goes for JavaScript code:
[highlight=javascript]your code here[/highlight]
javascript Code:
Original - javascript Code
  1.  
  2. <script type="text/JavaScript">
  3. function doStuff()
  4. {
  5.     //declare vars...
  6.     var foo='bar';
  7.     var o=document.getElementByid('something');
  8.     /*
  9.         -Take the value and convert to a float.
  10.         -alert the value
  11.     */
  12.     var v=parseFloat(o.value);
  13.     alert(v);
  14. }
  15. </script>

The same goes for CSS highlighting:
[highlight=css]your code here[/highlight]
css Code:
Original - css Code
  1.  
  2. /*Comments*/
  3. body
  4. {
  5.     property:value;
  6. }
  7. body, div
  8. {
  9.     property:value;
  10. }

As you can see from the thread I linked, there are many many
other languages supported, but these three examples are more
likely to be used than any other in this particular forum...

Have fun with it, and please do use this feature, I'm sure it will
make things much easier for us to read/understand, rather than
just posting chunks of code.

Enjoy!

--Jon.
__________________
Support requests via PM will be ignored!
Sites: Route of Queue | Sinthetic - Alternative UK Hiphop
Read These: The General Rules Thread | The General FAQ Thread | NEW USERS - How to post a question

Sign up with Matched.co.uk and earn up to £15 per website every month!


Reply With Quote
Reply

Viewing: Dev Shed ForumsWeb DesignJavaScript Development > New Syntax Highlighting...


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

 Free IT White Papers!
 
Accelerating Trading Partner Performance
One in five. That's how many partner transactions have at least one error. That is an amazing statistic, particularly given the extraordinary leaps in innovation across the global supply chain during the past two decades. Download this white paper to learn more.

 
Competing on Analytics
This Tech Analysis is designed to help identify characteristics shared by analytics competitors, and includes information about 32 organizations that have made a commitment to quantitative, fact-based analysis.

 
Cost Effective Scaling with Virtualization and Coyote Point Systems
An overview of the industry trend toward virtualization, how server consolidation has increased the importance of application uptime and the steps being taken to integrate load balancing technology with virtualized servers.

 
Five Checkpoints to Implementing IP Telephony
Implementation planning for IP PBX software and IP telephony has become vital as businesses replace discontinued legacy PBX phone systems. This informative whitepaper outlines five "checkpoints" for any implementation plan that will help make IP communications a successful proposition.

 
Hosted Email Security: Staying Ahead of New Threats
In the last two years, email has become a fierce battleground between the nefarious forces of spam and malware, and the heroes of messaging protection. The spam volumes increased alarmingly every month, bringing clever new forms of phishing and virus propagation attacks.

 

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 6 hosted by Hostway