Posting A Value For A Field In Select Option

I have an ASP admin script where I'm adding records, and I have a
category that already has set name values hard-coded into a selct option
pulldown, but if the user wants to create a new category and not use the
select pulldown, the value will end up being " , newvalue" when posting
from this sequence of pulldown and input text box:

<select name="CategoryName">
<option selected></option>
<option value="first">first category</option>
<option value="second">second category</option>
</select>
<br>
New Category<br>
<input name="CategoryName" type="text" size="26"
maxlength="255">

What is the best way of not having that extra preceeding comma appear as
the value if the user chooses to add a brand new category?

View Replies


ADVERTISEMENT

Posting A Selected Option (drop Down List)

I cannot get the selected option to be POSTed (it does not appear in the
QueryString when using GET neither)

I construct the drop down list from an array, I select an element in the
list, I POST using a submit button. When I use Request.Form("NAME") it's
always empty. Is the selected item is Posted? How to retreive it?

Response.Write "<SELECT NAME>"
for i = LBound(aRessource, 1) to UBound(aRessource, 1)
Response.Write "<OPTION VALUE=" & i & ">"
Response.Write aRessource(i, 0)
next
Response.Write "<OPTION SELECTED>"
Response.Write "</SELECT>"

View Replies View Related

Option Select

i have a list of provinces in an option select right, so when i click one province i want it to chance the header of my page according to the provinces, and i have no idea on how to do that.

View Replies View Related

Select/Option

I have loaded a combobox (select) with a recordset from SQL Server. I am trying to accomplish two things, so I will break them up.1) Is there a way to allow the user to enter as many characters in the dropdown menu. For example, if you have serveral options in the dropdown menu that start with A, they can key in app.. to got to apples, instead of entering A and then having to keydown or click on the dropdown menu.

Granted there is a solution to #1, could you also allow the user to key information and if it is not apart of the dropdown menu, insert the value back into SQL (kind of like an notonlist event in Access).I have googled this and can't find anything, probably wrong keywords used.

View Replies View Related

Select/Option

i just want to ask on how will i load the other version of file written in another language (e.g Japanese)upon selecting that particular language from the option box. Like for instance the options are English, Arabic, Japanese and so on...then upon choosing the Arabic language, the page that contains an Arabic language (layout and data)will be displayed.

View Replies View Related

Forcing Option Select?

I am trying to force the last option selected in a drop down!, I basically have a page with a drop down box in which sends to itselfs when selected, the idea is
the selected value updates a postage amount depending on the country selected from the dropdown.

However when it returns to the page it defaults back to 'select country' and I would really like it to be able to display the option selected as this is part of the address form.

the relevant country is correct, and i am putting that into a request.querystring so this variable (destination) is available to test/compare against and maybe force select this way, but i just don;t know how to write the asp/html to make the select value go to either this variable or the last one selected. Code:

View Replies View Related

Select Box Option Values

I am creating an application in ASP (old school ASP not .NET) and VBSCRIPT connecting to a SQL Server 2000 back end. There is a form on my webpage that has a select box in which <option> tags allow users choose a document type.

Once the document type is determined it is sent off as a parameter in a stored procedure on the databse. The recordset returned holds the values that are required to go in another set of options boxes.

(the next set of option box values depend on the query results). I know it sounds easy...I mean I know how to do it if it where on 2 seperate pages (thats easy) where it passes on the info...but this is for ONE asp page.

View Replies View Related

Select Name With Option Function

Is there a possibilty to use the function <SELECT NAME="user"><OPTION>user 1</OPTION></SELECT>
from a database. I want to get the data out from a table and store the data from that column in a dropdown box. What's the way to do this ?

View Replies View Related

Request.Form Select Option

I am trying to retrieve option values using Request.Form as you do for textboxes! The textboxes work fine... but I can't get it done for select options.

View Replies View Related

Drop Down Menu Select An Option

Is there a way to have a drop down menu where u can select an option from the menu or type in ur own??? I am using ASP and SQL

View Replies View Related

Select Multiple Option Not Working

I have a form search page with many field options but this one field I would like to select multiple options.

I have this on the search screen for my multiple field where I pull the list of options from my database: Code:

View Replies View Related

Option Based On Previous Select

How can I get a new Option based on a the previous select. When you select a room from selRoom (orange) I want the available equipment (red) that match on a foreign key (CampusID 'Not Displayed') to be displayed. Code:

View Replies View Related

Form SELECT OPTION Displayed Data

Is there a way to retrieve the DESCRIPTION in the following code from within the process.asp page without adding additional fields to the form?

<form name="myForm" method="post" action="process.asp">
<select name="Options">
<option value="1">DESCRIPTION</option>
</select>
</form>

View Replies View Related

Changing "selected" Option On Select Menu Dynamically?

I'm building a page to update an existing database entry. On the form to do so, I have a basic select option menu as such:

<select size="1" name="ColR" style="width: 115px">
<option value="FFFFFF">White</option>
<option value="000000">Black</option>
<option value="FF0000">Red</option>
<option value="FF9900">Orange</option>
<option value="FFFF00">Yellow</option>
<option value="008000">Green</option>
<option value="0000FF">Blue</option>
<option value="4B0082">Indigo</option>
<option value="9400D3">Violet</option>
</select>


I'd like to have the option that matches the current value in the database field display as the selected option. I know it's easy enough to manually force one option or another to be selected, but how could I change which one it is based on the database contents?

View Replies View Related

Select Highest Value For Each Field?

I've got a database that has 5 numeric values for each record. I'm trying to figure out how to have the records sorted alphabetically, but highlight the highest value in the table for each column. So in other words, the table shows up with one record in each row, with a total of 6 columns (the name plus 5 columns). I want the highest value in each column to be emphasized.

So the final product would end up looking like the code at the bottom of this message.

I've pulled the records from the Access database and am able to sort them alphabetically and get the table to appear. What I was thinking is that at the top I'd define variables that correspond to the highest record for each column. Then in the table code I'd set the colour of each cell using an 'if then'.

So I have 3 specific questions:

- Is that the best way to do it? I don't want the page to take 20 minutes to load because I'm overloading the server.

- how would you set the variables at the top of the page?

