Results 1 to 6 of 6
  1. #1
    Join Date
    Jan 2010
    Posts
    130
    Plugin Contributions
    0

    Default Drop Down Problem

    Hi

    I made some changes in Registration Form, I added 1 drop down box Company Certification having 3 options
    1. I want to deactivate the Other Text Box when page is loaded
    2. If Other option is selected from Drop Down Box, Other Text Box get Activated
    3. If None option is selected from Drop Down Box, Other Text Box get Deactivated

    Please VISIT...

    And accordingly data should be stored in Database. I already created columns in database.

    Please help me, if any one

  2. #2
    Join Date
    Jan 2010
    Posts
    130
    Plugin Contributions
    0

    Default Re: Drop Down Problem

    More Detail
    I made changes in
    includes/templates/template_default/templates/tpl_modules_create_account.php

    PHP Code:
    <br class="clearBoth" />
    <label class="inputLabel" for="company_certification"><?php echo 'Company Certification:'?></label>
    <?php
            
    echo "<select name=\"company_certification\">";
                echo 
    "<option value=\"ISO2001\">ISO2001</option>";
                echo 
    "<option value=\"OTHER\">Other</option>";
                echo 
    "<option value=\"None\">None</option>";
            echo 
    "</select>";
    ?>

    <?php echo "Other:"?>
        <?php echo zen_draw_input_field('other_certification'''zen_set_field_length(TABLE_ADDRESS_BOOK'customer_company_other_certification''40') . ' id="other_certification"') . (zen_not_null(ENTRY_COMPANY_TEXT) ? '<span class="alert">' ENTRY_COMPANY_TEXT '</span>'''); ?>
    <br class="clearBoth" />

  3. #3
    Join Date
    Jan 2010
    Posts
    130
    Plugin Contributions
    0

    Default Just a simple help from you all Zenner

    Can any one help me just a simple

  4. #4
    Join Date
    Jan 2010
    Posts
    130
    Plugin Contributions
    0

    Default Is this so HARD to do...?

    I am waiting for last 7 to 8 days for reply from this forum, but till now no reply.
    Did I asked some thing impossible in Zen cart.

  5. #5
    Join Date
    Feb 2005
    Location
    Lansing, Michigan USA
    Posts
    20,021
    Plugin Contributions
    3

    Default Re: Drop Down Problem

    No, you're asking for custom coding that's beyond the abilities of many (probably most) here. Fact is, most people who can do that sort of programming do it for a living, so you might try the Commercial Help Wanted forum.

  6. #6
    Join Date
    Jan 2010
    Posts
    130
    Plugin Contributions
    0

    Default Re: Drop Down Problem

    Hi Stevesh

    I know this is not a easy job and this should be happening at client side, so either I have to use java script or ajax.
    I wrote a small java script also but don't know how to integrate in my code thats all
    Code:
    <html>
    <head>
    
    <title>Untitled Document</title>
    
    <script type="text/javascript">
    
    function change(val)
    {	
        if (val=="Other")
        {
    	document.getElementById("txt").innerHTML="<input type=\"text\" id=\"other\" name=\"other\"/>";
        }
        else
       {
    	document.getElementById("txt").innerHTML="<input type=\"text\" id=\"other\" name=\"other\" disabled/>";
       }
    }
    </script>
    </head>
    <body>
    <form name="f1">
    <select name="s1" onchange="change(this.value)" onchange="change(this.value)">
    <option value="ISO2000">ISO2000</option>
    <option value="ISI">ISI</option>
    <option value="Other">Other</option>
    </select>
    <div id="txt">
    	<input type="text" id="other" name="other"  disabled/>
    </div>
    </form>
    </body>
    </html>
    And you already saw my PHP code in previous Post.

    Thank you

 

 

Similar Threads

  1. Drop down problem
    By Rich108 in forum Templates, Stylesheets, Page Layout
    Replies: 1
    Last Post: 22 Mar 2010, 07:08 PM
  2. drop down menus problem!
    By digz in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 1 Nov 2007, 11:23 AM
  3. Subscribe Drop Down Option Problem
    By jsheena in forum General Questions
    Replies: 1
    Last Post: 16 Sep 2006, 04:45 PM
  4. css/drop down problem
    By mazzifer in forum Templates, Stylesheets, Page Layout
    Replies: 4
    Last Post: 20 Jun 2006, 05:54 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg