Bug Tracker

Modify

Ticket #7268 (closed bug)

Opened 3 years ago

Last modified 3 years ago

Data argument no longer works with DELETE requests

Reported by: anonymous Owned by: anonymous
Priority: low Milestone: 1.5
Component: unfiled Version: 1.4.3
Keywords: data argument delete Cc:
Blocking: Blocked by:

Description

Introduced here:  http://github.com/jquery/jquery/commit/c4e653237f258ce618ad5a9ec677917166fbed16

Code presupposes that data will never be sent with GET, HEAD or DELETE requests, previous versions only assumed this to be the case with GET.

Change History

comment:1 Changed 3 years ago by addyosmani

  • Keywords data argument delete added
  • Owner set to anonymous
  • Status changed from new to pending
  • Priority changed from undecided to low

Please provide us with a test case that reproduces this issue so that we can verify the effects its having.

comment:2 Changed 3 years ago by Mal

I did try to, however jsfiddle does not support ajax testing with anything but POST requests. I have posted a test case on jsFiddle, but it must be executed elsewhere in a PHP environment, sorry I couldn't be of more help.

Hope this is what you were looking for.

 http://jsfiddle.net/malibu/MCzkL/

comment:3 Changed 3 years ago by Mal

Managed to get the test case up on a server:  http://www.locatetv.com/blog/test/test.php

As you can see while the PUT request echos back correctly, the DELETE data is never sent and the corresponding echo is blank.

comment:4 Changed 3 years ago by andrew@…

I can confirm this regression. The fix is simply to remove DELETE from the rnoContent regexp, since there's no reason that delete requests cannot have parameters.

comment:5 Changed 3 years ago by trac-o-bot

  • Status changed from pending to closed

Automatically closed due to 14 days of inactivity.

Please follow the  bug reporting guidlines and use  jsFiddle when providing test cases and demonstrations instead of pasting the code in the ticket.

View

Add a comment

Modify Ticket

Action
as closed
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.