- how would you write the if then in the middle of the table to change the background colour of the cell if that value (or values, in case there's a tie) is the highest of all the records? Code:

View Replies View Related

Select Only The First Few Words Of A Record Field.

Say I have a field containig some text, for example: The quick brown fox jumped over the fence. How do I only show the first 4 words of the sentance, i.e: The quick brown fox...

View Replies View Related

SELECT Statement Pulls Field Names - How To Avoid?

I do a SELECT * from table command in an ASP page to build a text file
out on our server, but the export is not to allow a field name rows of
records. The first thing I get is a row with all the field names. Why
do these come in if they are not part of the table records? How do I
eliminate this from being produced? Code:

View Replies View Related

Freeaspupload: Retrieving Multiple Values From A Select Field

I'm having problems retrieving all the values from a multiple selection field using the freeaspupload component.

I'm creating an online email app that uses the freeaspupload to add attachement functionality, which means the form encoding type is multipart/form-data. I've done something similar with the persits aspupload component, and had no problems with that, but the freeaspupload version seems to handle <select> fields slightly differently. Code:

View Replies View Related

Using Vbscript "SPLIT" Function On Multi-select Field

I am trying to split a mgrgroup field to extract the MD codes. It correctly grabs the MD codes if all records in a mass update are updated, but if only one record in the loop is updated then it puts the last 5 digits of the mgr name in the MD field.

THIS IS THE CODE: ....

View Replies View Related

Using Vbscript "SPLIT" Function On Multi-select Field

I am using the following code to split/join values in a multi-select field. It is combining all the values in All the records into one long string in each record in recordset.

Example: I have a recordset with 2 records. The 1st contains the split/joined values: Alan Smir, Jeff Karl The 2nd contains the value: Keith Robb

When it updates database, it will put Alan Smir, Jeff Karl, Keith Robb into each record in the recordset. Instead it should be putting Alan Smir, Jeff Karl into the 1st record
and Keith Robb into the 2nd record in the recordset.

Does anyone see what is wrong with the code ....

View Replies View Related

Select Statement Comparing Date() & Date Field Of Database

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

View Replies View Related

Posting To 2 Db's

I have a service request form in asp, which takes a bunch of data (name, id, etc). it then has 2 checkboxes, either or both of which can be checked to request a certain service. depending on which box is checked, the other data collected is inserted into a corresponding database. what is the best way to do this?

can i just use 2 IF statements (not nested) to open the connections to the databases?

View Replies View Related

Re-Posting

I'm building a wizard-type site and I have a form that has a fair amount of
information being posted page to page until it reaches the end where it has
all of the data from Page 1 - Page 5.
For future reference more than anything...is there a way to post all of the
data coming from a previous page to the next page? Basically I just wrote
out all of the values I received on each page into hidden variables and then
posted that to the next page every time. Is there a simpler way?

View Replies View Related

Posting

If you have an SQL error, response.write your SQL including all variables to the browser.
If I had a dollar for every error that could be fixed in about 15 seconds after doing this, I'd have like at least 15 bucks.

View Replies View Related

Posting To A Url

I have been left a set of instructions. One of them is to post an XML string to an address. I have my XML string, but how do I 'Post' it? I'm using ASP.

View Replies View Related

Posting The Value Of A Cookie

Is it possible to post the value of a cookie through a hyperlink?

View Replies View Related

Multiple Posting

i am trying to do Multiple Posting to different Server when
User post the Order form.
one to windows server
second to linux server
third to its own server

View Replies View Related

Posting Data To An API

I'm working on a shopping cart that uses PayPal when the user submits their information 3 things need to happen on the same page:

1. User information gets saved in a database
2. An e-mail is sent out
3. Variables are transferred via a "POST" method to the PayPal API

I've successfully made it through the first 2 but the 3rd one is killing me. How do I do this? The only way I can think to do this is with the response.redirect but it can't be a GET it needs be a POST. Any thoughts?

View Replies View Related

Posting One Form

My employer uses an onjline application for new hires. Currently they fill out a form which goes to ../cgi-bin/formail.pl
Of course this then email the application to them.
Once they recieve it it looks fine but when the go to print they say it prints 4 or 5 pages of garbly gook.
I havent seen this yet but i was thinking that if i could post the form to two seperat files, the fromail.pl and an asp page to insert it into an access table to later view with another asp page they could view the apps online and just print form explorer if i designed the page right
i have never done anythig with pearl before. Can I post it to an asp page then to the formail.pl. instead of posting it to two pages.

View Replies View Related

Posting Threads

I have a discussion forum that is working great, except that I just found out that if a person adds a reply to a thread, the thread just stays in place, weather or not if it's the first post or 7893th post. What I would like it to do is display the earliest thread, or the earliest thread with a reply at the top and work to the oldest thread. Right now it works only from earliest post to oldest post, not including the replies.

View Replies View Related

Posting Acceptor

I was using Microsoft Posting Acceptor to upload file on
web server(IIS 5) but after reinstalling my web server.
when i try to upload file it give me error
Http 405 - Resource not allowed.
I checked permission on all the directories and tried
after giving full permission but result is same
Also i checked mime extentions and found entry for .dll

View Replies View Related

Posting To Another Server And End Up There?

I have a login form on a page that should post the data to a non Windows
server and upon successful authentication, the browser needs to show the
secodn url.

I did the form post, got the successful results back but the browser is
still showing at the same url. Which method needs to be used so that the
browser shows the target url. In this case it's sURL in my code. sHTML is
the result from the successful result from posting the form to the non
Windows server.

As an example, imagine you want to put a Hotmail login form in your own
site, post the form using your asp.net code and the browser ends up inside
Hotmail showing a hotmail.com url.

Code Snippet:

Response.ClearContent();
Response.ClearHeaders();
Response.ContentType = "text/html";
Response.Write(sHtml);
Response.RedirectLocation = sURL;
Response.Flush();
Response.Close();

View Replies View Related

Data Posting

welll I'm using ASP 2.0 =)
I'm trying to do the automated form posting and submition.
What I got is Excel file with the data that I need to manually enter to
the form...
What should I use to maximumally automate it =)

View Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved