<% Option Explicit %> <% '**************************************************************************************** '** Copyright Notice '** '** Copyright 2002 Drew Gauderman All Rights Reserved. '** '** This program is free software; you can redistribute it and/or modify '** it under the terms of the GNU General Public License as published by '** the Free Software Foundation; either version 2 of the License, or '** any later version. '** '** All copyright notices must remain intacked in the scripts and the '** outputted HTML. '** '** You may not pass the whole or any part of this application off as your own work. '** '** All links to www.maddogs-asp.com must remain in place and the powered by '** link or image must remain visiable when the pages are viewed. '** '** This program is distributed in the hope that it will be useful, '** but WITHOUT ANY WARRANTY; without even the implied warranty of '** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the '** GNU General Public License for more details. '** '** You should have received a copy of the GNU General Public License '** along with this program; if not, write to the Free Software '** Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA '** '** No official support is available for this program but you may post support questions at: - '** http://www.maddogs-asp.com/ '** '** Support questions are NOT answered by e-mail ever! '** '** For correspondence or non support questions contact: - '** webmaster@maddogs-asp.com '** '**************************************************************************************** Dim rsLinks Dim strLinkID Dim strStars Dim strInputName Dim strInputURL Dim strInputCategory Dim strInputDescription Dim strInputActive Dim strInputStatus Dim strMode If NOT strUserGood = "True" Then Response.Write "Niste ovlašteni da vidite ovu stranicu, ulogirajte se!" Response.End End If strInputName = Request.Form("name") strInputURL = Request.Form("url") strInputCategory = Request.Form("category") strInputDescription = Request.Form("description") strLinkID = Request.QueryString("ID") If strLinkID = "" Then Response.Write "Kriva identifikacija" Response.End End If strInputActive = Request.Form("Active") strInputStatus = Request.Form("Status") If strInputActive = "on" Then strInputActive = "True" Else strInputActive = "False" End If strMode= Request.Form("mode") Set rsLinks = Server.CreateObject("ADODB.Recordset") strSQL = "SELECT tblLinks.* FROM tblLinks Where tblLinks.ID = " & strLinkID & ";" rsLinks.CursorType = 2 rsLinks.LockType = 3 rsLinks.Open strSQL, strLinksCon If strMode = "update" Then rsLinks.Fields("Link") = strInputName rsLinks.Fields("URL") = strInputURL rsLinks.Fields("Cat_ID") = strInputCategory rsLinks.Fields("Description") = strInputDescription rsLinks.Fields("Active") = strInputActive rsLinks.Fields("Status") = strInputStatus rsLinks.Update rsLinks.Requery Response.Redirect "admin_links.asp?ID=" & Request.QueryString("ID") End If If Request.QueryString("Delete") = "True" Then rsLinks.Delete rsLinks.Update rsLinks.Requery Response.Write "Deleted!


Zatvori prozor" Response.End End If %> <% = strWebSiteName %> - Admin Linkovi " onSubmit="validate();return returnVal;" onReset="return confirm('Jeste li sigurni da želite poništiti promjene?');">
Admin Linkovi
<% If strMode = "add" Then %>

Hvala na dodanom linku!

Link će postati vidljiv kad ga administrator odobri!


<% Else %>
Naziv linka: ">
Adresa linka: ">
Aktivan: >
Prijavljen puta: ">
Kategorija:
Opis linka:
<% End If %> Zatvori prozor
&Delete=True">
<% rsLinks.Close Set rsLinks = Nothing %>