Hej Har kollat på de sidor som var med Login programmet. På de sidor så står detett litet problem med Login Manager
Har laddat ner Breathofair Login Manager V1.
har då en liten fråga om hur man ska lägga in koden så att bara inloggade admins/mods får tillgån till sidorna??
I texten står det:
To add restrictions to your webpage you require the follow code
<!--#include virtual="Relative path to /Site_Common.asp" -->
There are 2 Places that require changing for the paths to the pages in the above file, the lines that will require editing are:
- Closed.asp
- Member_Suspended.asp
Here are some examples that are added below the include file for rescrictions
Don't forget to set up your Return Page system by opening the returns.asp file
Administrators & Moderators Only
<%
if blnModerator = False then
' close all connections to the database
adoCon.Close
SET adoCon = Nothing
SET strCon = Nothing
' use a relative path below to make it work from the root folder ..
' you don't have to but it makes it better coded
response.redirect "/loginManager/access_denied.asp<%= strReturnPageProperties %>"
End if
%>
Är det bara att länka till Site_Common och sen lägga in if blnModerator... överst ??
Tacksam för alla tips jag kan fåSv: ett litet problem med Login Manager
<!--#include file="common.asp" -->
<%
IF blnEdit_Groups = False Then
'Release server varaibles
adoCon.Close
SET adoCon = Nothing
SET strCon = Nothing
response.redirect "../access_denied.asp"
END IF
så jag provade:
<!--#include file="../../../Login/Site_Common.asp" -->
<%
If blnModerator = False Then
'Release server varaibles
adoCon.Close
SET adoCon = Nothing
SET strCon = Nothing
response.redirect "../../../Login/access_denied.asp"
END IF
%>
men får felmeddelandet:
Feltyp:
Microsoft OLE DB Provider for ODBC Drivers (0x80004005)
[Microsoft][Drivrutin för ODBC Microsoft Access]Allmänt fel Det går inte att öppna registernyckeln 'Temporary (volatile) Jet DSN for process 0x988 Thread 0x110c DBC 0x7e41bc Jet'.
Site_Common.asp, line 157
på linje 157 står det:
'Set an active connection to the Connection object
adoCon.Open strCon
vad kan jag göra för att få det att fungera??Sv:ett litet problem med Login Manager
Svara