I've never built a ff extension before and before I start I want some feedback on my idea to make sure its possible.
I want a firefox extension that allows me to supply a url with parameters in GET format, the extension would take the url, parse it, and submit the request as POST开发者_开发问答 rather than GET.
Is this possible? and could someone give me some advice on how to start designing an extension? or point me at a tutorial?
You definitely can! Parsing the URL's can be done with any javascript library you can find such as parseUri or you can do it with the mozilla component nsIURLParser.
After that it is only a matter of actually executing the POST request with a XMLHttpRequest. I think that should be the easy part to do. The hard part will be getting up to speed with Firefox extension development. The Add-on Builder can set you with with a minimal Firefox extension as a building block.
Good Luck!
I don't know for sure, but as the Tamper Data plugin is able to manipulate HTTP request, it should be possible.
Have a look at the source code of the plugin to get some ideas.
精彩评论