Drop-down menu menu back to the first item after submission

I created a search using the menu drop down.

The menu items are from a source of data (recordset), but after clicking on the button "submit" section goes to the first item in the menu dropdown. How can I keep the selection to the selected element?

Here's the code, I do not know where to add selected, eco

< option value = "<?" PHP echo $row_RSspeciality ['id']? > "<?" PHP if ($HTTP_POST_VARS ['id'] == $row_RSspeciality ['id']) {echo "SELECTED" ;}? > > <? PHP echo $row_RSspeciality ['field']? > < / option >

I have another question, how can I add an item (all) in the drop-down list, which allow the user to search in the entire Department?

You must match the values. If $_POST ['id'] does not exist, you can use any value is sent by the form. Judging by your code, it is the specialty (with a capital S).


Tags: Dreamweaver

Similar Questions

  • I have a new MacBook Pro 13 "." When you click on almost ANYTHING, I get a drop-down menu, rather than the simple task. This includes a link to closing a window, writing a message of openness. Whatever it is. I've updated to 10.11.2.

    I have a new MacBook Pro 13 "." When you click on almost ANYTHING, I get a drop-down menu, rather than the simple task. This includes a link to closing a window, writing a message of openness. Nothing, including the drafting of this issue. A screenshot is included. I've updated to 10.11.2.

    Thank you!

    Bill Koechling

    Is it possible that you accidentally tap the touchpad with 2 fingers?

    Try to go to the preferences system-> Trackpad-> point & click and disable the "Secondary click" item Or change one option other than water from the tap 2 fingers.

  • Drop-down lists lists loop until the first position when scrolling down

    Original title : Drop-down lists keep scrolling to the first position

    As soon as there is a drop involved or any time there is more than a list of what can be seen on the screen, something is causing the list to scroll to the first position.  It also happens on anything that uses a mouse to move a bar on the side, using keyboard does not help, she returned at the beginning.  Please, someone let me know how to solve this problem, I can't get anything done as much of what I do has lists in drop-down lists.

    Thanks for your help

    BlueFairy2012

    Hello

    1. the problem occurs with any particular application or all applications?
    2. don't you make changes to the computer before the show?
    3. what operating system is installed on the computer?

    I suggest you perform the clean boot and check if the problem persists.

    How to troubleshoot a problem by performing a clean boot in Windows Vista or in Windows 7
    http://support.Microsoft.com/kb/929135
    Note: Follow step 7 clean boot KB929135 article to reset the computer in normal mode.

    Additional information:
    The problems with the mouse button or scroll the parameters
    http://support.Microsoft.com/kb/303091

  • The drop down menu moves to the top instead of the bottom.

    I see a new kind of problems with PCMCIA. When I click on something that should give me a drop-down list, he sometimes "drops up to." It's like a Venetian blind in the sense opposite, I have my mouse programmed for single-click operation and simply maintained sometimed the muse button pressed for about one second "locks the drop in place. This is a minor annoyance, but it's always a surprise when a drop down menu "drops up to" when he has to stay down.

    I am rnning Win7 HP Pavilion PC onan; Any thoughts?

    Original title: remove the drop menus-doen - as if they were d 'ropping save '.

    Hi jcgiglio,

     

    Thanks for sharing this information with us.

     

    Glad to know that you were able to resolve the issue. Feel free to contact the Microsoft community for issues related to Windows in the future.

  • Drop Down Menu hidden behind the images on the page.

    I created a drop down menu of the page MASTER using a blank publication and adding the trigger on my menu tab.

    For some reason when I transfer to the server I get this error. The region appeared behind images.

    Help, please.

    Screen Shot 2014-11-19 at 5.05.05 PM.png

    Yes I know that's what it says in all the documentation and I've tried about 300 different ways, time and the only way that they work and have a menu pops down in front of a youtube video that has been incorporated into the page was to put this in a YouTube video embed code. I tried to reorder the items inside of the layers, I tried to create another layer, I tried all of the documented methods that I could find on the internet and on the site of Adobe Web and none of them worked except for this code. I know it says its supposed to work this way, but it never did for me

  • How to delete the history in the drop-down menu search in the middle of the Start Page?

    I deleted the whole history using clear all and restarted FF. The drop-down list search in the middle of the Start Page always displays all of the research I did in the past to him. How can I remove this from this search bar?

    What is the URL of the start page?

    You can remove the formhistory.sqlite file in the Firefox profile folder to delete all stored form data.

    You can use this button to go to the Firefox profile folder:

    You can delete all data stored in Firefox with a specific area through "Forget this Site" in the context menu of a history entry ("" history > view history "or" view > sidebar > History "") or via the subject: permissions page.

    Using "Forget this Site" will delete all data stored in Firefox in this area as bookmarks, cookies, words of past, cache, history, and exceptions, so be careful and if you have a password or other data from this area you don't want to lose so take note of these passwords and bookmarks.

    You can't recover from this "forget" unless you have a backup of the files involved.

    It has no lasting effect, so if come back you on such a 'forgotten' site, then the data of this Web site will be saved once more.

  • Drop-down menu? using the ActionScript 3.0

    More seriously, the answer is literally on the tip of my tongue, but basically my menu works but when I move my mouse over the menu, it doesn't go away :/

    at first, my problem was that the menu kept rereading without me even to ride on the button, so I put a stop action on the frame where the menu dropped down.

    Y at - it implementation code and where to put this code? on an invisible button or?

    Please let me know what you need to know to help me with this problem! If you need codes or screenshots - whatever it is, let me know if I can put it upward and solve this little problem!

    You can make use of the mouse over the event in AS3.

    Open the Code Snippets Panel in the Windows menu and navigate to Actionscript > event handlers > mouse over event to verify its use.

  • I can't get the drop down menu to change the columns in the media

    Using first Elements 10, no matter where I right-click, I can't drop-down list that contains "Edit Columns".

    Have you passed to the window menu and choose to display host headers?

    Once you have done this, simply click on the > dropdown at the top right of the project Panel.

  • Populating a drop-down menu form with the values from MySQL database

    I'm creating a simple CMS that will allow staff to add new items on their site (sale of furniture).

    I want them to be able to choose from the list of values for some fields to ensure that the items are displayed on the website correctly (IE to avoid typos etc.).

    I have spent a lot of time to trawl forums and have so far obtained the code below.  When it was working I could only get the dropdown menu options of data contained in the database, as opposed to the list of DEFINED values that initially, I would put in my database.

    For example under the field named 'Type', I assigned these values: all ('table', 'chair', 'buffet', 'convenient', 'bottles', 'library', 'mirror', 'drawers','s chest', 'display', 'tvunit', "bedside", reads, "wardrobe", 'dressingtab', 'blanketbox', 'Office', 'filing cab', "workstation")

    Here's what I want to display in the drop-down, not only the five values of elements already in it.

    However, my CMS page is nothing display now not in the drop down and I can't understand why not!

    So my question is, first of all any ideas what's wrong with my code?  And second, how to fill the bottom of the fall with SET values?

    Thank you very much in advance for your help!

    I didn't want to bore you, then the code below is just the bit that is relevant to my question, rather than any connection $POST and info php etc.

    It is in my code php at the top of my page

     $sql = mysql_query("SELECT DISTINCT id, supplier, room, type, material, finish, bespoke, image FROM furniture ORDER BY ASC");
    
                        while($row = mysql_fetch_assoc($sql))
                        {
                    $supp .= "<option value=\"{$row['supplier']}\">{$row ['supplier']}</option>";
                    $room .= "<option value=\"{$row['room']}\">{$row['room']}</option>";
                    $type .= "<option value=\"{$row['type']}\">{$row['type']}</option>";
                    $material .= "<option value=\"{$row['material']}\">{$row['material']}</option>";
                    $finish .= "<option value=\"{$row['finish']}\">{$row['finish']}</option>";
                    $bespoke .= "<option value=\"{$row['bespoke']}\">{$row['bespoke']}</option>";
                        } 
    

    It's in my html code

    <form action="<?php echo $editFormAction; ?>" method="POST" enctype="multipart/form-data" name="form1"  id="form1">
    
                    <label for="supplier">Manufacturer</label>
                    <select name="supplier" id="supplier" title="<?php echo $row_add['supplier']; ?>" >
                      <? echo $supp; ?>
                     </select>
           
    
                     <label for="room">Room</label>
                    <select name="room" id="room" title="<?php echo $row_add['room']; ?>" >
                      <? echo $room; ?>
                     </select>
    
                           <label for="type">Type</label>
                          <select name="type" id="type" title="<?php echo $row_add['type']; ?>">
                           <? echo $type; ?>
                          </select>
       
    
                          <label for="material">Material</label>
                          <select name="material" id="material" title="<?php echo $row_add['material']; ?>">
                          <? echo $material; ?>
                              </select>
           
                              <label for="finish">Finish</label>
                          <select name="finish" id="finish" title="<?php echo $row_add['finish']; ?>">
                            <? echo $finish; ?>
                              </select>
       
                           <label for="bespoke">Can be made-to-measure?</label>
                           <select name="bespoke" id="bespoke" title="<?php echo $row_add['bespoke']; ?>">
                          <? echo $bespoke; ?>
                          </select>
    
                                  <input type="Submit" name="Add" id="add" value="Add" />
                          <input name="date" type="hidden" id="hiddenField" value="<?php echo $todayis['date']; ?>">
                          <input type="hidden" name="MM_insert" value="form1" />
                          </form>
    

    > So, don't you think not with my different approach?

    Yep, that's how it should be done.

    Note the OP also mentioned that they are filled with 6 drop-down lists:

    > 6 fields I want to post, drop downs in my a form are: provider, room, type of material, finish and custom.

    So you can create a table for each separate... but what I would probably do is store everything in a single table (depends of if you need to store additional information or if it's just a list of choice):

    optionsTbl

    Category ID value

    ------------------------------

    1 provider abc

    2 vendor xyz

    3 living room

    4 dining

    Enter values using a set of multiple records in the query: Select value of optionsTbl category WHERE = 'suppplier. " Select the value optionsTbl category = "room"; etc.

    Then fill the drop-down lists by looping through each query in the recordset and use next_result() to perform a loop on the next game.

  • I have a drop down menu that lists the locations for the food.  I would like to create a javascript entry that says that if it is a special place that it is in building b... another place would show building c... so on and so forth.

    I'm setting up a work order system.  We have food on campus locations and I would like an entry javascript if it is in a certain place of the food, then it is in the building one.  If it's somewhere else, it is in the b building.  So I have the location of the food menu drop-down.  And I list building sites.  So, I was wondering if we could use Javascript or an action script to make this possible.

    Yes, it is possible to do it with JS. I developed a tool that does it for you (I can provide more information in private, if you're interested), and there is also some information here:

    https://acrobatusers.com/tutorials/js_list_combo_livecycle

    https://acrobatusers.com/tutorials/list_and_combo_in_lc

  • Use the drop-down menu to set the value of check boxes

    Hello everyone, I am using a drop-down list field in a form to also check or uncheck the different boxes, based on the value. I'm looking for something like the following:

    f = this.getField (event.target.name) .value;

    g = this.getField ("Checkbox1");

    h = this.getField ("Checkbox2");

    If (f is 'Value1')

    {

    g.Value = true;

    h.Value = false;

    }

    on the other

    {

    g.Value = false;

    h.Value = true;

    }

    and so on. It works the way I want. This is probably a simple syntax or a thing of terminology. Can someone advise? Thank you!

    The value of the boxes is not true or false, but one channel (either 'Off' or the value of exports).

    You can also set the like this, but:

    this.getField("Checkbox1").checkThisBox (0, true); check one

    this.getField("Checkbox2").checkThisBox (0, false); to clear a check box

    Edit: fixed the code

  • Drop-down menu is hidden behind the elements

    Hello

    I have a right to 2 containers after another. Drop-down menu is in the first. When I want something to choose in the drop-down menu, he hides behind the elements in the second container.  How can I make this drop in the front, when the seecting elements?

    In my application, I also noticed that when I didn't use a drop-down list ScrollView did disappear after the elements below the drop-down list. Then when I used a ScrollView around all elements, it has been resolved.

    A drop-down list in cascades infact do not come on the top items. It expanded just himself and all the elements under the menu drop-down get pushed down. When the bottom is reached, items below, that the drop cannot be pushed more, so the drop-down list will appear behind items.

    When you use a scrollview, the items in the drop-down list may get pushed too far below is necessary because the window is not limited to the screen.

    I hope that was a little bit useful.

  • Drop-down menu auto-remplit but will not be updated if you change the selection?

    Hi all

    I'm having a problem with the auto fill to a text field based on the selection in a drop-down list. While the script is running in the first case, if I go back and change my selection as result calculations be updated based on the new selection.

    I used the following script Auto Fill a field of text (called "stndwatt") based on the drop-down menu selection. The drop-down field is called "ProductLineOne":

    var v = this.getField("ProductLineOne").value;

    If (v == "3000K T10 (Tube) '") event.value = "21";

    else if (v == "4000K T10 (Tube) '") event.value = "21";

    else if (v == "5000K T10 (Tube) '") event.value = "21";

    else if (v == "6000K T10 (Tube) '") event.value = "21";

    else if (v == "HBZ (100W Bay)") event.value = "100";

    else if (v == "HBZ (150W Bay)") event.value = '150 ';

    else if (v == "HBZ (200W Bay)") event.value = "200";


    The text field ("stndwatt") is actually hidden and is only required to be part of other subsequent calculations - I don't know if this is a factor?


    If you can please advise what I can do to make the field to update when a new selection is made in the drop-down box, it would be much appreciated!

    I'm just a beginner so please keep this in mind

    Thank you!!!

    You must make sure that the field calculation order is correct. See

    as it is a calculated field that is used in other calculations, you should

    Make sure it is higher on the list compared to the fields that use its value

    for their own calculation, that is to say that its calculated before them.

    You can set this order in form editing mode, via the game of - other - jobs

    Field calculation order.

  • Drop-down menu in the table of cells - how to develop across the width of column?

    Hello!

    A customer migrate their 2 400 forms of old JetForms as PDF (LiveCycle Designer) and would like to keep the same functionality, so that it is used in the old platform. However, some of the old tool features do not seem to be present in LiveCycle.

    Suppose that a drop down menu in a table cell, containing the elements whose lengths are larger than the column of the table. In JetForm, when you open the drop-down menu that spans the columns to display all of its content, do not cut the contents of the drop-down list.

    I tried this in LiveCycle, but the drop down menu gets cut and its content is limited to the column in the table (where the drop-down menu below) width.

    Is there a way to bypass this limitation, even if I use scripts?

    Thank you for all the ideas!

    Marcos

    Hi Marcos,

    I don't think you will get this works reliably in a table

    Niall

  • Drop-down menu and report queries

    Hi all

    I have a report query that print Information on a given employee's salary (it works fine). It was printed on a letter head of companies and to get it stamped properly. The letter is addressed to a particular bank (depending on the choice of the employee)

    Scenario:
    I have 10 banks that this letter may be addressed to (one at a time). Each employee has a choice by drop-down menu to choose the Bank they want this letter to be sent to the. and when he chooses for example. BofA. I want to print in PDF format also with his statement of salary.

    Even if another employee wants his salary for Chase Bank statement, it should select Chase Bank of drop down and the letter would be printed address Chase Bank.

    I can do this thing by the static bank names. But it would create 10 similar models each different bank name. But I don't want to. I want a model and value automatically feeding WRT my drop-down list of choices.

    I hope I am clear. Thanks in advance. Your help is appreciated.

    Hello

    First of all, you must make sure that the selected page, employee and banking, the elements have been registered in the session, so that it is available for use in the report. This can be done by using a Select list that submits the page for the two elements.

    The query itself just needs to be able to recover both the banking information and employee information. This can be done in the SQL statement:

    SELECT B.NAME, B.ADDRESS1, B.ADDRESS2, etc
    S.NAME, S.SALARY, etc
    FROM BANK_TABLE B
    INNER JOIN SALARY_TABLE S ON 1 = 1
    WHERE B.BANK_ID = :P1_BANK_ID
    AND S.EMPLOYEE_ID = :P1_EMPLOYEE_ID
    

    Andy

Maybe you are looking for