Access Database and HTML

E

elahd

Hi,

I'm working on an internal website for a high school. I have the sit
separated into two sections: public and internal. The internal site i
not complete, and i do not know where to begin. Here's what i want t
do:

- The school runs a Windows network on all of the school's computers.
Students and teachers have their own accounts and email can be checke
over the web on the school's Microsoft Office Exchange site (so logi
names and passwords are accessable to a web script). I want to lin
these existing user names and passwords to the school's main websit
for access to the internal elements through a login form.

- The school stores student and teacher schedules in an Access databse
I am looking for a way for the internal site to recognize the studen
after login (cookie?) and pull our his or her schedule from the Acces
database. I can figure out the data presentation once i know how t
pull strands of info from a database.

- I am also curious as to how to keep the internal elements of the sit
off limits to public browsers (it typing in the private directory an
running one of the private pages).

I'm a student in the school and am well versed in HTML, Flash an
JavaScript, and can manage CGI, but have never created an "internal
element to a site. Any help would be greatly appreciated.

Thank


-
elah
 
T

Toby A Inkster

elahd said:
- The school runs a Windows network on all of the school's computers.
Students and teachers have their own accounts and email can be checked
over the web on the school's Microsoft Office Exchange site (so login
names and passwords are accessable to a web script). I want to link
these existing user names and passwords to the school's main website
for access to the internal elements through a login form.

Much of what you want to do depends on what web server platform you're
using. On the intranet at work I've set up Apache on Linux web server to
authenticate against the Windows NT network logins using HTTP Basic auth,
mod_auth_pam, pam-smb and Samba. It's not too hard to do, and if you're
not having to cross the Linux-Windows bridge, things should be even easier.
- The school stores student and teacher schedules in an Access databse.
I am looking for a way for the internal site to recognize the student
after login (cookie?) and pull our his or her schedule from the Access
database. I can figure out the data presentation once i know how to
pull strands of info from a database.

You really need an IIS server to do this, although Apache on Windows may
do the trick.
- I am also curious as to how to keep the internal elements of the site
off limits to public browsers (it typing in the private directory and
running one of the private pages).

In your CGI scripts grab the IP address of visitor and check it against
a (hopefully known!) list of internal IP addresses.
 
A

Adrienne

Gazing into my crystal ball I observed elahd
Hi,

I'm working on an internal website for a high school. I have the site
separated into two sections: public and internal. The internal site is
not complete, and i do not know where to begin. Here's what i want to
do:

- The school runs a Windows network on all of the school's computers.
Students and teachers have their own accounts and email can be checked
over the web on the school's Microsoft Office Exchange site (so login
names and passwords are accessable to a web script). I want to link
these existing user names and passwords to the school's main website
for access to the internal elements through a login form.

- The school stores student and teacher schedules in an Access databse.
I am looking for a way for the internal site to recognize the student
after login (cookie?) and pull our his or her schedule from the Access
database. I can figure out the data presentation once i know how to
pull strands of info from a database.

- I am also curious as to how to keep the internal elements of the site
off limits to public browsers (it typing in the private directory and
running one of the private pages).

I'm a student in the school and am well versed in HTML, Flash and
JavaScript, and can manage CGI, but have never created an "internal"
element to a site. Any help would be greatly appreciated.

Thanks

Looks like you have access to IIS, which means can run ASP scripts.

Include something like this in the top of sensitive pages:
<!--#include file="loginchk.asp" -->

Loginchk.asp
<% session("frompage") = request.servervariables("url")
if request.querystring <> "" then
session("frompage") = session("frompage") & "?" &
request.querystring
else
session("frompage") = session("frompage")
end if

if loggedin <> true then
response.redirect "login.asp"
end if
%>


Login.asp
<% dim username
dim password
dim message
dim sql

Set loginrs = Server.CreateObject("ADODB.Recordset")
sql = "SELECT count(id) "
sql = sql & " FROM login "
sql = sql & " WHERE username = '" & request.form("username") & "'"
sql = sql & " AND password = '" & request.form("password") & "'"

loginrs.Open sql, yourconnection

if loginrs.EOF then
loggedin = false
loginrs.Close
Set loginrs = nothing
message = "Bad Username or Password"
else
loggedin = true
loginrs.Close
Set loginrs = nothing
response.redirect session("frompage")
end if
%>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,430
Messages
2,571,676
Members
48,796
Latest member
Greg L.

Latest Threads

Top