Do you think it's posible to DISABLE a checkbox and the value associated with it, based on the DATE apearing in one of the columns in my database? Example,
I will loop through a list of series of products from my database, and I will put an automatic checkbox infront of any row in my form. I want ASP to automaticly disable the checkbox (can't be clicked on) if the date associated with it is older than 3 years.
i ve a problem thats regarding the data retrieval from database.I m storing data in the microsoft access database by writing query in the asp page..and the number of characters is exceeding 255.so the datatype that i ve chosen is memo... but now when i want to retrieve the data on another page by writing query i cannot retrieve the whole data it is truncating and i can get only 255 characters
where level means the type of grade a person has like A,B it may even be Numbers on a scale of 1 to 5
the sno is declared as a rowid datatype if i want to update any record i have to give the existing userid ( primary key ) and even update the primary key if there are no duplicates (obviously)
so when the userid is entered i am selecting the rowid where userid = request("") and storing that rowid value in a variable to perform update operation in the next few steps
i am getting a type mismatch when i am doing the assignment
is there somethin wrong in the code ( that i need to check again ) or that sort of assignment cant be done ( i am still tryin to get it right as i write this thread )
i have one more ques: does the rowid value remain constant that is when i do a delete operation on one row and then subsequently a update operation on another row in the same table will the rowid's get mixed up and mess up my data.
Is there a way to perform multiple actions on a SUBMIT with ASP? Example, I have a submit button that when it is pressed, it performs an action where information is stored in the database using a stored procedure. Can I also write out a flat file of the information saved separately or something parallel without hendering the original submit? I would want to do these two requests at the same time on the submit. Is it possible? Can someone give me some guidance on this?
currently i have an online shopping website that display 12 categories of different items of up to 12 types. well my boss wants related items to be displayed in each of the different items . i am not sure how to start this. is there any special code for it. please advise.you may visit www.mellon.com.sg/shop to view .
I have 2 web sites hosted on 2 different machies (pages are in classic asp). when the user accesses http://Machine1/testapp then a cookie is written say
Response.Cookies("user")="Alex"
Whe the user acceses http://Machine2/testapp then a cookie is written as
Response.Cookies("user")="Alex"
before machine2 writes a cookie I need to check if the browser already hase Machine1 cookie, if yes then dont write if no then only write. I know the different hostnames generate different cookies....but is there any way for machine2 code to check client browser cookie for machine1.
Access db, one table, 12 or so fields (id, item_name, category, manufacture, price, description etc.)... (ecomm site).
When displaying the details of a particular item I want to display "related items" below it. All I do now is pull info depending on the item id then display the size, dimensions, description, photo etc.
Lets say the item is a Large Blue Widget, i want to display related items... say "Large Widget Covers" or/and "Large Widget Accessories"... you get the idea... cross selling
So, I am looking for ideas on how to simplify the display of related items.
I am designing a Web site with about 500 - 600 pages of festivals on it and would like opinions on two ASP subjects. I have designed about 20 pages or so as of now. These are the contact us, FAQ, about us pages and such. I also have a template to go by for each festival's page. But I have two problems I need fixed before I start to replicate.
(1) SSI and styles - There are four sections to each page. I use SSI (ASP virtual version) for the top, bottom and a small section of featured festivals (which is above the bottom) on each page. Between the top and featured festivals is the actual page. This way I can change a link on the top or bottom and it is fixed on all pages.
But, I have an enormous amount of styles listed (all styles on four pages) in the code from each page's fonts. Each page's styles are called something different. For example, the festival page itself has the styles as normal, ".style1." But the styles on the top the links, which once again is an ASP include, would be called ".style1top." I used that approach because .style1 on the festival page and top links could be different.
It works, but I have dirty code and I want the site to be as Google friendly as possible. I have thought about adding all the styles to a page and using it as an ASP include on all pages, but that would have way too many styles each page and be even dirtier. What is the best practice for this? Code:
Syntax error (missing operator) in query expression ''087,'1075654'
This is a mobile number I entered in a form. 087 is the cusMobilePrefix, 1075654 is the cusMobileNumber
why is there a double quotation mark at the beginning of the number and none at the end? I dont get it. If i leave the ' in i get a data type error and if i leave them out i get the above error. Below is my ASP file: Code:
When adding i am checking if that name already exists in the DB and if so i am poping up the message that name already existing.
It is working perfectly in my win2000prof and i have tested in both in my localhost and ftp servers and in both places it is working as i ahve expected.
But when the same application is opened in winxp i have a strange problem coming. When i add a new list , then it checks for the name and what happens is every time i add a new one and even if there is no matching record or matching name avialable for that record, javascript popups saying "Favourite List Name Already Exists" and the strangest part is the insert part also working. That is both if and else part are working together. I am getting this problem only in XP. Code:
while using <form method=GET> whats the max length we can send in the input fields? i heard that max querystring length is 2048 characters.while using forum with POST method its nearly one lakh characters.since GET method is treated as querystring, does it restricts the huge data?
I have a MS Access database composed of a few related tables. I'm trying to link this with a website so that new data may be entered remotely via the website. I am using MS Frontpage, which has a simple wizard for this, but the wizard does not allow for updating multiple tables from the one web form. I have started learning ASP and VB, but all the books don't really discuss adding records to several related tables at one go. How do I do this?
Conceptually, I understand that you can't have a new record in the child table without a corresponding record in the parent record. It there a way of submitting several forms to the same record by 'indicating' which parent record each field is linked to? Is there a simple scripting code ? Any help or suggestion will be greatly appreciated, or just point me to where I might find the information I need?
I have a timesheet application I'm working on. The user fills in a form which sends data to an Access db. On the results page I need to display the values from 2 fields; i.e if the user selects "Report Writing" from a drop down list, I need the data contained in another column called 'Codes' to display as well.
What i'm looking for is an asp function which automatically runs every day at e.g. 12:00 AM and then updates a database. So no user or external event is involved to trigger the function. It operates stand alone. Hope there are some code examples available.
We are working on an old asp project and we noticed that some users get kicked out of the session right after they log in.
I investigated the issue and I found the cause: 1- The user login successfuly. 2- He gets redirected to the menu screen. that's when I set some cookies to cookie("cookie name").expires = Now. that when the session starts to disapear, once the user tries to access other pages (or even refresh), the ASPSESSIONID cookie disapears.
I did some debugging on the http_cookie collection and looks like the ASPSESSION disapears once I set the cookie expiration, although I set the expiration for cookies unrelated to the ASPSESSIONID.
Here is the tricky thing, it works on 90% of the machines, and it doesn't on other machines, it's also random, so some users who had the problem, are now able to work on the system and the problem disapeard.
Have you guys ever had this problem, or do you know if it is related to IE batches or service packs?
I am relatively new to ASP but am fairly familiar with PHP and ASP.NET and JavaScript.
My problem is this:
I have a drop down box which is populated from the database (Access), it sets the value to the ID of a hospital ward, and the text to the name of the ward.
I then use the ID to look up an email address for the manager of the ward from another table in the database. My un-optimised code is as follows: Code:
I am developing a simple booking system where I had a booking date. The problem is I want to make sure that the user must book 3 days in advanced for certain room.
I have tried to use DateDiff but it seems doesn't work. Actually i just 1 to make sure that the user must book 3 days in advanced from the current date. I am wondering whether there is anything goes wrong in my datediff function. Code:
i'm new here and i'd like to ask if there's someone who knows how to compare date() function and date from database with date/time type inside select statement so i don't have to do if..then..else
In my page i have two combobox. one for year and one for week numbers.Now my prob is
1.when i select a year from combo box 1, second combox box will display the number of weeks in that year.eg if i select 2005 it display me list from 1 to 53 as there are 53 weeks in 2005.
2.when i select a weeknumber from combobox 2 and press submit button it ll display start date and end date of entered week.
I am trying to compare two dates. My problem is no matter what the value of mydate, it is still fall in the first IF statement condition (even if mydate is 10/10/2004). Any advise for this matter?
mydate = "6/6/"&year(date) IF date() <= mydate THEN response.write "first half of the year" ELSE response.write "second half of the year" END IF
I am trying to construct an SQL statement that can grab all of the entries out of a table, where the Date field consists of today's date. The Date field is called 'DateTime' - and it is in a General Date format (DD/MM/YYYY HH:MM:SS). I obviusly want to use an SQL statement like this:
SELECT * FROM tblExample WHERE (DateTime = Date());
However, that wont work because Date() will only return a short date (DD/MM/YYYY).
I would like to modify this so that the first available date that can be selected is five BUSINESS days out. The script only shows Mon-Fri so if the date is Tue Jul 13, 2004, Tue Jul 20, 2004 needs to be displayed. Code:
I am trying to compare a date in my database to the current date. MySQL statement is:
sqltemp5="select * from users where dateclosed <= '" & date & "'"
What I am trying to accomplish is exclude records where the dateclosed field is older than todays date. Such as if dateclosed = 6/30/2004 then today being 08/25/2004 that record should be excluded.
sql3 = "SELECT DISTINCT State FROM Property Where TypeID = '" & srch_cat & "'"
In the database, is a field called expiredDate I am trying to show only records whose expiredDates are greater than todays date, but I am messing up somewhere. The values in the fields are as this: 3/7/03 (or something like that...no time is added to it)