/[health_html]/inc/pgLifestyle.php
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Diff of /inc/pgLifestyle.php

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.8 by ravilov, Fri Sep 28 23:34:37 2001 UTC revision 1.9 by ravilov, Tue Oct 2 16:18:09 2001 UTC
# Line 9  Line 9 
9                          if ($del_id) {                          if ($del_id) {
10                                  include_once("inc/newsDelete.php");                                  include_once("inc/newsDelete.php");
11                                  newsDelete($del_id);                                  newsDelete($del_id);
12                                  unset($top_edit, $wn_edit, $pn_edit);                                  unset($top_edit);
13                          }                          }
14                          if ($down_id) $dbh->dbh_do("UPDATE news SET ord = ord + 1 WHERE (news_id = $down_id)");                          if ($down_id) $dbh->dbh_do("UPDATE news SET ord = ord + 1 WHERE (news_id = $down_id)");
15                          if ($up_id) $dbh->dbh_do("UPDATE news SET ord = ord - 1 WHERE (news_id = $up_id)");                          if ($up_id) $dbh->dbh_do("UPDATE news SET ord = ord - 1 WHERE (news_id = $up_id)");
# Line 40  Line 40 
40                          if ($section_menu2 == "vjezbe") $cat = "u";                          if ($section_menu2 == "vjezbe") $cat = "u";
41                          # if ($section_menu2 == "fitcenter") $cat = "k";                          # if ($section_menu2 == "fitcenter") $cat = "k";
42                  }                  }
43                    if ($cat == "x") {
44                            $empty = array("category" => "y", "limit" => 1, "offset" => 0, "npar" => 0);
45                            include_once("inc/newsShow.php");
46                            $art = newsLoad(-1, $empty["category"], $empty["limit"], $empty["offset"], $empty["npar"]);
47                            $art = array_shift($art);
48                            $ed = "";
49                            if ($kol_edit && ($art["id"] == $ed_id || $ed_id <= 0) && $isEdit) {
50                                    include_once("inc/newsEdit.php");
51                                    $ed = newsEdit(($ed_id > 0) ? $art : $empty, "kol_edit");
52                            }
53                            if ($ed && is_string($ed)) $tpl->assign("KOL_EDIT", $ed);
54                            else {
55                                    if ($ed && $ed["category"] == "y") $art = $ed;
56                                    $tpl->assign("kol_id", $art["id"]);
57                                    $tpl->assign("kol_title", MyEscape($art["title"]));
58                                    $tpl->assign("kol_lead", MyEscape($art["lead"]));
59                                    $tpl->assign("kol_pgfs", (count($art["text"]) > 0) ? true : false);
60                                    $tpl->assign("kol_titlepic_url", MyEscape($art["pic_url"]));
61                                    $tpl->assign("kol_titlepic_alt", MyEscape($art["pic_alt"]));
62                                    $tpl->assign("kol_titlepic_type", $art["pic_pos"]);
63                                    $tpl->assign("kol_titlepic_width", $art["pic_w"]);
64                                    $tpl->assign("kol_titlepic_height", $art["pic_h"]);
65                                    for ($j = 0; $j < count($art["text"]); $j++)
66                                            $art["text"][$j]["text"] = ParseNewline(MyEscape($art["text"][$j]["text"]), true);
67                                    $tpl->assign("kol_text", $art["text"]);
68                                    include_once("inc/author.php");
69                                    $tpl->assign("AUTHOR", GetAuthor($art["au_pic"],
70                                            $art["au_alt"], $art["au_info"],
71                                            $art["au_w"], $art["au_h"]));
72                                    $tpl->assign("kol_links", GetLinks($art["read"] && $art["id"],
73                                            /* MyEscape($art["more"]) */ (count($art["text"]) > 0 && $art["id"]) ? $art["more"] : "",
74                                            MyEscape($art["more_title"]), $art["id"], $empty["category"],
75                                            "kol", $isEdit, false, false, false));
76                                    $tpl->assign("kol_read", $art["read"] || ($art["more"] && !strstr($art["more"], "?")) ? true : false);
77                            }
78                    }
79                  if (!$offset) $offset = 0;                  if (!$offset) $offset = 0;
80                  $empty = array("category" => $cat, "limit" => 11, "offset" => $offset, "npar" => 0);                  $empty = array("category" => $cat, "limit" => 11, "offset" => $offset, "npar" => 0);
81                  if ($top_edit && $ed_id <= 0 && $isEdit) {                  if ($top_edit && $ed_id <= 0 && $isEdit) {
# Line 78  Line 114 
114                                          "links" => GetLinks($art["read"] && $art["id"],                                          "links" => GetLinks($art["read"] && $art["id"],
115                                                  /* MyEscape($art["more"]) */ ((count($art["text"]) > 0 || strstr("?", $art["more"]) == 0) && $art["id"]) ? $art["more"] : "",                                                  /* MyEscape($art["more"]) */ ((count($art["text"]) > 0 || strstr("?", $art["more"]) == 0) && $art["id"]) ? $art["more"] : "",
116                                                  MyEscape($art["more_title"]), $art["id"], $empty["category"], "top",                                                  MyEscape($art["more_title"]), $art["id"], $empty["category"], "top",
117                                                  $isEdit, true, ($i > 0), ($i < count($arts) - 1))                                                  $isEdit, true, ($i > 0), ($i < count($arts) - 1)),
118                                            "read" => $art["read"] || ($art["more"] && !strstr($art["more"], "?")) ? true : false
119                                  ));                                  ));
120                          }                          }
121                  }                  }

Legend:
Removed from v.1.8  
changed lines
  Added in v.1.9

  ViewVC Help
Powered by ViewVC 1.1.26