=0) { if ($pageNum_Recordset1 > ceil($max_links/2)) { $fgp = $pageNum_Recordset1 - ceil($max_links/2) > 0 ? $pageNum_Recordset1 - ceil($max_links/2) : 1; $egp = $pageNum_Recordset1 + ceil($max_links/2); if ($egp >= $totalPages_Recordset1) { $egp = $totalPages_Recordset1+1; $fgp = $totalPages_Recordset1 - ($max_links-1) > 0 ? $totalPages_Recordset1 - ($max_links-1) : 1; } } else { $fgp = 0; $egp = $totalPages_Recordset1 >= $max_links ? $max_links : $totalPages_Recordset1+1; } if($totalPages_Recordset1 >= 1) { $_get_vars = ''; if(!empty($_GET) || !empty($HTTP_GET_VARS)){ $_GET = empty($_GET) ? $HTTP_GET_VARS : $_GET; foreach ($_GET as $_get_name => $_get_value) { if ($_get_name != "pageNum_news") { $_get_vars .= "&$_get_name=$_get_value"; } } } $successivo = $pageNum_Recordset1+1; $precedente = $pageNum_Recordset1-1; $firstArray = ($pageNum_Recordset1 > 0) ? "$prev_Recordset1" : "$prev_Recordset1"; for($a = $fgp+1; $a <= $egp; $a++){ $theNext = $a-1; if($show_page) { $textLink = $a; } else { $min_l = (($a-1)*$maxRows_news) + 1; $max_l = ($a*$maxRows_news >= $totalRows_news) ? $totalRows_news : ($a*$maxRows_news); $textLink = "$min_l - $max_l"; } $_ss_k = floor($theNext/26); if ($theNext != $pageNum_Recordset1) { $pagesArray .= ""; $pagesArray .= "$textLink" . ($theNext < $egp-1 ? $separator : ""); } else { $pagesArray .= "$textLink" . ($theNext < $egp-1 ? $separator : ""); } } $theNext = $pageNum_Recordset1+1; $offset_end = $totalPages_Recordset1; $lastArray = ($pageNum_Recordset1 < $totalPages_Recordset1) ? "$next_Recordset1" : "$next_Recordset1"; } } return array($firstArray,$pagesArray,$lastArray); } ?> addField("email", true, "text", "email", "", "", "Inserire un indirizzo email valido!"); $formValidation->addField("privacy", true, "", "", "", "", "Per proseguire è necessario accettare la normativa di legge vigente in materia di privacy!"); $tNGs->prepareValidation($formValidation); // End trigger if (!function_exists("GetSQLValueString")) { function GetSQLValueString($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "") { if (PHP_VERSION < 6) { $theValue = get_magic_quotes_gpc() ? stripslashes($theValue) : $theValue; } $theValue = function_exists("mysql_real_escape_string") ? mysql_real_escape_string($theValue) : mysql_escape_string($theValue); switch ($theType) { case "text": $theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL"; break; case "long": case "int": $theValue = ($theValue != "") ? intval($theValue) : "NULL"; break; case "double": $theValue = ($theValue != "") ? doubleval($theValue) : "NULL"; break; case "date": $theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL"; break; case "defined": $theValue = ($theValue != "") ? $theDefinedValue : $theNotDefinedValue; break; } return $theValue; } } $maxRows_categorie = 5; $pageNum_categorie = 0; if (isset($_GET['pageNum_categorie'])) { $pageNum_categorie = $_GET['pageNum_categorie']; } $startRow_categorie = $pageNum_categorie * $maxRows_categorie; mysql_select_db($database_domuscoop, $domuscoop); $query_categorie = "SELECT * FROM domuscoop_cat ORDER BY ordinamento ASC"; $query_limit_categorie = sprintf("%s LIMIT %d, %d", $query_categorie, $startRow_categorie, $maxRows_categorie); $categorie = mysql_query($query_limit_categorie, $domuscoop) or die(mysql_error()); $row_categorie = mysql_fetch_assoc($categorie); if (isset($_GET['totalRows_categorie'])) { $totalRows_categorie = $_GET['totalRows_categorie']; } else { $all_categorie = mysql_query($query_categorie); $totalRows_categorie = mysql_num_rows($all_categorie); } $totalPages_categorie = ceil($totalRows_categorie/$maxRows_categorie)-1; $colname_sottocategorie = "-1"; if (isset($_GET['cat'])) { $colname_sottocategorie = (get_magic_quotes_gpc()) ? $_GET['cat'] : addslashes($_GET['cat']); } mysql_select_db($database_domuscoop, $domuscoop); $query_sottocategorie = sprintf("SELECT * FROM domuscoop_subcat WHERE id_rel = %s ORDER BY ordinamento ASC", GetSQLValueString($colname_sottocategorie, "int")); $sottocategorie = mysql_query($query_sottocategorie, $domuscoop) or die(mysql_error()); $row_sottocategorie = mysql_fetch_assoc($sottocategorie); $totalRows_sottocategorie = mysql_num_rows($sottocategorie); mysql_select_db($database_domuscoop, $domuscoop); $query_subcat_1 = "SELECT id FROM domuscoop_subcat WHERE id_rel = 1 LIMIT 1"; $subcat_1 = mysql_query($query_subcat_1, $domuscoop) or die(mysql_error()); $row_subcat_1 = mysql_fetch_assoc($subcat_1); $totalRows_subcat_1 = mysql_num_rows($subcat_1); mysql_select_db($database_domuscoop, $domuscoop); $query_subcat_2 = "SELECT id FROM domuscoop_subcat WHERE id_rel = 2 LIMIT 1"; $subcat_2 = mysql_query($query_subcat_2, $domuscoop) or die(mysql_error()); $row_subcat_2 = mysql_fetch_assoc($subcat_2); $totalRows_subcat_2 = mysql_num_rows($subcat_2); mysql_select_db($database_domuscoop, $domuscoop); $query_subcat_3 = "SELECT id FROM domuscoop_subcat WHERE id_rel = 3 LIMIT 1"; $subcat_3 = mysql_query($query_subcat_3, $domuscoop) or die(mysql_error()); $row_subcat_3 = mysql_fetch_assoc($subcat_3); $totalRows_subcat_3 = mysql_num_rows($subcat_3); mysql_select_db($database_domuscoop, $domuscoop); $query_subcat_4 = "SELECT id FROM domuscoop_subcat WHERE id_rel = 4 LIMIT 1"; $subcat_4 = mysql_query($query_subcat_4, $domuscoop) or die(mysql_error()); $row_subcat_4 = mysql_fetch_assoc($subcat_4); $totalRows_subcat_4 = mysql_num_rows($subcat_4); mysql_select_db($database_domuscoop, $domuscoop); $query_subcat_5 = "SELECT id FROM domuscoop_subcat WHERE id_rel = 5 LIMIT 1"; $subcat_5 = mysql_query($query_subcat_5, $domuscoop) or die(mysql_error()); $row_subcat_5 = mysql_fetch_assoc($subcat_5); $totalRows_subcat_5 = mysql_num_rows($subcat_5); mysql_select_db($database_domuscoop, $domuscoop); $query_sub_index = "SELECT * FROM domuscoop_subcat WHERE id_rel = 6 ORDER BY ordinamento ASC"; $sub_index = mysql_query($query_sub_index, $domuscoop) or die(mysql_error()); $row_sub_index = mysql_fetch_assoc($sub_index); $totalRows_sub_index = mysql_num_rows($sub_index); $maxRows_news = 2; $pageNum_news = 0; if (isset($_GET['pageNum_news'])) { $pageNum_news = $_GET['pageNum_news']; } $startRow_news = $pageNum_news * $maxRows_news; mysql_select_db($database_domuscoop, $domuscoop); $query_news = "SELECT * FROM domuscoop_news ORDER BY `data` DESC"; $query_limit_news = sprintf("%s LIMIT %d, %d", $query_news, $startRow_news, $maxRows_news); $news = mysql_query($query_limit_news, $domuscoop) or die(mysql_error()); $row_news = mysql_fetch_assoc($news); if (isset($_GET['totalRows_news'])) { $totalRows_news = $_GET['totalRows_news']; } else { $all_news = mysql_query($query_news); $totalRows_news = mysql_num_rows($all_news); } $totalPages_news = ceil($totalRows_news/$maxRows_news)-1; // Make an insert transaction instance $ins_domuscoop_newsletter = new tNG_insert($conn_domuscoop); $tNGs->addTransaction($ins_domuscoop_newsletter); // Register triggers $ins_domuscoop_newsletter->registerTrigger("STARTER", "Trigger_Default_Starter", 1, "POST", "KT_Insert1"); $ins_domuscoop_newsletter->registerTrigger("BEFORE", "Trigger_Default_FormValidation", 10, $formValidation); $ins_domuscoop_newsletter->registerTrigger("END", "Trigger_Default_Redirect", 99, "newsletter_ok.php"); // Add columns $ins_domuscoop_newsletter->setTable("domuscoop_newsletter"); $ins_domuscoop_newsletter->addColumn("email", "STRING_TYPE", "POST", "email"); $ins_domuscoop_newsletter->addColumn("privacy", "CHECKBOX_1_0_TYPE", "POST", "privacy", "0"); $ins_domuscoop_newsletter->setPrimaryKey("id", "NUMERIC_TYPE"); // Execute all the registered transactions $tNGs->executeTransactions(); // Get the transaction recordset $rsdomuscoop_newsletter = $tNGs->getRecordset("domuscoop_newsletter"); $row_rsdomuscoop_newsletter = mysql_fetch_assoc($rsdomuscoop_newsletter); $totalRows_rsdomuscoop_newsletter = mysql_num_rows($rsdomuscoop_newsletter); ?> DomusCoop | Beta

Iscrizione Newsletter

Il servizio newsletter offre la possibilità di ricevere periodicamente una e-mail contenente novità e informazioni relative alle iniziative della Domus Coop e delle realtà ad essa collegate.
Per iscriversi inserire il proprio indirizzo e-mail, nome, cognome e indirizzo postale. Al termine è sufficiente premere il pulsante "Iscriviti" e si verrà inseriti nella mailing list.


Acconsento al trattamento dei dati personali
ai sensi dell'art.13 del D. Lgs. 196/2003
type="checkbox" id="privacy_checkbox" name="privacy" value="1" required="required" />