This file contains 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
/******************************************************************************* | |
* Write Table for Messages Table Yammer | |
* *****************************************************************************/ | |
private DataTable writeTableMessages(IProgress prog, ITableWriter tblWriter) | |
{ | |
if (_dtMessages == null) | |
{ | |
// Requete sur API Yammer | |
string res = _oauth.Get("https://www.yammer.com/api/v1/messages.json"); |
This file contains 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
//La syntaxe de développement n'est pas respecté. | |
//Juste un exemple de POO. | |
// Ma classe Car | |
public class Car{ | |
public integer roues; | |
public integer porte; | |
public integer puissance; | |
// Mon constructeur |
This file contains 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
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Text; | |
using IndustrialCodeBox.APIConnector; | |
using IndustrialCodeBox.APIConnector.Interfaces; | |
using System.Data; | |
using System.Collections.Specialized; | |
using System.Windows.Forms; |
This file contains 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
#!/usr/bin/ruby | |
require 'rss/1.0' | |
require 'rss/2.0' | |
require 'open-uri' | |
require 'rss/maker' | |
source = "rss_voiture.xhtml" # url or local file | |
#source = "http://alerte-leboncoin.ilatumi.org/feed/rss?link=http%3A%2F%2Fwww.leboncoin.fr%2Fvoitures%2Foffres%2Fpays_de_la_loire%2F%3Ff%3Da%26th%3D1" | |
content = "" # raw content of rss feed will be loaded here |
This file contains 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
//Add several columns on a table | |
alter table tfa_data add column TEMP1 float; | |
alter table tfa_data add column TEMP2 float; | |
alter table tfa_data add column TEMP3 float; | |
// Update columns with randoms float (20 to 40) | |
update tfa_data |
This file contains 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
<?php | |
$var = 'niii'; | |
// Quote simple | |
$query = 'SELECT password from users where login = "' . $var . '"'; | |
echo $query; | |
// Exemples disponibles sur siteduzero.com |
This file contains 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
\documentclass[a4paper,11pt]{report} | |
\usepackage[french]{babel} | |
\usepackage[T1]{fontenc} | |
\usepackage[utf8]{inputenc} | |
\usepackage{lmodern} | |
\usepackage{microtype} | |
\usepackage{hyperref} |
This file contains 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
mickael@mickael-laptop:~/projects/pabd/test (master*!) 14:40:08 | |
2040/93 > ruby unit/validation_state_test.rb | |
Loaded suite unit/validation_state_test | |
Started | |
......... | |
Finished in 1.42106 seconds. | |
9 tests, 9 assertions, 0 failures, 0 errors |
This file contains 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
>> a = User.find(2) | |
=> #<User id: 2, email: "[email protected]", crypted_password: "ef0e221eed190211d5f3c5e74c82da3ac24a5a5a0ac18027a7a...", password_salt: "eetQTWZfnLG7KZmKfaH", persistence_token: "706a2857e2e4c6e80eec3ed0b779fe3c755b4b7446f3d1aa482...", created_at: "2010-09-07 15:23:00", updated_at: "2010-09-07 15:34:22", role: "poweruser", failed_login_count: 0> | |
# Test validate avec save callback | |
>> a.agencies | |
=> [#<Agency id: 19, name: "Nord", division_id: 1, created_at: "2010-09-07 15:22:00", updated_at: "2010-09-07 15:22:00", parent_id: nil>, #<Agency id: 1, name: "Nord-Ouest", division_id: 1, created_at: "2010-09-07 15:21:58", updated_at: "2010-09-07 15:21:58", parent_id: nil>] | |
>> a.valid? | |
=> true | |
>> a.agencies = [] | |
=> [] |
This file contains 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
# Filters added to this controller apply to all controllers in the application. | |
# Likewise, all the methods added will be available for all controllers. | |
class ApplicationController < ActionController::Base | |
helper :all # include all helpers, all the time | |
protect_from_forgery # See ActionController::RequestForgeryProtection for details | |
before_filter :set_locale | |
# Scrub sensitive parameters from your log | |
filter_parameter_logging :password, :password_confirmation |
NewerOlder