Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8275645
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T08:08:28+00:00 2026-06-08T08:08:28+00:00

Default3.aspx This is my first page. in which i have two textbox and one

  • 0

Default3.aspx

This is my first page. in which i have two textbox and one submit button, onclick of submit button calling Default4.aspx page, where i have written the data insertion code.

    <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.0/jquery.min.js">
    </script>

    <script type="text/javascript">
$(function() {
$("#add").click(function() {

var login = $("#loginid").val();
var pass = $("#pass").val();
var dataString = 'login='+ login +'&pass='+pass;

$("#flash").show();
$("#flash").fadeIn(400).html('<img src="ajax-loader.gif" align="absmiddle"> <span class="loading">Loading Comment...</span>');

$.ajax({
type: "POST",
url: "Default4.aspx",
data: dataString,
cache: false,
success: function(html){
$("#display").after(html);
//document.getElementById('content').value='';
//document.getElementById('content').focus();
$("#flash").hide();
}
});
 return false;
});
});
    </script>

</head>
<body>
    <form name="frm_add" id="frm_add">
    <input type="text" name="loginid" id="loginid" />
    <input type="text" name="pass" id="pass" />
    <input type="submit" id="add" value="Submit" />
    <div id="flash"></div>
<div id="display"></div>
    </form>
</body>
</html>

Default4.aspx

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

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>Untitled Page</title>
</head>
<body>
    <%
    Dim login, pass As String
        login = Request.QueryString("login")
        pass = Request.QueryString("pass")
        Dim cs As String = ConfigurationManager.ConnectionStrings("eExamSolutionConnection").ConnectionString
        Dim cn As New SqlConnection(cs)
        Dim cmd As New SqlCommand
        ' MsgBox(dob)
        cmd.CommandText = "INSERT INTO ADMIN_CREDENTIAL VALUES ('" & login & "','" & pass & "')"
        cmd.Connection = cn
        cmd.Connection.Open()
        cmd.ExecuteNonQuery()
        cmd.Connection.Close()
        cmd.Dispose()
        cn.Dispose()
        Response.Write("Added")
     %>
</body>
</html>

But, blank row inserted into my table, whenever i’m submitting the value. Need help !!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-08T08:08:30+00:00Added an answer on June 8, 2026 at 8:08 am

    Use Fiddler and check if everything is alright.

    Change the TYPE of JQuery Ajax to GET and see if it works or not.

    $.ajax({
    type: "GET",
    url: "Default4.aspx",
    data: dataString,
    cache: false,
    success: function(html){
    $("#display").after(html);
    //document.getElementById('content').value='';
    //document.getElementById('content').focus();
    $("#flash").hide();
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have two aspx page on my application. From the first one, lets say
this code will not pass the query string to default3.aspx on Image Button ..
I have page (Default1.aspx) in which I am redirecting to another page (Default2.aspx) using
I have a basic .ASP page like this, which when hit redirects the user
I have a Default.aspx page in which I have bind a Grid. In the
I have two master pages and a content page. On my local machine this
I have a page, Default.aspx, with its own code-behind file like this: using System;
I have an XML file that looks like this: <SiteMenuItems> <SiteMenuItem text=Home navigateurl=/Default.aspx tooltip=Return
Let's say I have two files default.aspx and the associated default.aspx.cs . default.aspx.cs: protected
I have a gridview and listview in my aspx pages which both display tables

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.