You must Sign In to post a response.
  • Category: HTML

    How to connect mysql with HTML ?


    Are you looking for a way to connect mysql with HTML ? then read this thread to know how to do it



    How to connect a html form with a MySQL database maintained else where.
    Where to upload the .php page .Mention all the aspects.
  • #757337
    Hi
    Download MySql this site
    http://dev.mysql.com/downloads/mysql/
    then refer your webpage Mysql.dll and using client side script for connection .

    Try this code

    <%@ Import Namespace="System.Data" %>

    <%@ Import Namespace="Microsoft.Data.Odbc" %>

    < HTML >

    < HEAD >

    < SCRIPT Language="VBScript" Runat="server" >

    Sub Page_Load(Source as object, e as EventArgs)

    Dim sConnection = "DRIVER={MySQL ODBC 3.51 Driver}; SERVER=localhost; DATABASE=; UID=;PASSWORD=< Put your MySQL password here >; OPTION=3"

    Dim oConnection as ODBCConnection = new ODBCConnection(sConnection)

    Dim sSQL as String = "SELECT FirstName, LastName FROM Users"

    Dim oDataAdapter as ODBCDataAdapter = New ODBCDataAdapter(sSQL, oConnection)

    Dim oDataSet as DataSet = new DataSet()

    oDataAdapter.Fill(oDataSet)

    oDataGrid.DataSource = oDataSet

    oDataGrid.DataBind()

    End Sub


    Refer this urls


    http://www.sqlstrings.com/mysql-asp.net-connection.htm
    http://webcheatsheet.com/asp/sqlserver_connection_strings.php
    http://webcheatsheet.com/asp/database_connection_to_MSSQL.php
    http://www.sqlstrings.com/SQL-Server-connection-strings.htm

    Name : Dotnet Developer-2015
    Email Id : kumaraspcode2009@gmail.com

    'Not by might nor by power, but by my Spirit,' says the LORD Almighty.


  • Sign In to post your comments