Help uploading test asp page with sql server 2000 onto webserver

Hi

I've been trying to create a test site - The site uses ASP with VBscript and talks to SQL Server 2000. I was able to complete and test it on my locally on my computer using Microsofts IIS 5.1. The website communicated fine with the database on the webserver/network server

However, when I tried to save the site from my local computer to the wwwroot folder in the servers IIS hoping to make the internal site available to here the resulting error comes up when we try to open a page with a recordset connected to the database: -

Having a nightmare, please help.
&nbsp(218 Views)
I am having a pain in the a** problem. Everything was working fine until I did an xhtml validation to find that you cannot place a div in between a data definitions list. So am having to find an alternative way fo achiving what i first set out.
Basically I have categories outputted from the news, this is shown as: Area Category. I managed to get the area to show once and then display all the items below it under.
I now need to add a closing when all the records for that area have finished. As you can see I managed to get the in where it is needed but now i need to finish it just after all the records for that area are complete.
Totally stumped, please help.
PHP Code:
SetoRS=oConn.Execute("EXECspNews'"&sAID&"','"&sNID&"','"&sNCID&"'")
currentType=0
DoWhileNotoRS.EOF
IfcurrentType oRS("AreaCategory")Then
Response.WritevbCr&vbCr&""&oRS("AreaCategory")&""&vbCr&vbCr&""&vbCr
currentType=oRS("AreaCategory")
EndIf
Response.Write""&oRS("NewsDate")&""&vbCr
Response.Write""&oRS("NewsH2")&""&vbCr
oRS.MoveNext
Loop

ASP help with form query
&nbsp(209 Views)
I have an ASP form that queries a database. It creates a drop down menu of a number of events. Once the event is selected it should go to a page where the admin can update the date and time. The drop down works, but when it goes to the next page, all it calls up is the first event in the database. For some reason, it doesn't show any other event, even when they are selected in the drop down menu. Please help!
Here's the first page of code with the drop down:
Code:

ASP project with Oracle Backend issue, need help ASAP
&nbsp(202 Views)
Guys,
I created a project at work (as a intern) . The platform was Windows Server 2003 and ASP code with Oracle 9i
The connection string i used was :
Set OraSession1 = CreateObject"OracleInProcServer.XOraSession")
Set OraDatabase1 = OraSession1.OpenDatabase("permitdb","permit_user/permit_user", Cint(0))
Set OraDynaset1 =
OraDatabase1.CreateDynaset("select * from agency where agency_id=" & Request.Form("agency_id") & "", cint(0))
After completing the project and trying to migrate the same to my box
which has Windows XP i had issues with the connection string. Then i googled and found the connection string with ADODB.
The connection string is
set objConn = Server.CreateObject("ADODB.Connection")
objConn.open "dsn=permitdb;uid=permit_user;pwd=permit_user; "
Set OraDynaset1 = objConn.Execute("select * from user_name where username LIKE '%" & Request.form("username") & "%' and password LIKE '%" & Request.form("password") & "%'")
This is working fine if its only for readonly queries. However if i have to either update a table or add a record to a table its bobming saying there is a possible locking error.
Please help me regarding this .
I appreciate your help in advance..

