This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $(document).ready(function() { | |
| $('#new-to-do-item').keyup(function() { | |
| alert("key pressed"); | |
| }); | |
| }); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $(document).ready(function() { | |
| $('h3').click(function() { | |
| $(this).text("ehh... Maybe tomorrow"); | |
| }); | |
| }); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $(document).ready(function() { | |
| alert("it's working!"); | |
| }); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!doctype html> | |
| <html> | |
| <head> | |
| <title>Hello!</title> | |
| <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script> | |
| <script src="./my_stuff.js"></script> | |
| </head> | |
| <body> | |
| <h1>Hello World!</h1> | |
| <div> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!doctype html> | |
| <html> | |
| <head> | |
| <title>Hello!</title> | |
| </head> | |
| <body> | |
| <h1>Hello World!</h1> | |
| <div> | |
| <h3 data-stuff="to dos">Things I would like to do today:</h3> | |
| <input type="text" id="new-to-do-item" placeholder="Enter a new todo item..."> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| require 'open-uri' | |
| print "Enter a website domain you like (without the http://): " | |
| website = gets.chomp | |
| if website.count(".") >= 2 | |
| first_letter = website.index(".") + 1 # we want the letter just after the first dot | |
| after_first_letter = first_letter + 1 | |
| last_letter = (website.index(".", after_first_letter) - 1) | |
| website_title = website[first_letter..last_letter] | |
| elsif website.count(".") == 1 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| p "Enter a number: " | |
| first = gets.chomp.to_i | |
| p "Enter a second number: " | |
| second = gets.chomp.to_i | |
| def multiply(num1, num2) | |
| num1 * num2 | |
| end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| p "Enter your favorite number: " | |
| number = gets.chomp | |
| p "The number you entered was #{number}" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| puts "Hello World!" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class Report < ActiveRecord::Base | |
| attr_accessible :title | |
| belongs_to :presenter | |
| delegate :team_name, to: :presenter, prefix: true | |
| end |