Jump to content

AdamPGT

Members
  • Posts

    7
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

AdamPGT's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. Anyone have any ideas? I noticed the onClick action works, but it's a bit pre-mature and doesn't grab the third variable. --Adam
  2. [!--quoteo(post=363255:date=Apr 10 2006, 04:42 AM:name=wildteen88)--][div class=\'quotetop\']QUOTE(wildteen88 @ Apr 10 2006, 04:42 AM) [snapback]363255[/snapback][/div][div class=\'quotemain\'][!--quotec--] Your form is submitting, but to its self! You will need something like this: [code]<?php if(isset($_POST['year'])) {    echo "Your have chosen: " . $_POST['make'] . " as the make, " . $_POST['model'] . " as the model, and " . $_POST['year'] . "as the year!"; } ?>[/code]If you wish to show what has been submitted. [/quote] THis is already in place: [code] if (isset($_POST['year'])){     header("Location: index.php?cPath=" . $_POST['make'] . "_" . $_POST['model'] . "_" . $_POST['year']);     } [/code] Which would send the page to index.php?cPath=xx_xx_xx, however, the form itself is simply not submitting, that's what I need help with. I need to submit this form without using a Submit button, even though using a submit button does work. --Adam
  3. HOw would you suggest I submit the form with the change of the third select? Here's a link....I have to edit my .htaccess file real quick: [a href=\"http://www.gforceauto.com/chain.php\" target=\"_blank\"]http://www.gforceauto.com/chain.php[/a] --Adam
  4. [!--quoteo(post=362620:date=Apr 7 2006, 01:05 PM:name=wildteen88)--][div class=\'quotetop\']QUOTE(wildteen88 @ Apr 7 2006, 01:05 PM) [snapback]362620[/snapback][/div][div class=\'quotemain\'][!--quotec--] Your code wont work as there is nothing to select! You'll want to use the <option></option> tag so the user can select an option from the pull down menu. Heres an example: [code]<form name="form" method="POST" action="<?=$_SERVER['PHP_SELF']?>"> <select name="year" style="width:160px;" onChange="this.form.submit();">   <option value="2001">2001</option>   <option value="2002">2002</option>   <option value="2003">2003</option> </select> </form>[/code] [/quote] The Options are being generated dynamically using PHP/JS.....even after looking at the page source when everything has been created no <option> tags show up. --Adam
  5. The form fields are being generated via JS, but for some reason when I select the third option, nothing happens. Here's the code: [code] <form name="form" method="POST" action="<?=$_SERVER['PHP_SELF']?>"> <table align="center">     <tr>         <td><select name="make" style="width:160px;"></select></td>     </tr>     <tr>         <td><select name="model" style="width:160px;"></select></td>     </tr>     <tr>         <td><select name="year" style="width:160px;" onChange="this.form.submit();"></select></td>     </tr>     <tr>         <td> </td>     </tr> </table> </form> [/code] Thanks for any help! Adam
  6. So I'm building a content/document management syste and it's turned a bit more complicated than I had anticipated. The problem I've run into is how I should setup my DB tables. Basically, I would like some outside input on DB structure so I can get my navigation to work like it should. The navigation has a Parent Category, with sub-categories and pages. But each sub category should have the ability to have subs and pages, etc. Now some of these sub-categories will be uploaded PDF docs. The tricky part of the navigation, or at least the part I'm having a bit of trouble with is that I only want the "active" category to be expanded. Kind of like this: -- No Active sub-cat Parent Category ---> Sub Category 1 ---> Sub Category 2 ---> Sub Category 3 -- Active sub-cat Parent Category ---> Sub Category 1 ---> Sub Category 2 -------> Sub-Sub Category 1 -------> Sub-Sub Category 2 -------> Sub-Sub Page 1 ---> Sub Category 3 -- Active sub-sub-cat Parent Category ---> Sub Category 1 ---> Sub Category 2 -------> Sub-Sub Category 1 ----------> Sub-Sub-Sub Category 1 ----------> Sub-Sub-Sub Category 2 -------> Sub-Sub Category 2 -------> Sub-Sub Page 1 ---> Sub Category 3 And so on and so on. Any DB setup suggestions? I don't need any code help or anything, just figured someone would have a suggestion that would give me a push in the right direction. --Adam
  7. I'm building a small PHP/MySQL driven system on a Windows IIS 5.x (Windows Server 2000). In any case I have a simple login page that works fine from the IP address, but when I use the host name (http://checklist/) I get an HTTP - 405 Resource Not Allowed error page. Any ideas? Thanks, Adam Here's the login script, just in case: [code] <?php if(isset($_POST['Submit'])){         $email = $_POST['Email'];         $pass = $_POST['Pass'];         $query = "SELECT UserID, UserLevel, Email, Password FROM users WHERE Email = '$email'";         $select = mysql_query($query) or die(mysql_error());             if (mysql_num_rows($select) < 1){                 header("Location: index.php?err=email");                              }             else {                 $row = mysql_fetch_array($select);                 $ePass = md5($pass);                     if ($ePass == $row['Password']){                         session_start();                         header("Cache-control: private"); // IE Fix                         //Store session information                         $login = date('Y-m-d') . " " . time();                         $insert = "INSERT INTO sessions (Session, UserID, LoginTime) VALUES ('" . session_id() . "', '" . $row['UserID'] . "', '" . $login . "')";                         mysql_query($insert);                         $sid = mysql_insert_id();                         $sess_sql = "SELECT SessID, Session FROM sessions WHERE SessID = '$sid'";                         $sess_result = mysql_query($sess_sql);                         $sess_row = mysql_fetch_array($sess_result);                                                                  header("Location: main.php?sid=" . $sess_row['SessID'] . "&&session=" . $sess_row['Session']);                     }                     else {                         header("Location: index.php?err=pass");                         //echo $ePass . "<br>" . $row['Password'];                     }             } } ?> [/code] --Adam
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.