Html page automatically refreshes

So i’ve been breaking my head over this, i am creating a php code using javascript and jquery. I created a html form, and called a php part of the code. Now when i display the JSON array, i can see the displayed elements for a millisecond and then the page refreses to the initial page. The code works, but i dont want the automatic refresh how do i do that ?

HTML:

 

ADD INVNTORY

" method="post"> 1Your basic info Name: Serial number: Amount:
<form action="<?php echo htmlspecialchars($_SERVER["PHP_SELF"]);?>" method="post">

VIEW ALL

1Current Inventory list

</fieldset> </div> </form>

VIEW INVENTORY DETAILS(GRAPH)

<button type="submit">Sign Up</button> </form>
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s