Im trying to make a client area on my website and an not sure on how to go about editing clients details.When the client logs in they are brought to a menu where they can update there record. How can i get the appropriate record from the database so they can update there details?
I'm trying to get a very simple task to work. Using the users login name (gained from IE) I want to get their full name from AD (Win 2k and 2003 AD domain).I'm using this ASP code on the IIS server:
usr=mid(request.ServerVariables("LOGON_USER"),8) Set User = GetObject("WinNT://domainname/" & usr & ",user") response.write "Name is " & User.Fullname set usr=nothing
This code works fine when run on the server direct using wscript, but when served by the web server I get the error:
Active Directory (0x80070005) General access denied error
I have a working members code now where members can sign up, login to a protected page and log out. I now want to personalise each members login so when a member logs in it says welcome [username] etc and then when the use logs out it says 'thanks [username] you have logged out'. I tried to query my database but it doesnt work.
how I can repeat details in a ASP page. For example I have to fill in a a form which has the following quetion.Language : (a text box here to fill in the details)
and then a message with 2 buttons Do you want to insert another? YES NOWhen click on the button YES, I want my asp page to take the quetion "Language :" and the text box and copy it so the user can insert another value.How can I do it ??
Is there a way of detecting and then recording a visitors details(eg. browser, ip, country, OS...) and then storing that info to a database automatically?If, so, could you plz tell me how to record the info straight to a database without the user having to click on anything.
I have seen an example of a page that displays the users browser details in a friendly manner like this:
Your operating system : Microsoft Windows NT Your browser : Microsoft Internet Explorer 6.0
from a HTTP_User_Agent string like this: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0) Can somebody give me some sample code of how I can extract this result out of the string, using asp.
I have a list of requests that I'm displaying. The client wants to be able to display the details of the FIRST request as the page loads.
Right now, as I loop through the recordset, I'm checking the querystring for "rid", and if rid = "" then I do a response.redirect to the page adding the rid value to the querystring from the recordset.
I'm thinking this is not very effecient, but I can't figure out anything better.. anyone have a good solution to show the details of the first item on the list?
I am looking to create an upload page for my website. I would like to have the user login and depending on who they log in as depends on which folder they upload to. I'd like to be able to upload multiple files, have the file size(s) show up on the form and also be able to calculate how much time it will take to upload the file.
Is it possible to run an asp script to display the details (i.e. last modifed time/date) of several files held on the client and or on the server running IIS (if i map it to the folder with the files in question).
im trying to work out basicly what i want to do his have a list of downloads and then at the top of the page have a form that has contact details that enables the download links and sends the details to an email address. is this possible and if so are there any scripts avaliable
I'm trying to build a details page that is reachable when a user clicks on the ID of a query that's returned multiple rows of data. The first piece of code is the querytest.asp page, and the second is the details.asp page. However, how do I get the user_id passed to the details page? Code:
The code below takes the script name of a page (which is always an asp file) and substitutes the asp extension with html and then inserts the file in the <frame> tag.
This code works file for a url such as www.somesite.com/file.asp But if the url includes an index eg www.somesite.com/file.asp#position1 how do I get the #position1 added to the file name that is used in the <frame> tag? Is there a server variable for # info? Code:
I have a button which runs and submits a form and if the name and contact details aren't filled out yet all it does is recalculate some totals.
BUT, my problem is that there is a checkbox in this form that is being cleared when the form is submitted at this stage, is there anyway to stop this??
I am of the understanding that the checkbox has to be in the form because when it is selected it adds a value to a field further down in the form.
There is also another text field that I need retained as well???
Just uploaded my database how to i create a simple page where i can enter customer details into my database. i would like fields like customer id, first name last name etc where the telephone number could be the primary key
I badly need help head sore from banging it off the wall. I have a Gridview which when a field is clicked on displays more details for that record in detailsview. I am using a single SQL table with fields for details and 3 image file locations.
I need to create a slideshow in detailsview to show these 3 images. I have no problem displying 1 image but don't know how to add a link to flick between images.
i have managed to pass over one item from a form and put it into the database, using this code:
' This writes information from the form to the customer database field (cust_name) dim name
name =request.Form("name")
strSQL="INSERT INTO customer (cust_name) VALUES ('" & name & "');"
con.Execute strSQL %>
how do i pass over more than one field and put them into the database, at the moment i can only pass over the name data and then store it into the cust_name field in the data base now i want to pass over address postcode , e.g and put that into the db how can i do this.
I've always been looking for the best way to get an accurate percentage statistics.
For example, in a election scenario:
Person A gets 33 votes Person B gets 33 votes Person C gets 34 votes Person D gets 35 votes
Total votes = 33 + 33 + 34 + 35 = 135 Percent for A = 0.244.... = 0.24 = 24% Percent for B = 0.244... = 0.24 = 24% Percent for C = 0.251... = 0.25 = 25% Percent for D = 0.259... = 0.26 = 26%
Then add up the percentage values: 24 + 24 + 25 + 26 = 99 (where it should be 100)
So, does anybody have a way to get around this problem? How should I calculate the percentage for each person so that the percentage will add up to 100 in the end?
I am needing to response.write a variable within a snippet of Javascript. My Javascript code that I need to response.write with the variable is below:-Code:
response.write ("imageArray[ImageNum++] = new imageItem(image_dir + ""variable here"");")
I can response.write the static Javascript string fine. The problem arises when I try and state a variable into where it says, 'variable here' The variable I need to include is Code: rs.Fields("ImgURL") Would someone please be able to show me the correct formatting for this Javascript string which includes the variable.
My asp syntax is very lacking, it seems the double quotes that have been done by me are not what asp is looking for. Anyone that could correct my faulty thinking would be thanked.
how to display correct time according to user timezone i want to do an online meeting let say schedule meeting at 1:00pm server time, how do i display the correct time for users in their local time
I have a form where users can enter search criteria for various products. now, if this form has 2 fields, colour and size (it wil have more but I'm assuming the the principle for two fields will be the same for ten fields) what would be the correct syntax for performing a query where the user didn't enter a criteria for both fields? the search string would be
strSQL = "SELECT * FROM products where colour = " & "'" & request.form("searchstrcolour") & "'" & "AND size =" & "'" request.form("searchstrsize") & "'" & " ORDER by price"
so if the user selects blue and large, thats fine but what if the user only selected say blue and didn't bother with the size? is there a wild card that I could use?
can someone explain to me the diffrence between the 2 below and why one works and the other one doesnt.could you also explain what each part of the correct version is doing because i dont really no.
INCORRECT
sql = "SELECT * FROM userlogon WHERE (username)=' "& (username) & "' AND (password)=' " & (password) & " ' "
CORRECT
sql = "SELECT * FROM [userlogon] WHERE [username]=' "& username & "' AND [password]=' " & password & " ' "
I am trying to develop a shopping cart using a dictionary object to represent the shopping basket. I have a products page which displays all the products for the user to click on to add products to the basket. This works fine.
The problem I am having is when I want to display the content of the shopping cart. The dictionary object can only contain the product id / quantity, so I have written a function which uses the product ID to retrieve the product details from the database.
Whilst I can output the values in the function which retrieves the data from table into the array, I can't output the values in the procedure which receives the array. Code:
I've created a form for users to fill in, and I want to be able to write the details of each form to a text file. Each file is named username.txt (eg. JohnSmith.txt or MikeStiletti.txt)
However, when the code below is processed i get a "Path not found" error. Now these files are on a web server and i am trying to write to my C drive. It would be great if I could create these files on the same web server too by just removing the "C:Surveys" on the bolded line. Code:
I have a feedback form which asks someone to enter their personal details and then submits them to db. There are input, checkboxes and selection boxes on form.
Now I want to allow user to edit this form. When user clicks 'edit', I retrieve all the values from db and populate the text boxes.
What happens with the options and checkboxes. How can I get these to reflect what their values in db? Also I have some drop downs allowing user to select date of birth ie. day drop down, month drop down and year drop down. How do I show user the details we have for them if I'm using drop downs?
I am looking into creating a intranet at work which will do a number of things including forums etc but one thing that i would like to do i dont know if it is possible or not.
When a user signs into their workstation it will launch the intranet, no problem, then i want it to log them in as the user id they logged into the workstation as. Is there any way of getting this information???