- Timestamp:
- Jan 14, 2009, 7:38:30 PM (16 years ago)
- Location:
- devel/web
- Files:
-
- 68 added
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
devel/web
- Property svn:ignore
-
old new 4 4 backup 5 5 6 index 6 index.cgi 7 8 index.compiled
-
- Property svn:ignore
-
devel/web/UCore.pas
r135 r137 19 19 function HumanDate(Date: string): string; 20 20 procedure RegisterPage(Name: string; Producer: TPageProducer); 21 function PagesList(URL: string; Page, TotalCount, CountPerPage: Integer): string; 22 function StrRepeat(Data: string; Count: Integer): string; 23 function FormatOutput(Data: string): string; 21 24 22 25 type … … 52 55 begin 53 56 Navigace := CgiEnvVar.RequestURI; 54 Result := '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">' + 55 '<html><head>' + 56 ' <meta http-equiv="Content-Language" content="cs">' + 57 ' <meta http-equiv="Content-Type" content="text/html; charset=utf-8">' + 57 Result := '<?xml version="1.0" encoding="utf-8"?>' + 58 '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">' + 59 '<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">' + 60 '<head>' + 61 ' <meta http-equiv="Content-Language" content="cs" />' + 62 ' <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />' + 63 ' <link rel="stylesheet" href="style/style.css" type="text/css" media="all" />' + 64 ' <script type="text/javascript" src="style/global.js"></script>' + 58 65 ' <title>Centrála - ' + Path + '</title>' + 59 ' </head><body style="font-family: sans-serif;">' +60 '<div style="padding: 3px; font-size: 20px; border-style: solid; border-color: blue; border-width: 1; background-color: #F0F0FF; margin-bottom: 4px;">' + Title + '</div>'+61 '<div style="border-style: solid; border-bottom-color: gray; border-width: 0 0 1 0; margin-bottom: 3px; padding-bottom: 2px;"><strong>Navigace >></strong> ' + Navigace + '</div>';66 ' </head><body>' + 67 '<div id="Title">' + Title + '</div>'+ 68 '<div class="Navigation"><strong>Navigace >></strong> ' + Navigace + '</div>'; 62 69 end; 63 70 … … 69 76 UpdateDate := '2.5.2007'; 70 77 GenerateTime := '1 s'; 71 Result := '<div style="border-style: solid; border-top-color: gray; border-width: 1 0 0 0; margin-top: 7px; padding-top: 2px;" align="center">'+ 72 ' <i style="font-size: 10;">| Web mistr: Jiří Hajda | e-mail: robie@centrum.cz | ICQ: 277158770 | Vygenerováno za ' + GenerateTime + ' s | Verze: 1.0 | Naposledy aktualizováno: ' + UpdateDate + ' |</i>'+ 73 ' </div>'; 78 Result := '<div id="Footer">| Web mistr: Jiří Hajda | e-mail: robie@centrum.cz | ICQ: 277158770 | Vygenerováno za ' + GenerateTime + ' s | Verze: 1.0 | Naposledy aktualizováno: ' + UpdateDate + ' |' + 79 '</div>'; 74 80 //ShowArray($GLOBALS); 75 81 Result := Result + '</body></html>'; … … 102 108 function InsertIcon(FileName: string): string; 103 109 begin 104 Result := '<img alt="" src=" /dev/centrala/www/images/favicons/' + FileName + '" width="16" height="16">';110 Result := '<img alt="" src="images/favicons/' + FileName + '" width="16" height="16" />'; 105 111 end; 106 112 … … 126 132 end; 127 133 134 function PagesList(URL: string; Page, TotalCount, CountPerPage: Integer): string; 135 const 136 Around: Integer = 10; 137 var 138 Count: Integer; 139 PagesMax: Integer; 140 PagesMin: Integer; 141 I: Integer; 142 begin 143 Count := Round(TotalCount / CountPerPage); 144 Result := ''; 145 if Count > 1 then begin 146 if Page > 0 then begin 147 Result := Result + '<a href="' + URL + '0"><<</a> '; 148 Result := Result + '<a href="' + URL + IntToStr(Page - 1) + '"><</a> '; 149 end; 150 PagesMax := Count - 1; 151 PagesMin := 0; 152 if PagesMax > (Page + Around) then PagesMax := Page + Around; 153 if PagesMin < (Page - Around) then begin 154 Result := Result + ' .. '; 155 PagesMin := Page - Around; 156 end; 157 for I := PagesMin to PagesMax do begin 158 if I = Page then Result := Result + '<strong>'; 159 Result := Result + '<a href="' + URL + IntToStr(I) + '">' + IntToStr(I + 1) + '</a> '; 160 if I = Page then Result := Result + '</strong>'; 161 end; 162 if PagesMax < (Count - 1) then Result := Result + ' .. '; 163 if Page < (Count - 1) then begin 164 Result := Result + '<a href="' + URL + IntToStr(Page + 1) + '">></a> '; 165 Result := Result + '<a href="' + URL + IntToStr(Count - 1) + '">>></a>'; 166 end; 167 end; 168 end; 169 170 function StrRepeat(Data: string; Count: Integer): string; 171 var 172 I: Integer; 173 begin 174 Result := ''; 175 for I := 1 to Count do 176 Result := Result + Data; 177 end; 178 179 function FormatOutput(Data: string): string; 180 var 181 BlockStart, BlockEnd: Integer; 182 Indention: Integer; 183 Indention2: Integer; 184 Line: string; 185 Command: string; 186 begin 187 Result := ''; 188 Indention := 0; 189 Indention2 := 0; 190 while Data <> '' do begin 191 //WebWrite('.'); 192 BlockStart := Pos('<', Data); 193 BlockEnd := Pos('>', Data); 194 if BlockStart > 1 then begin 195 BlockEnd := BlockStart - 1; 196 BlockStart := 1; 197 end; 198 Line := Trim(Copy(Data, BlockStart, BlockEnd)); 199 //WebWriteLn(Line); 200 if Length(Line) > 0 then 201 if Line[1] = '<' then begin 202 if Data[BlockStart + 1] = '/' then begin 203 Indention := Indention - 2; 204 Indention2 := Indention; 205 end else begin 206 if Pos(' ', Line) > 0 then Command := Copy(Line, 2, Pos(' ', Line) - 2) 207 else Command := Copy(Line, 2, Length(Line) - 2); 208 //WebWriteLn(Command + ' ' + IntToStr(Indention)); 209 if Pos('</' + Command + '>', Data) > 0 then Indention := Indention + 2; 210 //WebWriteLn(IntToStr(Indention) + ',' + IntToStr(Indention2)); 211 end; 212 end; 213 if Line <> '' then Result := Result + StrRepeat(' ', Indention2) + Line + #13#10; 214 Data := Copy(Data, BlockEnd + 1, Length(Data)); 215 Indention2 := Indention; 216 end; 217 end; 218 128 219 initialization 129 220 -
devel/web/UFinancePage.pas
r135 r137 15 15 begin 16 16 Result := ShowHeader('<strong>ZděchovNET</strong> - komunitní počítačová síť', 'Finance'); 17 Result := Result + '<table><tr><td valign="top"><table><tr><td width="30%">' +17 Result := Result + '<table><tr><td valign="top"><table><tr><td>' + 18 18 HtmlLink('Výpis zařízení', 'zarizeni.php') + '<br />' + 19 HtmlLink('Seznam členů', ' clenove.php') + '<br />' +19 HtmlLink('Seznam členů', '?p=finance-clenove') + '<br />' + 20 20 HtmlLink('Spotřeba energie', 'spotreba.php') + '<br />' + 21 21 HtmlLink('Investice v síti', '/aktuality/index.php?category=9') + '<br />' + … … 25 25 HtmlLink('Výpis skladových zásob', 'inventory.php') + '<br />' + 26 26 HtmlLink('Porovnání tarifů s konkurencí', 'srovnani.php') + '<br />' + 27 '</td><td width="50%"></td></tr></table><br /><strong>Souhrn:</strong><br />Aktuální měsíční poplatek za společný internet (10240/10240 kbit/s):' +27 '</td><td></td></tr></table><br /><strong>Souhrn:</strong><br />Aktuální měsíční poplatek za společný internet (10240/10240 kbit/s):' + 28 28 ' <strong>15351 Kč</strong><br />Počet členů (s internetem): <strong>79 (79)</strong><br />Celková cena zařízení sítě: <strong>106335 Kč</strong><br />Celkem peněz na účtech: <strong>' + 29 29 '-14537 Kč</strong><br />Stanovená cena jedné kWh: <strong>3 Kč</strong><br />V připojených domácnostech celkem <strong>273</strong>' + -
devel/web/UMainPage.pas
r134 r137 20 20 II: Integer; 21 21 Enclosures: TArrayOfString; 22 Content: string; 22 23 const 23 24 NewsCountPerCategory = 3; 24 UploadedFilesFolder = 'aktuality/uploads/'; 25 // UploadedFilesFolder = 'aktuality/uploads/'; 25 26 begin 26 27 // global $NewsCategoryNames, $NewsCountPerCategory, $UploadedFilesFolder; … … 28 29 DbRows := Database.Select('news_category', '*', 'id=' + IntToStr(Category)); 29 30 30 Result := '<table cellspacing="0" cellpadding="0" border="0" width="100%" style="font-size: small; padding-bottom: 5px;"><tr>'+ 31 '<td width="40%">' + DbRows[0].Values['caption'] + '</td><td width="80%" align="right">'+ 32 '<a href="aktuality/index.php?category=' + IntToStr(Category) + '">Zobrazit všechny aktuality</a> '; 33 if StrToInt(DbRows[0].Values['permission']) = 1 then Result := Result + '<a href="aktuality/index.php?action=add&category=' + IntToStr(Category) + '">Přidat aktualitu</a> '; 31 Result := '<table class="MainTable"><tr>' + 32 '<td>' + DbRows[0].Values['caption'] + '</td><td align="right">'+ 33 '<a href="?p=news-list&category=' + IntToStr(Category) + '">Zobrazit všechny aktuality</a> '; 34 if StrToInt(DbRows[0].Values['permission']) = 1 then 35 Result := Result + '<a href="aktuality/index.php?action=add&category=' + IntToStr(Category) + '">Přidat aktualitu</a> '; 34 36 Result := Result + '</td></tr><tr><td colspan="2">'+ 35 '<table cellspacing="0" width="100%" style="padding: 2px 2px 2px 2px; font-size: small; border-style: solid; border-color: red; border-width: 1; background-color: #FFF0F0;">';37 '<table>'; 36 38 Index := 0; 37 39 FontSize := 12; 38 40 DbRows := Database.Select('news', '*', 'category=' + IntToStr(Category) + ' ORDER BY date DESC LIMIT 0,' + IntToStr(NewsCountPerCategory)); 39 41 for I := 0 to DbRows.Count - 1 do with DbRows[I] do begin 40 Result := Result + '<tr><td onmouseover="zobraz(''."''new".$Category.$Index."''".'')" style="cursor: pointer; margin: 0px;"><table cellspacing="0" cellpadding="0" style="padding: 0px; margin: 0px; font-size: small; color: red;" width="100%">'+ 42 Content := Values['content']; 43 Content := StringReplace(Content, '<br>', '<br />', [rfReplaceAll]); 44 Result := Result + '<tr><td onmouseover="zobraz(''new' + IntToStr(Category) + '_' + IntToStr(I) + ''')" style="cursor: pointer; margin: 0px;"><table cellspacing="0" cellpadding="0" style="padding: 0px; margin: 0px; font-size: small; color: red;" width="100%">'+ 41 45 '<tr><td style="font-size: ' + IntToStr(FontSize) + 'pt"><strong>' + Values['title'] + '</strong></td>'+ 42 46 '<td align="right" style="font-size: ' + IntToStr(FontSize) + 'pt">' + Values['author'] + ' (' + HumanDate(Values['date']) + ')</td></tr></table>'+ 43 '<div id="new' + IntToStr(Category) + IntToStr(Index) + '" class="skryty" style="display: none; border-width: 1; border-style: solid; border-color: blue; padding: 3px; font-size: 9pt;">' + Values['content'];47 '<div id="new' + IntToStr(Category) + '_' + IntToStr(Index) + '" class="skryty" style="display: none; border-width: 1; border-style: solid; border-color: blue; padding: 3px; font-size: 9pt;">' + Content; 44 48 45 49 if Values['enclosure'] <> '' then begin 46 Result := Result + '<br >Přílohy: ';50 Result := Result + '<br />Přílohy: '; 47 51 Enclosures := Explode(';', Values['enclosure']); 48 52 for II := 0 to High(Enclosures) do begin … … 64 68 begin 65 69 Output := ShowHeader('<strong>ZděchovNET</strong> - komunitní počítačová síť', 'Rozcestník'); 66 Output := Output + '<script type="text/javascript">'+ 67 '<!--'+ 68 'function openClient(client_type)'+ 69 '{'+ 70 'if(client_type=="java")clientWindow = window.open("http://go.icq.com/icq2go/web.html","ICQ2Go","left=20,top=20,width=156,height=446,toolbar=0,resizable=0");'+ 71 'else clientWindow = window.open("http://go.icq.com/icq2go/flicq.html","ICQ2Go","left=20,top=20,width=176,height=441,toolbar=0,resizable=0");'+ 72 '}'+ 70 Output := Output + '<table width="100%"><tr><td valign="top">' + 71 '<div class="Panel">' + 72 '<strong>Důležité odkazy:</strong><br />' + 73 InsertIcon('money.gif') + ' <a href="?p=finance">Finance</a><br />' + 74 InsertIcon('chart.gif') + ' <a href="?p=statistic">Statistika</a><br />' + 75 InsertIcon('prohledavac_sdileni.gif') + ' <a href="/share">Prohledat sdílení</a><br />' + 76 InsertIcon('comp.gif') + ' <a href="/userlist.php">Seznam uživatelů</a><br />' + 77 InsertIcon('comp.gif') + ' <a href="/hostlist.php">Seznam počítačů</a><br />' + 78 InsertIcon('sunrisechat.gif') + ' <a href="/sunrisechat/history.php">Historie SunriseChatu</a><br />' + 79 InsertIcon('sunrisechat.gif') + ' <a href="/sunrisechat/webchat.php">Webový SunriseChatu</a><br />' + 80 InsertIcon('discus.gif') + ' <a href="/forum">Diskusní fórum</a><br />' + 81 InsertIcon('openwebmail.gif') + ' <a href="https://centrala.zdechov.net/cgi-bin/openwebmail/openwebmail.pl">WebMail</a><br />' + 82 InsertIcon('apple.gif') + ' <a href="/jidelna">Jídelníček</a><br />' + 83 InsertIcon('clear.gif') + ' <a href="http://tv.zdechov.net/">Televize</a><br />' + 84 InsertIcon('cube.gif') + ' <a href="http://game-server.zdechov.net/">Herní server</a><br />' + 85 InsertIcon('cfix.gif') + ' <a href="/farnost">Rozpis mší</a><br />' + 86 InsertIcon('tel.gif') + ' <a href="/telseznam.php">Telefonní seznam</a><br />' + 87 InsertIcon('pripoj.gif') + ' <a href="/nabidky_pripojeni.php">Nabídky připojení</a><br />' + 88 InsertIcon('zapisy.gif') + ' <a href="/docs/zapisy/zapisy.php">Zápisy ze schůzí</a><br />' + 89 InsertIcon('lear.gif') + ' <a href="/mapy/mapa.php">Mapa Zděchova</a><br />' + 90 InsertIcon('otv_doby.gif') + '<a href="/otevreno.php">Otvírací doby</a><br />' + 91 InsertIcon('topologie.gif') + ' <a href="/is/topologie.php">Topologie sítě</a><br />' + 92 InsertIcon('satellite.gif') + ' <a href="/is/dostupnost.php">Dostupnost sítě</a><br />' + 93 InsertIcon('tech.gif') + ' <a href="/network.php">Technické informace</a><br />' + 94 InsertIcon('socer.gif') + ' <a href="http://fotbal.zdechov.net/">Fotbal Sokol Zděchov</a><br />' + 95 '</div><div class="Panel">' + 96 '<strong>Další odkazy:</strong><br />' + 97 InsertIcon('tv.gif') + ' <a href="/tkr.php">Kanály kabelovky</a><br />' + 98 InsertIcon('clear.gif') + ' <a href="/mapy/mapa_nabidka.php">Nabídka mapy</a><br />' + 99 InsertIcon('clear.gif') + ' <a href="/history.php">Historie sítě</a><br />' + 100 InsertIcon('electric.gif') + ' <a href="/merak.php">Měřič spotřeby</a><br />' + 101 InsertIcon('clear.gif') + ' <a href="/ukoly.php">Plány do budoucna</a><br />' + 102 InsertIcon('clear.gif') + ' <a href="/navody.php">Návody</a><br />' + 103 InsertIcon('info.gif') + ' <a href="/infokanal/index.htm">Infokanál</a><br />' + 104 InsertIcon('progman.gif') + ' <a href="/manualy.php">Programátorské manuály</a><br />' + 105 '</div></td><td valign="top">' + 106 '<div class="Panel">' + 107 '<strong>Vyhledávání:</strong><br />'+ 108 InsertIcon('www_google_com.gif') + ' <a href="http://www.google.cz/">Google</a><br />' + 109 InsertIcon('morfeo.png') + ' <a href="http://morfeo.centrum.cz">Morfeo</a><br />' + 110 InsertIcon('www_centrum_cz.gif') + '<a href="http://www.centrum.cz">Centrum</a><br />' + 111 InsertIcon('www_seznam_cz.gif') + ' <a href="http://www.seznam.cz">Seznam</a><br />' + 112 InsertIcon('www_atlas_cz.gif') + ' <a href="http://www.atlas.cz">Atlas</a><br />' + 113 InsertIcon('www_tiscali_cz.gif') + ' <a href="http://www.tiscali.cz">Tiscali</a><br />' + 114 '</div><div class="Panel">' + 115 '<strong>Užitečné:</strong><br />'+ 116 InsertIcon('clear.gif') + ' <a href="http://www.zdechov.net">Stránky naší sítě</a><br />' + 117 InsertIcon('www_tvinfo_cz.gif') + ' <a href="http://www.tvinfo.cz/live/televize/cz">Online TV</a><br />' + 118 InsertIcon('www_idos_cz.gif') + ' <a href="http://www.idos.cz/ConnForm.asp?tt=c">Jízdní řády</a><br />' + 119 InsertIcon('www_atlas_cz.gif') + ' <a href="http://tv.atlas.cz">TV programy</a><br />' + 120 InsertIcon('www_icq_com.gif') + ' Web ICQ <a href="javascript:openClient(''flash'')">Flash</a> <a href="javascript:openClient(''java'')">Java</a><br />' + 121 InsertIcon('www_centrum_cz.gif') + ' <a href="http://slovniky.centrum.cz">Slovníky</a><br />' + 122 InsertIcon('pocasi.gif') + ' <a href="http://www.meteopress.cz/">Počasí</a><br />' + 123 InsertIcon('www_tzones_cz.gif') + ' <a href="http://www.tzones.cz/">T-Mobile SMS</a><br />' + 124 InsertIcon('www_mvk_cz.png') + ' <a href="http://www.mvk.cz/">Knihovna Vsetín</a><br />' + 125 '</div><div class="Panel">' + 126 '<strong>Prodej počítačů:</strong><br />'+ 127 InsertIcon('www_computershop_cz.png') + ' <a href="http://shop.computershop.cz/eshop/">SOFTCOM</a><br />' + 128 InsertIcon('www_alfacomp_cz.gif') + ' <a href="http://www.alfacomp.cz/php/zbozi.php?akc=2">Alfacomp</a><br />' + 129 InsertIcon('www_petracomp_cz.png') + ' <a href="http://www.petracomp.cz/">Petracomp</a><br />' + 130 InsertIcon('www_tsbohemia_cz.png') + ' <a href="http://interlink.tsbohemia.cz/">TS Bohemia</a><br />' + 131 '</div></td><td valign="top">' + 132 '<div class="Panel">'; 73 133 74 'var predchozi = ''first'';'+75 ''+76 'function zobraz(idecko)'+77 '{'+78 ' skryj(predchozi);'+79 'el=document.getElementById(idecko).style;'+80 ' el.display=''block'';'+81 'predchozi = idecko;'+82 '}'+83 ''+84 'function skryj(idecko)'+85 '{'+86 'if(idecko != ''first'')'+87 '{'+88 ' el=document.getElementById(idecko).style;'+89 ' el.display=''none'';'+90 '}'+91 '}'+92 '//-->'+93 '</script>'+94 ''+95 '<table width="100%"><tr><td valign="top">' +96 '<table width="100%">' +97 '<tr><td width="20%" valign="top">' +98 '<strong>Důležité odkazy:</strong><br>' +99 InsertIcon('money.gif') + ' <a href="?p=finance">Finance</a><br>' +100 InsertIcon('chart.gif') + ' <a href="?p=statistic">Statistika</a><br>' +101 InsertIcon('prohledavac_sdileni.gif') + ' <a href="/share">Prohledat sdílení</a><br>' +102 InsertIcon('comp.gif') + ' <a href="/userlist.php">Seznam uživatelů</a><br>' +103 InsertIcon('comp.gif') + ' <a href="/hostlist.php">Seznam počítačù</a><br>' +104 InsertIcon('sunrisechat.gif') + ' <a href="/sunrisechat/history.php">Historie SunriseChatu</a><br>' +105 InsertIcon('sunrisechat.gif') + ' <a href="/sunrisechat/webchat.php">Webový SunriseChatu</a><br>' +106 InsertIcon('discus.gif') + ' <a href="/forum">Diskusní fórum</a><br>' +107 InsertIcon('openwebmail.gif') + ' <a href="https://centrala.zdechov.net/cgi-bin/openwebmail/openwebmail.pl">WebMail</a><br>' +108 InsertIcon('apple.gif') + ' <a href="/jidelna">Jídelníček</a><br>' +109 InsertIcon('clear.gif') + ' <a href="http://tv.zdechov.net/">Televize</a><br>' +110 InsertIcon('cube.gif') + ' <a href="http://game-server.zdechov.net/">Herní server</a><br>' +111 InsertIcon('cfix.gif') + ' <a href="/farnost">Rozpis mší</a><br>' +112 InsertIcon('tel.gif') + ' <a href="/telseznam.php">Telefonní seznam</a><br>' +113 InsertIcon('pripoj.gif') + ' <a href="/nabidky_pripojeni.php">Nabídky připojení</a><br>' +114 InsertIcon('zapisy.gif') + ' <a href="/docs/zapisy/zapisy.php">Zápisy ze schůzí</a><br>' +115 InsertIcon('lear.gif') + ' <a href="/mapy/mapa.php">Mapa Zděchova</a><br>' +116 InsertIcon('otv_doby.gif') + '<a href="/otevreno.php">Otvírací doby</a><br>' +117 InsertIcon('topologie.gif') + ' <a href="/is/topologie.php">Topologie sítě</a><br>' +118 InsertIcon('satellite.gif') + ' <a href="/is/dostupnost.php">Dostupnost sítě</a><br>' +119 InsertIcon('tech.gif') + ' <a href="/network.php">Technické informace</a><br>' +120 InsertIcon('socer.gif') + ' <a href="http://fotbal.zdechov.net/">Fotbal Sokol Zděchov</a><br>' +121 '<br>' +122 '<strong>Další odkazy:</strong><br>' +123 InsertIcon('tv.gif') + ' <a href="/tkr.php">Kanály kabelovky</a><br>'+124 InsertIcon('clear.gif') + ' <a href="/mapy/mapa_nabidka.php">Nabídka mapy</a><br>'+125 InsertIcon('clear.gif') + ' <a href="/history.php">Historie sítě</a><br>'+126 InsertIcon('electric.gif') + ' <a href="/merak.php">Měřič spotřeby</a><br>'+127 InsertIcon('clear.gif') + ' <a href="/sluzby.php">Seznam služeb</a><br>'+128 InsertIcon('clear.gif') + ' <a href="/ukoly.php">Plány do budoucna</a><br>'+129 InsertIcon('clear.gif') + ' <a href="/navody.php">Návody</a><br>'+130 InsertIcon('info.gif') + ' <a href="/infokanal/index.htm">Infokanál</a><br>'+131 InsertIcon('progman.gif') + ' <a href="/manualy.php">Programátorské manuály</a><br>'+132 '<br>'+133 '</td><td width="13%" valign="top">'+134 '<strong>Vyhledávání:</strong><br>'+135 InsertIcon('www_google_com.gif') + ' <a href="http://www.google.cz/">Google</a><br>'+136 InsertIcon('morfeo.png') + ' <a href="http://morfeo.centrum.cz">Morfeo</a><br>'+137 InsertIcon('www_centrum_cz.gif"') + '<a href="http://www.centrum.cz">Centrum</a><br>'+138 InsertIcon('www_seznam_cz.gif') + ' <a href="http://www.seznam.cz">Seznam</a><br>'+139 InsertIcon('www_atlas_cz.gif') + ' <a href="http://www.atlas.cz">Atlas</a><br>'+140 InsertIcon('www_tiscali_cz.gif') + ' <a href="http://www.tiscali.cz">Tiscali</a><br>'+141 '<br>'+142 '<strong>Užitečné:</strong><br>'+143 InsertIcon('clear.gif') + ' <a href="http://www.zdechov.net">Stránky naší sítě</a><br>'+144 InsertIcon('www_tvinfo_cz.gif') + ' <a href="http://www.tvinfo.cz/live/televize/cz">Online TV</a><br>'+145 InsertIcon('www_idos_cz.gif') + ' <a href="http://www.idos.cz/ConnForm.asp?tt=c">Jízdní řády</a><br>'+146 InsertIcon('www_atlas_cz.gif') + ' <a href="http://tv.atlas.cz">TV programy</a><br>'+147 InsertIcon('www_icq_com.gif') + ' Web ICQ <a href="javascript:openClient(''flash'')">Flash</a> <a href="javascript:openClient(''java'')">Java</a><br>'+148 InsertIcon('www_centrum_cz.gif') + ' <a href="http://slovniky.centrum.cz">Slovníky</a><br>'+149 InsertIcon('pocasi.gif') + ' <a href="http://www.meteopress.cz/">Počasí</a><br>'+150 InsertIcon('www_tzones_cz.gif') + ' <a href="http://www.tzones.cz/">T-Mobile SMS</a><br>'+151 InsertIcon('www_mvk_cz.png') + ' <a href="http://www.mvk.cz/">Knihovna Vsetín</a><br>'+152 '<br>'+153 '<strong>Prodej počítačů:</strong><br>'+154 InsertIcon('www_computershop_cz.png') + ' <a href="http://shop.computershop.cz/eshop/">SOFTCOM</a><br>'+155 InsertIcon('www_alfacomp_cz.gif') + ' <a href="http://www.alfacomp.cz/php/zbozi.php?akc=2">Alfacomp</a><br>'+156 InsertIcon('www_petracomp_cz.png') + ' <a href="http://www.petracomp.cz/">Petracomp</a><br>'+157 InsertIcon('www_tsbohemia_cz.png') + ' <a href="http://interlink.tsbohemia.cz/">TS Bohemia</a><br>'+158 '<br>' +159 '</td>' +160 '<td width="15%" valign="top">';161 134 // Zobrazení seznamu online poèítaèù 162 Output := Output + '<strong>Online počítače:</strong><br ><span style="font-size: smaller;">';135 Output := Output + '<strong>Online počítače:</strong><br /><span style="font-size: smaller;">'; 163 136 DbRows := Database.Select('hosts', 'name', 'online=1 AND show_online=1 ORDER BY name'); 164 137 for I := 0 to DbRows.Count - 1 do with DbRows[I] do begin 165 Output := Output + Values['name'] + '<br >';138 Output := Output + Values['name'] + '<br />'; 166 139 end; 167 140 DbRows.Free; 168 Output := Output + '</span><br >';141 Output := Output + '</span><br />'; 169 142 170 // Zobrazení seznamu dlu¾níkù 171 Output := Output + '<strong>Dlužníci:</strong><br><span style="font-size: smaller;">'; 143 (* 144 // Zobrazení seznamu dlužníkù 145 Output := Output + '<strong>Dlužníci:</strong><br /><span style="font-size: smaller;">'; 172 146 DbRows := Database.Select('users', 'fullname', 'cash<0 ORDER BY cash'); 173 147 for I := 0 to DbRows.Count - 1 do with DbRows[I] do begin 174 Output := Output + Values['fullname'] + '<br >';148 Output := Output + Values['fullname'] + '<br />'; 175 149 end; 176 150 DbRows.Free; 177 151 Output := Output + '</span>'; 178 152 Output := Output + '</td></tr></table>'; 179 180 (* 153 *) 154 155 (* 181 156 // Zobrazení èasu bìhu poèítaèe 182 157 Data = explode(' ', exec('uptime')); … … 196 171 echo('Server bì¾í '.$Uptime); 197 172 *) 198 Output := Output + '</ td><td width="50%" valign="top" style="font-size: smaller;">';173 Output := Output + '</div></td><td valign="top">'; 199 174 200 175 (* … … 208 183 *) 209 184 210 Output := Output + '<div onmouseout="skryj(predchozi)">' + ShowNews(5) + ShowNews(3) + ShowNews(1) + ShowNews(2) + ShowNews(4) + ShowNews(6) + ShowNews(8) + ShowNews(9) + ShowNews(10);185 Output := Output + '<div onmouseout="skryj(predchozi)">' + ShowNews(5) + ShowNews(3) + ShowNews(1) + ShowNews(2) + ShowNews(4) + ShowNews(6) + ShowNews(8) + ShowNews(9) + ShowNews(10); 211 186 212 Output := Output + '<a href="aktuality/subscription.php"><img s tyle="margin: 0px 0px 0px 0px;" border="0" src="images/rss20.png" alt="Aktuality pøes RSS"></a> <a href="aktuality/subscription.php">Automatické sledování novinek</a>'+187 Output := Output + '<a href="aktuality/subscription.php"><img src="images/rss20.png" alt="Aktuality přes RSS" /></a> <a href="aktuality/subscription.php">Automatické sledování novinek</a>'+ 213 188 '</div></td></tr></table>'; 214 189 Output := Output + ShowFooter; -
devel/web/deploy.sh
r134 r137 8 8 -Xs -XX -CX index.pas 9 9 10 cp index /var/www/cgi-bin/index.cgi 10 mv index index.cgi -
devel/web/index.lpi
r134 r137 13 13 <IconPath Value="./"/> 14 14 <TargetFileExt Value=".exe"/> 15 <ActiveEditorIndexAtStart Value=" 1"/>15 <ActiveEditorIndexAtStart Value="2"/> 16 16 </General> 17 17 <VersionInfo> 18 18 <ProjectVersion Value=""/> 19 <Language Value=""/>20 <CharSet Value=""/>21 19 </VersionInfo> 22 20 <PublishOptions> … … 32 30 </local> 33 31 </RunParams> 34 <Units Count=" 3">32 <Units Count="13"> 35 33 <Unit0> 36 34 <Filename Value="index.pas"/> 37 35 <IsPartOfProject Value="True"/> 38 36 <UnitName Value="Hello"/> 39 <CursorPos X=" 8" Y="6"/>37 <CursorPos X="43" Y="16"/> 40 38 <TopLine Value="1"/> 41 <EditorIndex Value=" 0"/>42 <UsageCount Value="2 0"/>39 <EditorIndex Value="1"/> 40 <UsageCount Value="21"/> 43 41 <Loaded Value="True"/> 44 42 </Unit0> … … 47 45 <IsPartOfProject Value="True"/> 48 46 <UnitName Value="UMainPage"/> 49 <CursorPos X=" 1" Y="1"/>50 <TopLine Value=" 1"/>47 <CursorPos X="32" Y="33"/> 48 <TopLine Value="28"/> 51 49 <EditorIndex Value="2"/> 52 <UsageCount Value="2 0"/>50 <UsageCount Value="21"/> 53 51 <Loaded Value="True"/> 54 52 </Unit1> 55 53 <Unit2> 56 54 <Filename Value="USqlDatabase.pas"/> 55 <IsPartOfProject Value="True"/> 57 56 <UnitName Value="USqlDatabase"/> 58 <CursorPos X="22" Y="8"/> 57 <CursorPos X="47" Y="96"/> 58 <TopLine Value="79"/> 59 <EditorIndex Value="0"/> 60 <UsageCount Value="21"/> 61 <Loaded Value="True"/> 62 </Unit2> 63 <Unit3> 64 <Filename Value="UXmlClasses.pas"/> 65 <IsPartOfProject Value="True"/> 66 <UsageCount Value="21"/> 67 </Unit3> 68 <Unit4> 69 <Filename Value="UCore.pas"/> 70 <IsPartOfProject Value="True"/> 71 <UnitName Value="UCore"/> 72 <CursorPos X="38" Y="79"/> 73 <TopLine Value="61"/> 74 <EditorIndex Value="4"/> 75 <UsageCount Value="21"/> 76 <Loaded Value="True"/> 77 </Unit4> 78 <Unit5> 79 <Filename Value="UFinance.pas"/> 80 <IsPartOfProject Value="True"/> 81 <UnitName Value="UFinance"/> 82 <CursorPos X="1" Y="1"/> 83 <TopLine Value="81"/> 84 <EditorIndex Value="3"/> 85 <UsageCount Value="21"/> 86 <Loaded Value="True"/> 87 </Unit5> 88 <Unit6> 89 <Filename Value="UFinancePage.pas"/> 90 <IsPartOfProject Value="True"/> 91 <UnitName Value="UFinancePage"/> 92 <CursorPos X="45" Y="19"/> 93 <TopLine Value="10"/> 94 <EditorIndex Value="6"/> 95 <UsageCount Value="21"/> 96 <Loaded Value="True"/> 97 </Unit6> 98 <Unit7> 99 <Filename Value="UHtmlClasses.pas"/> 100 <IsPartOfProject Value="True"/> 101 <UnitName Value="UHtmlClasses"/> 102 <CursorPos X="1" Y="1"/> 59 103 <TopLine Value="1"/> 60 <EditorIndex Value="1"/> 104 <EditorIndex Value="5"/> 105 <UsageCount Value="21"/> 106 <Loaded Value="True"/> 107 </Unit7> 108 <Unit8> 109 <Filename Value="UNews.pas"/> 110 <IsPartOfProject Value="True"/> 111 <UnitName Value="UNews"/> 112 <CursorPos X="5" Y="40"/> 113 <TopLine Value="8"/> 114 <EditorIndex Value="8"/> 115 <UsageCount Value="21"/> 116 <Loaded Value="True"/> 117 </Unit8> 118 <Unit9> 119 <Filename Value="UNewsPage.pas"/> 120 <IsPartOfProject Value="True"/> 121 <UnitName Value="UNewsPage"/> 122 <CursorPos X="38" Y="100"/> 123 <TopLine Value="82"/> 124 <EditorIndex Value="7"/> 125 <UsageCount Value="21"/> 126 <Loaded Value="True"/> 127 </Unit9> 128 <Unit10> 129 <Filename Value="../../../../../../../usr/share/fpcsrc/rtl/unix/sysutils.pp"/> 130 <UnitName Value="sysutils"/> 131 <CursorPos X="10" Y="94"/> 132 <TopLine Value="81"/> 61 133 <UsageCount Value="10"/> 62 <Loaded Value="True"/> 63 </Unit2> 134 </Unit10> 135 <Unit11> 136 <Filename Value="../../../../../../../usr/share/fpcsrc/rtl/objpas/sysutils/sysutils.inc"/> 137 <CursorPos X="26" Y="17"/> 138 <TopLine Value="121"/> 139 <UsageCount Value="10"/> 140 </Unit11> 141 <Unit12> 142 <Filename Value="../../../../../../../usr/share/fpcsrc/rtl/objpas/sysutils/sysstrh.inc"/> 143 <CursorPos X="4" Y="33"/> 144 <TopLine Value="18"/> 145 <UsageCount Value="10"/> 146 </Unit12> 64 147 </Units> 65 <JumpHistory Count="2 " HistoryIndex="1">148 <JumpHistory Count="28" HistoryIndex="27"> 66 149 <Position1> 67 <Filename Value="U SqlDatabase.pas"/>68 <Caret Line=" 1" Column="1" TopLine="1"/>150 <Filename Value="UMainPage.pas"/> 151 <Caret Line="89" Column="88" TopLine="73"/> 69 152 </Position1> 70 153 <Position2> 71 <Filename Value="U SqlDatabase.pas"/>72 <Caret Line=" 8" Column="27" TopLine="1"/>154 <Filename Value="UMainPage.pas"/> 155 <Caret Line="90" Column="80" TopLine="74"/> 73 156 </Position2> 157 <Position3> 158 <Filename Value="UMainPage.pas"/> 159 <Caret Line="91" Column="96" TopLine="75"/> 160 </Position3> 161 <Position4> 162 <Filename Value="UMainPage.pas"/> 163 <Caret Line="93" Column="39" TopLine="77"/> 164 </Position4> 165 <Position5> 166 <Filename Value="UMainPage.pas"/> 167 <Caret Line="94" Column="71" TopLine="78"/> 168 </Position5> 169 <Position6> 170 <Filename Value="UMainPage.pas"/> 171 <Caret Line="95" Column="84" TopLine="79"/> 172 </Position6> 173 <Position7> 174 <Filename Value="UMainPage.pas"/> 175 <Caret Line="96" Column="76" TopLine="80"/> 176 </Position7> 177 <Position8> 178 <Filename Value="UMainPage.pas"/> 179 <Caret Line="97" Column="80" TopLine="81"/> 180 </Position8> 181 <Position9> 182 <Filename Value="UMainPage.pas"/> 183 <Caret Line="98" Column="77" TopLine="82"/> 184 </Position9> 185 <Position10> 186 <Filename Value="UMainPage.pas"/> 187 <Caret Line="106" Column="88" TopLine="83"/> 188 </Position10> 189 <Position11> 190 <Filename Value="UMainPage.pas"/> 191 <Caret Line="124" Column="104" TopLine="103"/> 192 </Position11> 193 <Position12> 194 <Filename Value="UMainPage.pas"/> 195 <Caret Line="132" Column="64" TopLine="116"/> 196 </Position12> 197 <Position13> 198 <Filename Value="UMainPage.pas"/> 199 <Caret Line="135" Column="47" TopLine="119"/> 200 </Position13> 201 <Position14> 202 <Filename Value="UMainPage.pas"/> 203 <Caret Line="138" Column="35" TopLine="122"/> 204 </Position14> 205 <Position15> 206 <Filename Value="UMainPage.pas"/> 207 <Caret Line="142" Column="56" TopLine="126"/> 208 </Position15> 209 <Position16> 210 <Filename Value="UMainPage.pas"/> 211 <Caret Line="145" Column="51" TopLine="129"/> 212 </Position16> 213 <Position17> 214 <Filename Value="UMainPage.pas"/> 215 <Caret Line="24" Column="3" TopLine="8"/> 216 </Position17> 217 <Position18> 218 <Filename Value="UMainPage.pas"/> 219 <Caret Line="7" Column="48" TopLine="1"/> 220 </Position18> 221 <Position19> 222 <Filename Value="UMainPage.pas"/> 223 <Caret Line="104" Column="39" TopLine="89"/> 224 </Position19> 225 <Position20> 226 <Filename Value="UMainPage.pas"/> 227 <Caret Line="112" Column="36" TopLine="97"/> 228 </Position20> 229 <Position21> 230 <Filename Value="UMainPage.pas"/> 231 <Caret Line="123" Column="44" TopLine="108"/> 232 </Position21> 233 <Position22> 234 <Filename Value="UMainPage.pas"/> 235 <Caret Line="178" Column="36" TopLine="163"/> 236 </Position22> 237 <Position23> 238 <Filename Value="UMainPage.pas"/> 239 <Caret Line="3" Column="109" TopLine="1"/> 240 </Position23> 241 <Position24> 242 <Filename Value="UMainPage.pas"/> 243 <Caret Line="7" Column="93" TopLine="1"/> 244 </Position24> 245 <Position25> 246 <Filename Value="UFinancePage.pas"/> 247 <Caret Line="19" Column="21" TopLine="11"/> 248 </Position25> 249 <Position26> 250 <Filename Value="UMainPage.pas"/> 251 <Caret Line="12" Column="44" TopLine="1"/> 252 </Position26> 253 <Position27> 254 <Filename Value="UMainPage.pas"/> 255 <Caret Line="43" Column="23" TopLine="28"/> 256 </Position27> 257 <Position28> 258 <Filename Value="UMainPage.pas"/> 259 <Caret Line="43" Column="27" TopLine="28"/> 260 </Position28> 74 261 </JumpHistory> 75 262 </ProjectOptions> 76 263 <CompilerOptions> 77 264 <Version Value="8"/> 265 <Target> 266 <Filename Value="index.cgi"/> 267 </Target> 268 <SearchPaths> 269 <OtherUnitFiles Value="/var/www/html/other/powtils/extras/;/var/www/html/other/powtils/main/"/> 270 <LCLWidgetType Value="gtk2"/> 271 </SearchPaths> 272 <Parsing> 273 <SyntaxOptions> 274 <CStyleOperator Value="False"/> 275 </SyntaxOptions> 276 </Parsing> 277 <CodeGeneration> 278 <SmartLinkUnit Value="True"/> 279 <Checks> 280 <IOChecks Value="True"/> 281 <RangeChecks Value="True"/> 282 <OverflowChecks Value="True"/> 283 <StackChecks Value="True"/> 284 </Checks> 285 <VerifyObjMethodCallValidity Value="True"/> 286 </CodeGeneration> 287 <Linking> 288 <LinkSmart Value="True"/> 289 </Linking> 78 290 <Other> 79 291 <CompilerPath Value="$(CompPath)"/> -
devel/web/index.pas
r134 r137 5 5 uses 6 6 UCore, USqlDatabase, SysUtils, UMainPage, pwinit, pwmain, 7 UFinancePage ;7 UFinancePage, UNewsPage; 8 8 9 9 var … … 14 14 SetHeader('Content-Type', 'text/html; charset=utf-8'); 15 15 PageName := GetCgiVar('p'); 16 if PageName = '' then PageName := ' finance-clenove';16 if PageName = '' then PageName := 'index'; 17 17 I := 0; 18 18 while (I < Length(Pages)) and (Pages[I].Name <> PageName) do Inc(I); 19 19 if I < Length(Pages) then Output := Pages[I].Producer 20 20 else Output := 'Stránka nenalezena'; 21 WebWriteLn( Output);21 WebWriteLn(FormatOutput(Output)); 22 22 end.
Note:
See TracChangeset
for help on using the changeset viewer.