Spausdinti
Biudžetinė įstaiga
Vilniaus g. 13, LT-98112 Skuodas
El. paštas savivaldybe@skuodas.lt
Tel. 8 440 73932; Faks. 8 440 73984
Duomenys kaupiami ir saugomi
Juridinių asmenų registre,
kodas 188751834
Į pradžią
  Gyventojams   Verslininkams   Turistams
Prisijungimas vartotojams
Prisijungimas gyventojams
Tarybos komisijos

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 






Paskutinis atnaujinimas: 2019-05-23 15:41:49
MERAS
PETRAS PUŠINSKAS
Aktuali informacija
Naujienų prenumerata
Dienos
Mėnesio
Pagrindinė grupė
Savaitės

 

       
       
Pradžia Kontaktai Teisės aktai Forumas Padaryti pirmuoju Pasižymėti svetainę RSS

Informacijos talpinimas svetainėje: tomas.ubartas@skuodas.lt

© 2011 Skuodo rajono savivaldybė. Cituojant šios svetainės informaciją prašome nurodyti šaltinį ir datą.
Reklaminio pobūdžio skebimai visose skuodas.lt el. pašto dėžutėse yra nepageidaujami.
Sprendimas:
Idamas, Naudojama: Smatweb sistema.

x502sS($qry); $res_count = $db->Count($sites); for($c=0;$c<$res_count;$c++) { list($module_id) = $db->GetRowAsList($res); } $qry ="SELECT site_name FROM `sites`"; $res = $db->x502sS($qry); $res_count = $db->Count($res); for($c=0;$c<$res_count;$c++) { list($site_name) = $db->GetRowAsList($res); $qry ="SELECT * FROM `site_".$site_name."_modules` WHERE module_id=$module_id"; $result = $db->x502sS($qry); $result_count = $db->Count($result); if ($result_count>0){ if (file_exists($site_name."/system/config.php")){ include_once($site_name."/system/config.php"); global $pnconfig; $config = GetConfigFile("m_send_news",$site_name); if (isset($config['_c_send_fill_archive']) && $config['_c_send_fill_archive']==1){ foreach ($pnconfig['_t1659'] as $key => $val){ $qry ="SELECT category_id FROM `global_categories` WHERE is_archive='1' AND category_language='$val' AND category_module='".$site_name."_m_send_news'"; $result = $db->x502sS($qry); $number = $db->Count($result); if ($number==0){ if (file_exists($site_name."/m/m_send_news/lang/".$val."/".$val.".php")){ include_once($site_name."/m/m_send_news/lang/".$val."/".$val.".php"); } $qry = "INSERT INTO global_categories (category_name, category_language, category_status, category_module, is_archive) VALUES" . "('".( (text('_m_send_news_archive')!='') ? text('_m_send_news_archive') : "Archyvas*")."', '$val', 0, '".$site_name."_m_send_news', 1 ) "; $result = $db->x502sS($qry); $archive_id=$db->GetInsertedId(); } else{ for($i=0;$i<$number;$i++) { list($archive_id) = $db->GetRowAsList($result); } } $qry="SELECT n_user_id FROM ".$site_name."_m_send_news_users_cat WHERE n_cat_id=$archive_id "; $result = $db->x502sS($qry); $result_count = $db->Count($result); if ( $result_count>0 ){ $not_in=""; $not_in = "AND C.n_user_id NOT IN ("; for($c=0;$c<$result_count;$c++) { list($n_user_id) = $db->GetRowAsList($result); $not_in.=" $n_user_id,"; } $not_in = substr($not_in,0,strlen($not_in)-1); $not_in .=" )"; } $qry = "SELECT DISTINCT(C.n_user_id) FROM global_categories A LEFT OUTER JOIN ".$site_name."_m_send_news_users_cat B ON A.category_id = B.n_cat_id LEFT JOIN ".$site_name."_m_send_news_user_info C ON C.n_user_id = B.n_user_id WHERE A.category_language = '$val' AND A.is_archive <> 1 AND A.category_module = '".$site_name."_m_send_news' AND B.date_to <'".date('Y-m-d')."' AND B.date_to <>'1111-11-11' $not_in ORDER BY A.category_name ASC "; $results = $db->x502sS($qry); $result_counts = $db->Count($results); for($i=0;$i<$result_counts;$i++) { list($n_user_id) = $db->GetRowAsList($results); $qry="INSERT INTO ".$site_name."_m_send_news_users_cat (n_cat_id, n_user_id, date_from, date_to) VALUES ('$archive_id','$n_user_id','".date('Y-m-d')."','1111-11-11')"; $db->x502sS($qry); } } $qry = "DELETE FROM ".$site_name."_m_send_news_users_cat WHERE date_to < now() and date_to != '1111-11-11' and date_to IS NOT NULL"; $db->x502sS($qry); } } } } ?>x502sS($qry); $res_count = $db->Count($sites); for($c=0;$c<$res_count;$c++) { list($module_id) = $db->GetRowAsList($res); } $qry ="SELECT site_name FROM `sites`"; $res = $db->x502sS($qry); $res_count = $db->Count($res); for($c=0;$c<$res_count;$c++) { list($site_name) = $db->GetRowAsList($res); $qry ="SELECT * FROM `site_".$site_name."_modules` WHERE module_id=$module_id"; $result = $db->x502sS($qry); $result_count = $db->Count($result); if ($result_count>0){ if (file_exists($site_name."/system/config.php")){ include_once($site_name."/system/config.php"); global $pnconfig; $config = GetConfigFile("m_send_news",$site_name); if (isset($config['_c_send_fill_archive']) && $config['_c_send_fill_archive']==1){ foreach ($pnconfig['_t1659'] as $key => $val){ $qry ="SELECT category_id FROM `global_categories` WHERE is_archive='1' AND category_language='$val' AND category_module='".$site_name."_m_send_news'"; $result = $db->x502sS($qry); $number = $db->Count($result); if ($number==0){ if (file_exists($site_name."/m/m_send_news/lang/".$val."/".$val.".php")){ include_once($site_name."/m/m_send_news/lang/".$val."/".$val.".php"); } $qry = "INSERT INTO global_categories (category_name, category_language, category_status, category_module, is_archive) VALUES" . "('".( (text('_m_send_news_archive')!='') ? text('_m_send_news_archive') : "Archyvas*")."', '$val', 0, '".$site_name."_m_send_news', 1 ) "; $result = $db->x502sS($qry); $archive_id=$db->GetInsertedId(); } else{ for($i=0;$i<$number;$i++) { list($archive_id) = $db->GetRowAsList($result); } } $qry="SELECT n_user_id FROM ".$site_name."_m_send_news_users_cat WHERE n_cat_id=$archive_id "; $result = $db->x502sS($qry); $result_count = $db->Count($result); if ( $result_count>0 ){ $not_in=""; $not_in = "AND C.n_user_id NOT IN ("; for($c=0;$c<$result_count;$c++) { list($n_user_id) = $db->GetRowAsList($result); $not_in.=" $n_user_id,"; } $not_in = substr($not_in,0,strlen($not_in)-1); $not_in .=" )"; } $qry = "SELECT DISTINCT(C.n_user_id) FROM global_categories A LEFT OUTER JOIN ".$site_name."_m_send_news_users_cat B ON A.category_id = B.n_cat_id LEFT JOIN ".$site_name."_m_send_news_user_info C ON C.n_user_id = B.n_user_id WHERE A.category_language = '$val' AND A.is_archive <> 1 AND A.category_module = '".$site_name."_m_send_news' AND B.date_to <'".date('Y-m-d')."' AND B.date_to <>'1111-11-11' $not_in ORDER BY A.category_name ASC "; $results = $db->x502sS($qry); $result_counts = $db->Count($results); for($i=0;$i<$result_counts;$i++) { list($n_user_id) = $db->GetRowAsList($results); $qry="INSERT INTO ".$site_name."_m_send_news_users_cat (n_cat_id, n_user_id, date_from, date_to) VALUES ('$archive_id','$n_user_id','".date('Y-m-d')."','1111-11-11')"; $db->x502sS($qry); } } $qry = "DELETE FROM ".$site_name."_m_send_news_users_cat WHERE date_to < now() and date_to != '1111-11-11' and date_to IS NOT NULL"; $db->x502sS($qry); } } } } ?>