Welcome! This page is using CodeRay 1.1.0 (beta).

We currently have 2469 rays in the database.
You can add a New Ray or browse the posted rays by pages.

Page 126, 10 entries

nthtn 11 lines of HAML by blah 247 Bytes Show Edit Expand
1
2
3
4
5
6
!!!
%html
  %head
    %meta{:charset => 'utf-8'}
    <!-- Always force latest IE rendering engine (even in intranet) & Chrome Frame -->
    %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

# Re-a...
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
1
2
3
4
5
6
7
8
9
10
11
# protect the htaccess file
<files .htaccess>
order allow,deny
deny from all
</files>

# disable the server signature
ServerSignature Off

# limit file uploads to 10mb
LimitRequestBody 10...
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);  // POWER:Vcc Gnd
  PORTC |=_BV(3);  // VCC PINC3
  pinMo...
test 1 line of Ruby by robot 18 Bytes Show Edit Expand
1
p 'Hello World!!!'
PHP 7 lines of PHP 97 Bytes Show Edit Expand
1
2
3
4
5
6
7
@include("hello.php");

if($a) {
    echo "this";
} else {
    @include("goodbye.php");
}
easy xml 21 lines of XML by asm0dey 1.04 KB Show Edit Expand
1
2
3
4
5
6
<pre><code class="xml"><settings>
  <setting>
    <id>colors</id>
    <value class="list">
      <legendColor position="0" name="COL0" hexColor="F0F0F0"/>
      <legendColor position="1" name=...
php example 5 lines of PHP by alekzonder 68 Bytes Show Edit Expand
1
2
3
4
5
echo '123';
$arr[] = 123;
for ($i = 1;$i< 2; $i++) {
print $i;
}

Page 126, 10 entries