Jump to content

Search the Community

Showing results for tags 'hidden'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Welcome to PHP Freaks
    • Announcements
    • Introductions
  • PHP Coding
    • PHP Coding Help
    • Regex Help
    • Third Party Scripts
    • FAQ/Code Snippet Repository
  • SQL / Database
    • MySQL Help
    • PostgreSQL
    • Microsoft SQL - MSSQL
    • Other RDBMS and SQL dialects
  • Client Side
    • HTML Help
    • CSS Help
    • Javascript Help
    • Other
  • Applications and Frameworks
    • Applications
    • Frameworks
    • Other Libraries
  • Web Server Administration
    • PHP Installation and Configuration
    • Linux
    • Apache HTTP Server
    • Microsoft IIS
    • Other Web Server Software
  • Other
    • Application Design
    • Other Programming Languages
    • Editor Help (PhpStorm, VS Code, etc)
    • Website Critique
    • Beta Test Your Stuff!
  • Freelance, Contracts, Employment, etc.
    • Services Offered
    • Job Offerings
  • General Discussion
    • PHPFreaks.com Website Feedback
    • Miscellaneous

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


AIM


MSN


Website URL


ICQ


Yahoo


Jabber


Skype


Location


Interests


Age


Donation Link

Found 4 results

  1. hopefully this will be the end of this little project but ive been trying to do this for a while now i need to get 2 different collumns one of which is hidden which will be the ID one has the value of the field e.g. test, im hopefully down to the last error. ( ! ) Warning: mysqli_fetch_row() expects parameter 1 to be mysqli_result, boolean given in C:\wamp\www\AddLeads\addeadstemplate.php on line 254 Call Stack # Time Memory Function Location 1 0.0000 186408 {main}( ) ..\addeadstemplate.php:0 2 0.0156 194880 mysqli_fetch_row ( ) ..\addeadstemplate.php:254 <tr> <td>Type of Business:</td> <td> <select name="typeofbusiness"> <option value=''> - select type of business -</option> <?php $sql = "SELECT tbl_typesofbusiness.id, tbl_typesofbusiness.Agent FROM tbl_typesofbusiness"; $res = mysqli_query($con, $sql) or (mysqli_error($con)); while (list($id, $tob) = mysqli_fetch_row($res)); { echo "<option value='$id'>$tob</option>\n"; } ?> </select> </td> <td><span class="error">* <?php if (isset($errors['typeofbusiness'])) echo $errors['typeofbusiness']; ?></span></td> </tr> i can get rid of the error bie adding 'or die' on line 253 other than just or but what this does is stop everything under or die stops working cause ive got another 6 or 7 fields under type of business aswell as this no error occurs so im confused to hell, hopefully its not to complicated any help will be greatly appreciated
  2. right what i need to do is create 2 collumns for a html form, one of these is the ID and needs to be hidden and one collumn is full of options associated with these ID's the table which these two collumns are located on the database is called tbl_typesofbusiness and i just cant figure this out ive got the option box up but thats as far as i got i cant get two collumns up and they is no options in the option box, i just cant hack it ive been trying for a while and im confused to hell. <tr> <td>Type of Business:</td><td> <select name="typeofbusiness"> <?php $sql = sprintf("SELECT tbl_typesofbusiness.id, tbl_typesofbusiness.Agent FROM tbl_typesofbusiness")?></td> <td><span class="error">* <?php if (isset($errors['typeofbusiness'])) echo $errors['typeofbusiness']; ?></span></td> </tr> they is no errors on this code but i still cant seem to find a solution to it aswell theres only one record in the table at the moment which is called test1 with an id of 1. please help i just cant seem to hack it.
  3. hi once again im in need of help what i need is a double column one with a drop down box called type of business and one hidden one with the id, to me it would seem easier to simply code all of the options in html but the options for type of columns has been coded onto the website, i got a code sent over to me but errors are occurring so just wondering if anybody has any ideas. <td>Type of Business:</td> <select name="typeofbusiness" id="typeofbusiness"> <?php $count = count($_SESSION['typeofbusiness']); for ($i = 0; $i < $count; $i++) { if($_SESSION['id'][$i]!=$_SESSION['Id']){ ?> <option value="<?php echo $_SESSION['id'][$i];?>" <?php if (isset($_REQUEST['typeofbusiness'])&&$_REQUEST['typeofbusiness']==$_SESSION['id'][$i]) { echo'selected="selected"'; }?>><?php echo $_SESSION['typeofbusiness'][$i];?></option> <?php } } ?> ( ! ) Notice: Undefined variable: _SESSION in C:\wamp\www\AddLeads\addeadstemplate.php on line 248 Call Stack # Time Memory Function Location 1 0.0000 186688 {main}( ) ..\addeadstemplate.php:0 any help will be greatly appreciated.
  4. Hi everybody, I am writing an inventory system using PHP+MySQL. The system provides simple functions like Insert, Display, Update and Delete for the user to choose in Page 1. However, for Display, Update and Delete, users then have to enter the product ID in page 2, but not for the Insert function, which should directly jump to Page 3 for inserting the item specifics. As the different functions can go to different pages, in Page 1, I don't think I shall put all these function choices as radio buttons in the same form. One solution is to implement these 4 choices as 4 submit buttons, i.e. 4 forms are created. However, to differentiate among Display, Update and Delete, I need the HTML of Page 1 to carry some values to Page 2 depending on which submit button is being chosen, but apart from the choice of the 4 functions, users do not need to input anything else in Page 1. Hence I need a hidden input type, like this: <form name='1' action='Page3.php' method='post'> <!-- Insert will skip Page 2 --> <input type='Submit' value='Insert'> </form> <form name='2' action='Page2.php' method='post'> <input type='hidden' name='function' value='Display'> <input type='Submit' value='Display'> </form> <form name='3' action='Page2.php' method='post'> <input type='hidden' name='function' value='Update'> <input type='Submit' value='Update'> </form> <form name='4' action='Page2.php' method='post'> <input type='hidden' name='function' value='Delete'> <input type='Submit' value='Delete'> </form> So in Page 2, I can know which button is clicked from $_POST['function']. I believe this works, but is it a good practice? If not, is there any better solution? Thanks! -- pengi <(")
×
×
  • 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.