Welcome! This page is using CodeRay 1.1.2.
We currently have
3063 rays
in the database.
You can add a
New Ray
or browse the posted rays by pages.
sdzfg |
34 lines
of
CSS
|
1.51 KB |
Show |
Edit |
Expand |
1
2
3
4
5
6
7
8 |
.CodeRay {
background-color: #232323;
border: 1px solid black;
font-family: 'Courier New', 'Terminal', monospace;
color: #E6E0DB;
padding: 3px 5px;
overflow: auto;
font-size: 1... |
|
HELP! |
26 lines
of
Ruby
by
Fayimora
|
541 Bytes |
Show |
Edit |
Expand |
1
2
3
4
5 |
def coderay(text)
text.gsub(/\<code( lang="(.+?)")?\>(.+?)\<\/code\>/m) do
content_tag("notextile", CodeRay.scan($3, $2).div(:css => :class))
|
|
bum |
46 lines
of
Plain text
|
1.33 KB |
Show |
Edit |
Expand |
1
2
3
4
5
6
7
8
9
10
11
12
13 |
user www-data;
worker_processes 4;
error_log /opt/nginx/logs/error.log;
pid /var/run/nginx.pid;
events {
worker_connections 8192;
use epoll;
}
http {
passenger_... |
|
Unique Characters in a String |
47 lines
of
Java
by
Fayimora
|
1.06 KB |
Show |
Edit |
Expand |
1
2
3
4
5
6
7
8 |
class C1_1
{
public static void main(String[] args)
{
System.out.println(isUnique("fayimora"));
System.out.println(isUnique("fayi"));
System.out.println(isUnique("aaaaaaaa"));
Syst... |
|
nthtn |
11 lines
of
HAML
by
blah
|
247 Bytes |
Show |
Edit |
Expand |
1
2
3
4
5
6 |
!!!
%html
%head
%meta{:charset => 'utf-8'}
%meta{:content => 'IE=edge,chrome=1', :http-equiv='X... |
|
Test |
10 lines
of
Ruby
by
Bob
|
249 Bytes |
Show |
Edit |
Expand |
1
2
3
4
5
6
7
8
9 |
class User < ActiveRecord::Base
named_scope :inactive, :conditions => {:active => false} do
def activate
each { |i| i.update_attribute(:active, true) }
end
end
end
|
|
easy xml |
50 lines
of
XML
|
1.5 KB |
Show |
Edit |
Expand |
1
2
3
4
5
6
7 |
<settings>
<setting>
<id>colors</id>
<value class="list">
<legendColor position="0" name="COL0" hexColor="F0F0F0" />
<legendColor position="1" name="COL1" hexColor="E6FFE6" />
<... |
|
htacces sample |
63 lines
of
diff
|
1.57 KB |
Show |
Edit |
Expand |
|
test |
6 lines
of
JavaScript
|
177 Bytes |
Show |
Edit |
Expand |
1
2
3
4
5
6 |
<script>
$(document).ready(function(){
$("ul.varieties li:last-child").addClass("last-child");
$("ul.varieties li:first-child").addClass("first-child");
});
</script> |
|
k2008 |
40 lines
of
C
by
MiGaNuTs
|
715 Bytes |
Show |
Edit |
Expand |
1
2
3
4
5
6
7
8
9
10
11 |
#include <WProgram.h>
#include <Wire.h>
#include <DS1307.h>
int rtc[7];
int ledPin = 13;
void setup()
{
DDRC|=_BV(2) |_BV(3);
PORTC |=_BV(3);
pinMo... |
|