Write Positioning
Does any one know how I can position the output at certain point? Such as If I want to print "hello" starting at position 50 from the left in the file.
View RepliesDoes any one know how I can position the output at certain point? Such as If I want to print "hello" starting at position 50 from the left in the file.
View RepliesI managed to make This code works, in the sense that the <tr> are clickable, but the only problem is that it prints the first values (cat) on a separate column above the table.
code
<table align = center bgcolor = skyblue border = 2 width = 90%>
<%
while not rsTypes.EOF
Response.write "<tr style=""cursor: hand"" onmouseover = ""this.className='orangeThing';"" onmouseout = ""this.className='skyThing';""> <a href=""editfirstmarch.asp?cat=" & rsTypes.Fields.item("cat").Value &""" >" & rsTypes.Fields.item("cat").value & """ >"
Response.write "<td align = center >" & rsTypes.Fields.item("one").Value & "</td>"
Response.write "<td align = center>" & rsTypes.Fields.item("two").Value & "</td>"
Response.write "<td align = center>" & rsTypes.Fields.item
("three").Value & "</td>"
%></a><%
Response.write "</tr>"
rsTypes.MoveNext
wend
Response.write "</table></html>"
%>
I'm having trouble with an asp page. First off, I'm new to the html / asp world, but not to software development. I'd like to minimize or "normalize" the site, so I'm trying to use one menu page and include it into any page that needs the menu. The problem is, I include the header.asp page, include the menu.asp page, but when I write the body of the page, it sticks the text underneath the side menu.
I'd like the text to begin under the header (logo) but beside the menu on the left side of the page.The page that I'm working on is at ttp://www.hemmingway.com/default.asp.what I should look at or what I might want to try searching .
I'm having problems positioning results tables in ASP. Basically it's a catalogue site and I want to display 2 products side by side in rows of however many products there are in the category.
At the moment all items in the catagory are appearing side by side in one long row.....Can any one advise me what I'm doing wrong? Code:
i found a code for a menu which retrieves the links from a database, problem is i can't seem to position it properly on my layout.
at the same time, i want to make the asp codes external, so i can just include it in the areas i need it, which is the entire site.
i zipped a folder to make better sense... the sample.asp in menus folder, works fine on it's own, but the moment i placed it in the laid out page, the menu stays at top left and not on the navHeader layer that i want it to be in Code:
I was wondering whether having ASP pages hinders search engine positioning. I am soon to encourage submission and wanted to know whether recode some 'key' pages (ieindex.asp) to .html pages?
View Replies View RelatedI have 2 MS Access databases DB1.mdb and DB2.mdb.
In DB1.mdb there is a table named table1 and in DB2.mdb there is a table named table2.
How do I write query in ASP to write the records from table1 in DB1.mdb to table2 in DB2.mdb.
i am having a problem with ASP not doing the requestion action of Response.Write based on conditions of a code entered on a first page. The codes are below. I made the second page from template of another that yall helped me with and it aint working.. Code:
View Replies View RelatedWas curious if someone could help me out. I'm setting up a website and using Server side includes to make it easier for maintaining. I've got a contact form that will be included on several pages and I need to know from what page the forms is getting posted from. If I can figure out how to pass one value to a hidden field I can use the form as an include instead of hard coding the whole form into each page.
Ideally the value to be passed could be coded into each page then asp could pick it up and insert it into the hidden field. Any one point me in the right direction for accomplishing this. I don't have a clue about asp other than the basic include statement.
I select 'name' from the customer table.
Is it possible to write it into a cookie?
<%
Response.Cookies("customer")("firstname") = '" & objRecordset(NAME) & "'
%>
when I try to write the above using
<%
Response.Write (Request.Cookies("customer")("firstname"))
%>
i get the following ....
May i know isit can use asp to send an automail when customer fill up the registration form. i need to send a automail to his email verify the customer details. is it any free source code to write?
View Replies View RelatedI writing code that will create asp pages using the file system object.
<%
..
..
'other code here
Response.Write "<%sName=" & Var & "%>"
%>
How can I do this?
If my recordset is empty I want to write "Not Complete" and if there is
a value, I want to write the value. Can someone tell me what I am
doing wrong?
<%
If IsEmpty(rsa.Fields.Item("reclaima")) Then
Response.Write("Not Complete")
Else
Response.Write(rsa.Fields.Item("reclaima"))
End If
%>
Also tried....
<%
If rsa.Fields.Item("reclaima") = "" Then
Response.Write("Not Complete")
Else
Response.Write(rsa.Fields.Item("reclaima"))
End If
%>
Since ASP server scripts use VBScript by default, does it mean it is
redundant to put the following in ASP page? Then when do we need to use
this? In client-side VBScript?
I have a script in ASP:
If strReport = "OrderDetail" then
strReport1 = strReport & ".rpt"
End If
If strReport1 <> "" Then
strReport1 = strReport & Year(strPeriod) & ".rpt"
End If
Now based on the kind of value in strReport1, I would like to do 2 different set of work.... Like for instance,
If strReport = "OrderDetail" then
call SubReportDB
End If
If strReport1 <> "" Then
Call SubOrderDetail
End If
Is that the right syntax?
While doing a response.Write,
I would like to display the text as array item wrapped in quotes. How can I do that?
I write the code as:
'Now get all the sub-reports names to pass the log-on information
For i = 0 to UBound(aSubRpt,2)
Response.Write "webSource0.AddParameter " & u0 & " & " & aSubRpt(c_SRName,i) & ", " & dbd & "<br>"
Response.Write "webSource0.AddParameter " & p0 & " & " & aSubRpt(c_SRName,i) & ", " & dbc & "<br>"
'Response.Write aSubRpt(c_SRName,i) & "<br>"
Next
While seeing the results in the browser, I would like to see
"aSubRpt(c_SRName,i)"
which is primarily
"reportname"
How can I wrap the text in double quotes within a response.Write?
I want to be able to write a gif in my ASP app. Not even sure if it is possible with response.write. I want to replace the 'Member Log In' text with XXX.gif, and still have it linked to login.asp....
View Replies View RelatedI am trying to retrieve info from database and display it in the form. The problem I having is when I try to change the info in the form, it is not changing and I don't know why.
table.fieldname = payroll
Code:
payroll = rs("payroll")
If payroll = "something" Then
payroll = "Some Payroll"
End If
In the form table:
<input type="text" name="payroll" value=<%response.write(payroll)%>>
I want "Some Payroll" to be displayed in the form instead of "Something".
I need to put this whole line into a response.write statement:
field delimiter = """
Code:
<%
username = Session("username")
if ("" = username) Then
Response.redirect "login.asp"
response.Write("Sorry, you are not logged in.")
response.End
End if
%>
How do i write that Sorry, you are not logged in ... to the login.asp?
I've tried using a FSO to write to it directly. I've even managed to write a script for windows scripting host and invoke it from ASP, using standard output redirection (">") to redirect output to a file with no problems.
However, I can't seem to send writes to LPT2: from ASP, even through the other script.
It works perfectly fine if I invoke the WSH script at a command prompt using precisely the same command line, but when I do it from inside an ASP page, I get nothing.
Are there some permissions for the port I have to set or some such? I honestly have no idea how to get it to work.
If it is relevant, LPT2: is a mapped port for a network printer.
Yes, this is related to my previous thread, but I'm down to a much, much more specific problem.
Why do I get an error on executong the following code:
<body>
<%
Response.Write" <script language = ""vbscript""> "
Response.Write" res = MsgBox (""Do you want to edit appliance?"",4,""Edit Appliance"") "
Response.Write" if res=7 then"
Response.Write" window.location.href= ""Appliance.asp"" "
Response.Write" else"
Response.Write" window.location.href = ""Scenario.asp"" "
Response.Write" end if"
Response.Write" </script>"
%>
What is the right syntax, to make that a hyperlink?
Response.Write("<TD>"<a href=""rst("Kotisivu") & ">" & "</a"> & "</TD>")
I am trying to check for the final sql statement before passing it to a
database. I want to build the statement using user input in three text boxes.
However, the sql statement does not give me the right statement. Instead it
gives the following message:
Error Type:
Request object, ASP 0102 (0x80004005)
The function expects a string as input.
/sailors/loginverification1.asp, line 14
CODE:
<%
strSQL = "select PeopleNameFirst, PeopleNameLast, PeopleClubCode from People
where " & _
"PeopleNameFirst ='" & Request.Form(txtFirstName) & "' AND " & _
"PeopleNameLat ='" & Request.Form(txtLastName) & "' AND " & _
"PeopleClubCode ='" & Request.Form(txtPassword) & "'"
Response.Write strSQL
%>
How to use Response.write to Output the following Code:
Type id="1"
I tried this one but not working Code:
Response.Write( "Type id="" & "0" &"")
I am creating html string in a component that transforms xml into html.
Works o.k. with small html strings, but takes forever to response.write
big html strings. Is it possible to speed it up?
I am having trouble trying to output an image using Binary.Write. I have a page which displays a record. One of the fields is an image and I want to display this on the page.
My question is this: Is it possible to use the Binary write command i.e. Binary.Write("MyDatabaseField") on the same page that I want the image displayed on?
If not Is there a way to nest it inside an image tag as follows:
Response.Write("<img src=" & binaryWrite("mydatabasefield" & ">")
I have an asp page created in Dreamweaver with a form that is supposed to write to an Access database. It redirects to a formmail.asp that sends the info to my email. Everything works except the fact that no new info is written/inserted into the database.
I can connect, read, etc, it just doesn't write anything new. I get the email just like I'm supposed to only it has old entries and nothing new. There's nothing new added to the database when I check it. I've tried about everything I can think of. I've checked and double checked that the file can be written to, added all the default users, etc. Moved the file around, recreated the database, etc. I'm using DW 8, Access 2003 and Windows Server 2003. Code:
Now i have this part of the code . below in the code i should not call Sp_Getattachment if the Id = 0
but sme how I am gettin an error if I insert the If statemnt.
This is the part of the code:
I have a specific access db field that holds visitor website url's and I am currently displaying it onto a page as text but instead I need it to be displayed a clickable hyperlink.
The field datatype within access is set to url but when the entry is written to an asp page it doesn't bring the hyperlink properties with it.
I think I should be enclosing the RS within an <a href=''></a> type tag but can't seem to get it right.
Current code: Response.Write RS ("website") & "<BR><BR>"
Example 1 don't work:
title = rs.("title")
response.Write title
' this will show title= "the 100 Club"
SQL2 = "select * from events where (venue = '"&title&"');"
rs2.Open SQl2, Conn
' Either BOF or EOF is True, or the current record has been deleted.
Example 2 it work fine
title = "the 100 Club"
SQL2 = "select * from events where (venue = '"&title&"');"
rs2.Open SQl2, Conn
it work fine, so what I hove done wrong with the first one it seam strait forward..
I'm just getting started in ASP and would like to better understand how to write cookies with ASP.
Most of the examples I've worked through involve collecting user info from a form and then using response.cookies (cookiename)=" some value"
What is the best way to write a cookie to the client if you're not collecting user data from a form?
What information is possible and most useful to obtain from the client if they haven't filled out a form?
1. Files to be browsed
2. Anonymous upload to this directory
3. Allow uploaded files to over-write the existing file
I use the following to create new folders, but all above options are off.
Set fs = CreateObject("Scripting.FileSystemObject")
set b = fs.CreateFolder(newFolder)