Form help needed for noob please!
&nbsp(324 Views)
I recently updated one of my sites but unfortunately the send email asp page no longer work does anyone have any suggestions the code is:
"" Then
strBody = strBody & " " & Request.Form("_housenumber")
End If
If (Request.Form("_postcode)) > "" Then
strBody = strBody & " " & Request.Form("_postcode")
End If
If (Request.Form("_number1")) > "" Then
strBody = strBody & " " & Request.Form("_number1")
End If
If (Request.Form("_number2)) > "" Then
strBody = strBody & " " & Request.Form("_number2")
End IF
If (Request.Form("_email")) > "" Then
strBody = strBody & " " & Request.Form("_email")
End If
strBody = strBody & "E-mail: " & strReturnEmailAddress
'Check to see if the user has entered an e-mail address and that it is a valid address otherwise set the e-mail address to your own otherwise the e-mail will be rejected
If Len(strReturnEmailAddress) < 5 OR NOT Instr(1, strReturnEmailAddress, " ") = 0 OR InStr(1, strReturnEmailAddress, "@", 1) < 2 OR InStrRev(strReturnEmailAddress, ".") < InStr(1, strReturnEmailAddress, "@", 1) Then
'Set the return e-mail address to your own
strReturnEmailAddress = strMyEmailAddress
End If
'Send the e-mail
'Create the e-mail server object
Set objJMail = Server.CreateObject("JMail.SMTPMail")
'Out going SMTP mail server address
objJMail.ServerAddress = strSMTPServerAddress
'Senders email address
objJMail.Sender = strMyEmailAddress
'Get the senders e-mail address
'objJMail.Sender =strReturnEmailAddress
'Senders name
objJMail.SenderName = Request.Form("_fullname")
'Who the e-mail is sent to
objJMail.AddRecipient strMyEmailAddress
'Who the carbon copies are sent to
objJMail.AddRecipientCC strReturnEmailAddress 'strCCEmailAddress
'Who the blind copies are sent to
objJMail.AddRecipientBCC strBCCEmailAddress
'Set the subject of the e-mail
objJMail.Subject = "Individual Voluntary Arrangement (IVA) Enquiry from www.ivahelp.org.uk"
'Set the main body of the e-mail (HTML format)
objJMail.HTMLBody = strBody
'Set the main body of the e-mail (Plain Text format)
'objJMail.Body = strBody
'Importance of the e-mail ( 1 - highest priority, 3 - normal, 5 - lowest)
objJMail.Priority = 3
'Send the e-mail
objJMail.Execute
'Close the server object
Set objJMail = Nothing
%>
I would really appreciate any comments.

Including files ... help please
&nbsp(248 Views)
...
ok ... i have a big problem with my asp code ...
so ... i'm doing on a page that has to collect some data from database (mysql) ... i'm trying to do that with include file script ... so that's the code:
edit.asp
Code:
here comes the table with all the data from TEST database
And this is connect.asp:
Code:
Ok ... all databases that are mentioned exist so that's not the problem ...
the problem is:
Error Type:
ADODB.Connection.1 (0x80004005)
SQLState: IM002 Native Error Code: 0 [DataDirect][ODBC lib] Data source name not found and no default driver specified
/podljubelj/test/edit.asp, line 9
I have this problem only with collecting the data from database ... it's strange that everything works on the asp page that writes data to database ... on that page I also include file connect.asp and everything works properly ...
so ... help me please ...

need help with server address? used on my webpage
&nbsp(187 Views)
i created an application that streams from a server but my problem is on my server there quiet a few drives for eg drive m,u,f,g,h right and lets say my ip for my server is 123.34.0.1 for arguements sake right
1. i have some audio on the u drive and i want to retrieve it how would i do this
i tried http://123.34.0.1/recordings/ken.wav................i tried that since the ken.wav is located on u:/recordings/ken.wav

I need help...
&nbsp(229 Views)
I think the flu (or what ever it is I have) is winning. My head is swimming and I can't think straight.
What I need is very simple. I have an ecomm site and want to offer multii level volume discounts. They enter a code in a form field and I check the discount code value and the order total and calculate the discount (this will happen during the check out process.
I want 4 levels:
"SAVE5" = 5% discount on orders over $500
"SAVE10" = 10% discount on orders over $1000
"SAVE15" = 15% discount on orders over $2500
"SAVE20" = 20% discount on orders over $5000
I can get one to work but can't seem to get the others. I have tried a series of IF, THEN's... amnong other things. Please take pitty on me and my sickness
Code:
GiftCode = Request.Form("GiftCode")
If GiftCode = "save5" Or GiftCode = "Save5" Or GiftCode = "SAVE5" And runningtotal > 500 Then
discount = runningtotal * .05
End If

ASP Ad rotator help "open in new page"
&nbsp(161 Views)
i have created a Ad rotator and have problem with the ad opening up in the same screen as my site. Can anyone tell how to make it open in a new screen. Code example below.
Redirect AdRotatorRedirector.asp
Width 250
Height 70
Border 1
*
/html/images/timber.gif
http://www.timber.com
50
/html/images/wood.gif
http://www.timber.net
50

Need help adding and deleting from query data from list box
&nbsp(255 Views)
hello all,
ive developed a list box in asp to query from the database and list the data
i can post the whole file if you like
ive created one for adding and one for deleting;
thankyou again for the members who helped me last week please dont turn off your computer and run.
im getting the following error when trying to add
Error Type:
Microsoft OLE DB Provider for ODBC Drivers (0x80004005)
[Microsoft][ODBC Microsoft Access Driver] Cannot update. Database or object is read-only.
/copy/save.asp, line 40
line 40 being rsSubject.Update
Code:
Save Subject

Ive tried and tried to get my work working, someone please help me
&nbsp(218 Views)
i need serious help here
im using session varibles on each page
from login.asp it goes to verify.asp once StudentNO and Password are verified it goes to frames.asp
i had this working at one point now everything has gone wrong
supposdily this is it how it goes,
login to verfiy, verify checks login details
and then once verfiy works it goes to frame.asp
frame, asp displays the student details as seen in my code
middle frame it displays the subjects students have taken
there add and there delete using a list box, iv written the code to populate the list box with a query
add.asp views the students hasnt taken
delete.asp views the subects the student has taken and wants to delete.
from there once add or delete has been presses it just reloads the page with the update.
i dont know how to 'update' anything as you can see
ive tried to load these pages invidually without session varibles and still cant anything to display.
if some one would be so kind to look at my work and fix or let me know how to fix it it would be great help
im seeking any assistance please look at my code and guide me and help me. ive done the code and need some help the only thing i havnt done is the adding to the database and deleting from, so please im not trying to to get anyone to do my work just please please help me.
kindest regards
kn

ASP String function help
&nbsp(180 Views)
I'm looking for a string function to take a url and pull out the word between the dots, for example the url http://www.example.com would return the word example. The only criteria is because I don't know how long each url is I need to extract the word between each dot.

Image cropping help
&nbsp(192 Views)
Hi
I am not a great expert with ASP but have had a website made for me using it. It is a jewellery website for my new business and when selecting an item of jewellery an image is loaded on that page. The problem i am having is that occasionally that image is cropped to the wrong size. The website is www.emjems.co.uk. This only seems to happen in Internet explorer. Can anybody help me

Sql help, where statement
&nbsp(190 Views)
I am trying to retreive teams from my database where their ID is equal to tid (querystring). I am using the sql code below to try and withdraw these results in the way I want them from the database but it isnt working:
Code:
Dim rsHomeT
SET rsHomeT = Server.CreateObject("ADODB.Recordset")
rsHomeT.Open "SELECT * FROM Fixtures INNER JOIN Teams ON Fixtures.HomeTeamID = Teams.TeamID WHERE Fixtures.HomeTeamID = " & tid & ";", objConn
Dim rsAwayT
SET rsAwayT = Server.CreateObject("ADODB.Recordset")
rsAwayT.Open "SELECT * FROM Fixtures INNER JOIN Teams ON Fixtures.AwayTeamID = Teams.TeamID WHERE Fixtures.AwayTeamID = " & tid & ";", objConn
rsHomeT first selects everything from fixtures and then joins the fixtures.hometeamid onto the teams.teamid to get the name of the home team, but I want it to do this where the home team or away team equals tid (querystring) but am having difficulties. I also think that I HAVE to use 2 recordsets.
I thought of doing something like this..
Code:
Dim rsHomeT
SET rsHomeT = Server.CreateObject("ADODB.Recordset")
rsHomeT.Open "SELECT * FROM Fixtures WHERE Fixtures.HomeTeamID = " & tid & " OR Fixtures.AwayTeamID = " & tid & " INNER JOIN Teams ON Fixtures.HomeTeamID = Teams.TeamID ;", objConn
but I recieve errors.

help: Incorrect syntax ........
&nbsp(252 Views)
hi,,
I keep getting this error msg although the code was working fine the first few times I tested it !!!
Error Type:
Microsoft OLE DB Provider for ODBC Drivers (0x80040E14)
[Microsoft][ODBC SQL Server Driver][SQL Server]Incorrect syntax near the keyword 'order'.
/example_select.asp, line 123
I have checked the syntax several times but for me it looks OK !!!!!
any idea
any help please
the line 123 is the line highlighted in RED COLOR within the code I am posting.
Code:
selectbox1:
selectbox2:
textBox3:
example_select.asp

ASP sql query help
&nbsp(211 Views)
Hi ,
New to asp. I'm doing a simple login system for a school. I've students id and password in a table and teachers id and password in another table.
How can I query both tables and look for a match from the given asp login form page. Based on the user type, the users will be redirected to respective pages.
Is it a good practice to do like this:
if
query table 1 ->
else
query table 2
your replies appreciated.

search help..
&nbsp(183 Views)
i have a textfield1 and a Search button, how can search field in database when i click the search button
can you give me a sample code or page of the search page

objFSO.DeleteFile help - Page 2
&nbsp(148 Views)
Hi ,
Sorry to bug you with this
Just wondered if anyone could explain that code in my last post below.... just a bit confused as to how I do it...
manyyyy

ASP DB Problems - i'd LOVE some help!
&nbsp(159 Views)
.
I am writing a page that will open a database, check the users IP and Request.ServerVariables("ALL_RAW") with copies in the database. Only problem is, when i try and read the _Raw field of the database, it returns nothing, yet when i look at the database itself there is the _Raw data, clear as anything. I dont understand why this record is showing up blank. the other records show perfectly. Anyway here is the code:
Code: