Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie

HTML and MySQL databases

Options
  • 10-12-2007 6:40pm
    #1
    Closed Accounts Posts: 3,119 ✭✭✭


    Greetings.
    I'm trying to get information from a web page to a database :mad:. The idea is that a user enters the information in the web page and when they submit the information its stored on to a database, which is programmed using MySQL and is running off server2Go. Any ideas of tags i could use to do this or coding id need in the database?
    If its piss easy to do, tell me how THEN scorn my ignorance! ;) Any help is appreciated. Cheers!


Comments

  • Registered Users Posts: 3,594 ✭✭✭forbairt


    http://www.w3schools.com/php/php_ref_array.asp

    +

    http://ie.php.net/manual/en/ref.mysql.php

    You've a bit of reading to do

    look at the "PHP Database" bit on the left of the w3schools page


  • Closed Accounts Posts: 3,119 ✭✭✭Wagon


    Didn't think to look at w3schools :o Cheers man!


  • Registered Users Posts: 3,594 ✭✭✭forbairt


    no problem ... its always in the last place you look :D


  • Closed Accounts Posts: 238 ✭✭coadyj


    perl
    php
    servlet

    import java.sql.*;

    public class Oracle {
    public static void main(String[] args) {
    try {
    DriverManager.registerDriver(new oracle.jdbc.driver.OracleDriver());
    Connection conn = DriverManager.getConnection
    ("jdbc:oracle:thin:@localhost:1521:oracle", "sysman", "password");
    Statement stmt = conn.createStatement();
    ResultSet r = stmt.executeQuery ("SELECT * FROM client");
    while (r.next())
    System.out.println(r.getString(1) + " " + r.getString(2));
    r.close();
    stmt.close();
    conn.close();
    } catch (Exception e) {
    System.out.println("ERROR : " + e);
    e.printStackTrace(System.out);
    }
    }
    }


  • Registered Users Posts: 260 ✭✭pdebarra


    Coadyj, that was not terribly helpful. Indentation would make that code readable, as would fixing the smilies. If you want to post code, better to do so within [ CODE ][ /CODE ] tags:
    System.out.println(r.getString(1) + " " + r.getString(2));
    

    In any case, you have not given the OP any indication of what he should do with this code, nor even told him what language it is.

    A singularly useless post.

    OP, my recommendation would be the same as Forbairt's: PHP is ideally suited to taking info from web pages (HTML forms) and stick it into a MySQL database.


  • Advertisement
Advertisement