0 Favourites

How do I request data from ASP.NET?

  • Hi, I want to do login. On the main page there is only a PHP login tutorial but I don't know PHP and can only use ASP.NET. Can someone help me with a sample script to get login data from a aspx page? Or just convert the tutorial php code into aspx code? Thank you very much.

    [quote:37rhgvqo]

    <?php

    02 $username = $_GET['fname'];

    03 $password = $_GET['fpass'];

    04 $con=mysqli_connect("mysql","database_user","database_password","mydatabase");

    05 // Check connection

    06 if (mysqli_connect_errno())

    07 {

    08 echo "Failed to connect to MySQL: " . mysqli_connect_error();

    09 }

    10 $qz = "SELECT id FROM members where username='".$username."' and password='".$password."'" ;

    11 $qz = str_replace("\'","",$qz);

    12 $result = mysqli_query($con,$qz);

    13 while($row = mysqli_fetch_array($result))

    14 {

    15 echo $row['id'];

    16 }

    17 mysqli_close($con);

    18 ?>

  • Construct 3

    Buy Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Buy Now Construct 3 users don't see these ads
Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)
Similar Topics Posts Views Last Post
Unread sticky
150 20,718
Crow in the Snow's avatar
Crow in the Snow
Unread hot topic
99 10,136
karshinkoff's avatar
karshinkoff
Unread hot topic
0 Favourites
C3 Architect Request list
125 12,730
jayderyu's avatar
jayderyu