Jump to content

submitting form to self problem


JamesThePanda

Recommended Posts

Hi

Im having a problem with some code Im not sure if its a php thing or a html thing.

 

Basically I have been making a wordpress plugin, In the plugin there is a form, all it is ment to do is. delete a row of a table in a data base

all is working fine apart from one thing the delete button.

More specifically the action of the form, i have tried to get the form to submit to its self by setting the target as the specific php file.

 

How can i check If the file is actually submitting to its self.

Thanks

 

James

Link to comment
Share on other sites

example form code:

<form method="post" action="pagename.php">
<input type="submit" name="submit" value="Delete" />
</form>

 

Just make shure the php code is listening to the correct submit btn "name"

and make shure the php code that deletes receives the correct row id

otherwhise you wont be able to delete anything.

 

Can you post your code???

 

 

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.