hy, I have next lines of code:
1.
      <form method="post" action="leadview.php">
      <select name="viewleads" onChange="this.form.submit(viewleads)">
        <option value="AOL">All Open Leads</option>
        <option value="MUL">My Unread Leads</option>
        <option value="RVL">Recently Viewed Leads</option>
        <option value="TL">Today's Leads</option>
       </select>
       </form>
2.
            <form method="post" action="<?"$PHP_SELF"?>">
            <div align="right"><font face="Tahoma" size="1">Select
One:</font>
              <select name="keyleads" onChange="this.form.submit()">
                <option value="My Unread Leads"<?if($keyleads=="My Unread
Leads"){
                        print "selected";}?>>My Unread Leads</option>
                <option value="Recently Created"<?if($keyleads=="Recently
Created"){
                        print "selected";}?>>Recently Created</option>
                <option value="Recently Viewed"<?if($keyleads=="Recently
Viewed"){
                        print "selected";}?>>Recently Viewed</option>
              </select>
            </div>
            </form>

both forms are in same page. second form it works fine without problems.
first form it works with one exception. If select "All Open Leads" don't
happend anything
For rest of values it works.
For example if select "My Unread Leads" I see page leadview.php.
What is it wrong?

kale

----- Original Message -----
From: "Peter Bottenberg" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, August 13, 2002 1:35 PM
Subject: [PHP] Re: controls "list menu"


> Hy,
>
> Save this script as select.php
>
> <?PHP
>
> if (!isset($action))
> {
>   $action = "select";
> }
>
> if ($action == "select" )
> {
>   ?>
>   <form method="post" action="select.php">
>   <select name="select" onChange="this.form.submit()">
>     <option value="one">one</option>
>     <option value="two">two</option>
>     <option value="three">three</option>
>   </select>
>   <input type="hidden" name="action" value="display">
>   </form>
>   <?
> }
>
> if ($action == "display")
> {
>   ?>
>   You selected value <?=$select?>
>   <?
> }
>
> ?>
>
> Greetings
> Peter




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to