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
#!/usr/bin/python | |
# -*- coding: utf-8 -*- | |
import MySQLdb as mdb | |
import MySQLdb.cursors | |
class dbDevConfiguration: | |
host = "localhost" |
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
# import csv | |
def readCsv(path): | |
csvfile = open(path,'rb') | |
reader = csv.reader(csvfile) | |
# salto la prima riga | |
#reader.next() | |
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
import yaml | |
import re | |
import os | |
# definire il path rispetto allo script | |
dbPath = os.path.dirname(os.path.realpath(__file__)) + '/../config/databases.yml' | |
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
<div class="accordion" id="accordion2"> | |
<div class="accordion-group"> | |
<div class="accordion-heading"> | |
<a class="accordion-toggle" data-toggle="collapse" data-parent="#accordion2" href="#collapse1"> | |
LABEL 1 | |
</a> | |
</div> | |
<div id="collapse1" class="accordion-body collapse in"> | |
<div class="accordion-inner"> | |
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
<div class="container"> | |
<div class="navbar"> | |
<div class="navbar-inner"> | |
<a class="brand" href="#">GE.CO.</a> | |
<ul class="nav"> | |
<li class="active"><a href="#">Gestione Pagine</a></li> | |
<li><a href="#">Utenti</a></li> | |
<li><a href="#">Gestione Sito</a></li> | |
<li><a href="#">Catalogo</a></li> | |
<li><a href="#">Area Riservata</a></li> |
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
jQuery(function() | |
{ | |
jQuery('body').on('hidden', '.modal', function () { | |
jQuery(this).removeData('modal'); | |
}); | |
} |
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
$('.typeahead').typeahead({ | |
source: function (query, process) { | |
return $.get('/typeahead', { query: query }, function (data) { | |
return process(data.options); | |
}); | |
} | |
}); |
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
jQuery.ajax('http://url.com',{ | |
dataType: 'html', | |
data: jQuery('#mainform').serialize(),// or array { data1 : 'value1',... } | |
success: function(data,textStatus,jqXHR) | |
{ | |
jQuery('#container_to_update').html(data); | |
}, | |
error: function (jqXHR,textStatus,errorThrown) | |
{ | |
jQuery('#message_container').html('Si e\' verificato un errore...'); |
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
$sql = "[INSERT QUERY HERE]"; | |
$stmt = Propel::getConnection()->prepare($sql); | |
$stmt->execute(); | |
$res = $stmt->fetchAll(PDO::FETCH_BOTH); | |
foreach($res as $row) | |
{ | |
// ... $pippo = $row['column_name'] | |
// o |
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
<ul class="nav nav-tabs" id="myTab"> | |
<li class="active"><a href="#home">Home</a></li> | |
<li><a href="#profile">Profile</a></li> | |
<li><a href="#messages">Messages</a></li> | |
</ul> | |
<div class="tab-content"> | |
<div class="tab-pane active" id="home">...</div> | |
<div class="tab-pane" id="profile">...</div> |
OlderNewer