If this is your first visit, please click the Sign Up now button to begin the process of creating your account so you can begin posting on our forums! The Sign Up process will only take up about a minute of two of your time.

Results 1 to 2 of 2

Thread: Search and Edit

  1. #1
    Junior Member
    Join Date
    Apr 2016
    Member #

    Search and Edit

    How would I add search and edit capabilities to this? Appreciate any help!!

    $servername = "localhost";
    $username = "root";
    $password = "password";
    $dbname = "dbname";

    // Create connection
    $conn = new mysqli($servername, $username, $password, $dbname);
    // Check connection
    if ($conn->connect_error) {
    die("Connection failed: " . $conn->connect_error);

    <table id="default_mgmt" align="center" border="1">
    <td>Empower ID</td>
    <td>First Name</td>
    <td>Last Name</td>
    <td>LDA2 (If Rolls)</td>
    <td>Deliquency Date</td>
    <td>Days Deliquent</td>
    <td>Default Date</td>
    <td>Cohort Year (YYYY)</td>
    <td>Multiple Cohort Years?</td>
    <td>Loans Y/N</td>

    $sql = "SELECT * FROM `default_mgmt`";
    $results = mysqli_query($conn,$sql);

    while($rowitem = mysqli_fetch_array($results)) {
    echo "<tr>";
    echo "<td>" . $rowitem['id'] . "</td>";
    echo "<td>" . $rowitem['first_name'] . "</td>";
    echo "<td>" . $rowitem['last_name'] . "</td>";
    echo "<td>" . $rowitem['lda'] . "</td>";
    echo "<td>" . $rowitem['lda_rolls'] . "</td>";
    echo "<td>" . $rowitem['deliquency_date'] . "</td>";
    echo "<td>" . $rowitem['days_deliquent'] . "</td>";
    echo "<td>" . $rowitem['default_date'] . "</td>";
    echo "<td>" . $rowitem['cohort_year'] . "</td>";
    echo "<td>" . $rowitem['multiple_cohort'] . "</td>";
    echo "<td>" . $rowitem['loans'] . "</td>";
    echo "</tr>";


  3. #2
    WDF Staff mlseim's Avatar
    Join Date
    Apr 2004
    Cottage Grove, Minnesota
    Member #
    723 times
    I suggest you look at a PDO CRUD.
    CRUD means .... Create, Read, Update, Delete
    The 4 basic functions to a database.

    PDO is the new MySQL, object version of MySQL.

    See this:
    PHP PDO CRUD Tutorial using OOP with Bootstrap | Coding Cage

Remove Ads

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
All times are GMT -6. The time now is 03:00 PM.
Powered by vBulletin® Version 4.2.3
Copyright © 2020 vBulletin Solutions, Inc. All rights reserved.
vBulletin Skin By: