
readfile("./lv/info.txt"); ?> |

readfile("./lv/aug.txt"); ?> |

readfile("./lv/prog.txt"); ?> |

|
Nodibinajums "Augstakās izglītības kvalitātes novērtēšanas centrs" (AIKNC)
Juridiskā un pasta adrese: Vaļņu iela 2, LV-1050, Rīga
Biroja adrese: Meistaru iela 10/12 - 311. kab.
E-pasts: aiknc@aiknc.lv
Tālrunis: 7213870
Fakss: 7212558
Rēķins: LV05PARX0000275971014, Parekss Banka, PARXLV22
PVN reģ. nr. LV50003239391
|
|
|
J A U N U M I (vienlaicīgi tiek rādīti tikai 5 jaunumi):
|
function getmaxidm()
{
return ((date("Y")-1996)*12)-6+date("m");
}
function fdatums($val)
{
setlocale(LC_TIME, "lv_LV");
$arr = explode("-", $val);
return date("d. m. Y.", mktime(0,0,0, $arr[1], $arr[2], $arr[0]));
}
require_once("./lv/mysql.inc");
if (!isset($_GET["idm"])) { $idm=false; }
else {
if (strlen($_GET["idm"])>0) { $idm=irint($_GET["idm"]); }
else { $idm=false; }
}
if (!isset($_GET["id"])) { $id=false; }
else {
if (strlen($_GET["id"])>0) { $id=irint($_GET["id"]); }
else { $id=false; }
}
$lastid = mysql_query("select id from news order by id desc limit 1") or
die ("Pieprasījums id nedarbojas.");
$rezid = mysql_fetch_array($lastid);
if ($id)
{
$piepras = "SELECT id, datums, title, news FROM news where id<=$id ORDER BY datums DESC";
$rezult = mysql_query($piepras) or die ("Pieprasījums nedarbojas.");
}
else
{
$piepras = "SELECT id, datums, title, news FROM news ORDER BY datums DESC";
$rezult = mysql_query($piepras) or die ("Pieprasījums nedarbojas.");
}
echo "";
if (mysql_num_rows($rezult)>5)
{
if (($rezid[0]-5)>=0 and $id)
{
$nextid=$id-5;
echo " Iepriekšējie 5 jaunumi ";
}
else
{
$nextid=$rezid[0]-5;
echo " Iepriekšējie 5 jaunumi ";
}
}
else
{
echo " Iepriekšējie 5 jaunumi ";
}
echo " - Sākums - ";
if ($id and ($nextid+5<=$rezid[0]))
{
if (($nextid+6>$rezid[0])==false)
{
$nextid = $id + 5;
echo " Nākamie 5 jaunumi ";
}
else
{
echo " Nākamie 5 jaunumi ";
}
}
echo " | \n";
$counter=1;
if (mysql_num_rows($rezult) > 0)
{
while($a = mysql_fetch_array($rezult) and $counter<=5)
{
$counter++;
if ($a["title"])
{
echo "";
$dat = fdatums($a["datums"]);
echo $dat;
echo " ";
echo $a["title"];
echo " | \n";
$out = $a["news"];
$mainiits = false;
if (strlen($out) > 80)
{
$st = substr($out,0,80);
if ($no=strpos($st, "<") and strpos($st, ">")==false)
{
$st = substr($st, 0, $no);
}
$garums = strrpos($st, " ");
$out = substr($st, 0, $garums);
$mainiits = true;
}
echo "\n";
echo $out;
if ($mainiits)
{
echo "... turpināt lasīt";
}
echo "\n";
}
}
}
else
{
echo " | Jaunumu nav | \n";
}
if ($idm==false)
{
$piepr = mysql_query("select prog.akr_no, prog.nosaukums, augstsk.title, prog.id,
prog.pieder, if(prog.mainita=0,if((((year(prog.akr_lidz))-(year(prog.akr_no)))>3),'uz 6 gadiem',
'uz 2 gadiem'),'mainīta') as term from prog, augstsk where augstsk.id=prog.pieder and
(prog.akr_no>=date_sub(current_date, interval 3 month)) order by prog.akr_no desc") or
die ("Pieprasījums mēn. prog. nedarbojas.");
$mainiits=false;
echo "";
echo "Pēdējo 3 mēnešu laikā akreditētās programmas (tiek rādītas tikai 3 mēnešu
laikā akreditētās programmas ): | \n";
echo "";
echo " Iepriekšējie 3 mēneši ";
echo " - Sākums - ";
echo " Nākamie 3 mēneši | \n";
echo "\n";
while ($rezult=mysql_fetch_array($piepr))
{
$mainiits=true;
$dat=fdatums($rezult[0]);
echo " | $dat $rezult[term] -
$rezult[1] - $rezult[2] | \n";
}
if ($mainiits==false)
{
echo "Pēdējo 3 mēnešu laikā neviena programma nav akreditēta.\n";
}
if ($mainiits)
{
echo "\n";
}
}
else
{
$idm=irint($idm);
$piepr = mysql_query("select prog.akr_no, prog.nosaukums, augstsk.title, prog.id,
prog.pieder, if((((year(prog.akr_lidz))-(year(prog.akr_no)))>3),'uz 6 gadiem','uz 2 gadiem')
as term from prog, augstsk where augstsk.id=prog.pieder and
(prog.akr_no>date_sub(current_date, interval $idm month)) and
(prog.akr_no<=date_sub(current_date, interval $idm-3 month)) order by prog.akr_no desc")
or die ("Pieprasījums mēn. prog. nedarbojas.");
$mainiits=false;
echo "";
echo "Programmu akreditācijas vēsture (tiek rādītas tikai 3 mēnešu laikā akreditētās
programmas): | \n";
echo "";
if ($idm Iepriekšējie 3 mēneši ";
}
else
{
echo " Iepriekšējie 3 mēneši ";
}
echo " - Sākums - ";
if ($idm<=6)
{
echo " Nākamie 3 mēneši ";
}
if ($idm>6)
{
$nextidm=$idm-3;
echo " Nākamie 3 mēneši ";
}
echo "\n";
if (mysql_num_rows($piepr)==0)
{
echo " | Šajos mēnešos neviena programma nav akreditēta. | \n";
}
while ($rezult=mysql_fetch_array($piepr))
{
$mainiits=true;
$dat=fdatums($rezult[0]);
echo "$dat $rezult[term] -
$rezult[1] - $rezult[2] | \n";
}
}
mysql_close($link);
?>
|
|