issue with firefox tamper data plugin - firefox-addon

I am facing this problem while debugging a website.
Plugin used: tamper data for fire fox;
Possibilities: its a ajax request.
as you see in the image the tamper dialog dose not show anything for this request. for other request it shows the general options.
any known issue with this.
And I also want to know if any other better tool available for analyzing websites(live or remote, not on localhost)

Tamperdata is the buggiest thing ever made, even the UI takes 50 clicks to do anything. Look for another tool. I personally use HackBar to send simple POST/GET requests (there's a version that can modify cookies per request too I think), and Wireshark or livehttpheaders (although livehttpheaders is also buggy) when I need to analyze traffic.

Related

How can send ajax request from activex control/NPAPI and process its response?

Currently i have a wepage where I am sending a ajax request from javascript and in respose for that server is sending a video file which will be by default saved browser download location. I want the user to select download path each and every time for the file download(which can be achieved by changing browser settings which is not suited for me). So i want to include a activex object which can send ajax request and get its response. First I want to know whether is it possible, if yes is there any prototype/examples, or please let me know how it can be achieved.
It is possible; FireBreath has a mechanism called BrowserStreams that would probably work for what you're describing, but honestly I'd suggest against it. See if you can do what you need using an extension; Chrome is dropping support for NPAPI next year and even if they weren't I think it's a really bad idea to use a plugin for something like this.
Up to you, of course. There are examples for making HTTP GET and POST requests in the FBTestPlugin example in FireBreath.

Can we manage the silent print always by PHP or Jquery

print.print_always_silent use to print the page without print dialog box. My question is, can we do this my PHP / JQUERY code?. Please Help me how know well abt this.
I hope not. That would mean any website could print any document from my printer when they want. Would be a huge security hole imho
This is certainly not possible through the browser with PHP, which runs on the server. It's also not possible with javascript: browser security ensures that. Imagine what might happen if any web site could print whenever it wanted to.
There are (or were) ActiveX controls available for IE that enabled this. It might be possible with a browser extension for Chrome or Firefox if you want to explore that.
One other possibility is setting up a printer on Google Cloud Print and having your PHP server print directly to that, bypassing the browser altogether. Handling the authentication behind such a scheme could be tricky, but the API is documented on Google's site.

With firebug stop loading so can see requests

I am trying to analyze a POST request using firebug. Using the net panel I can see the request, however when the POST has success the page then reloads and I only have a couple of seconds to actually look at the request and see what is going on. Is there a way I can pause it much like when analyzing scripts using this tool?
There is a "Persist" button on some of the tabs in Firebug. Just make sure to click it before doing your post.
[edit] Second row, third button from the left, on the Console and Net tabs.
Even better, if you're on Windows you can use Fiddler - an amazing and free HTTP debugger developed by some important guy on the Microsoft IE team.
With it you can conditionally intercept GET or POST requests, inspect and change parameters, break on responses, change responses (headers or body), reissue old requests and generally screw with your application during development.
Simply one of the most useful web development tools. Ever.
May require a little tweaking for localhost - see here
One solution would be to remove the refresh of the page from your code.
Then run your code to see the results.
You can use web developer tools plugin for Mozilla firefox, and disable meta redirects

How can I detect when user browses certain url?

I'm writing an application, which becomes "useful" once user is browsing certain url.
I want to add feature to my application, that it will be automatically launched once user browses this url, I was thinking of writing some sort of watchdog to trigger it.
My question is, whether there is a generic way to get notified when user browses to urls, I want to support at least IE and FireFox, chrome and safari is nice to have.
I read about DDE and WWW_RegisterURLEcho, but from what I understand it's not supported by FireFox, and also little sample I wrote didn't work with IE as well.
Thank you in advance
some more questions **
Do Url Monikers and Asynchronous Pluggable Protocols help me here ? Is it supported by FireFox ?
If you have control over the website, you could have it write a cookie to the computer. Then have your application monitor for that cookie.
You can implement this in many ways and at many different layers.
At the highest level, you could implement a browser plugin. There is no cross-browser solution at this layer that will let you write the code once and work for every browser. On the easy end of the spectrum, Firefox, you could implement it entirely as a Javascript + XUL plugin and use built-in XPCom interfaces (nsIProcess) for launching your helper process. For IE you would need to write a COM, C++ and win32 BHO that handles DWebBrowserEvents2::BeforeNavigate2. This is the hardest thing to do. There are mechanisms for Safari, Chrome and other webbrowsers that you could use to achieve this same behavior, with varying degrees of difficulty.
At the next level you could implement an HTTP proxy, similar to Fiddler2, that redirects all HTTP traffic through your local proxy first. Each browser has a different way of configuring its proxy settings, but they're all basically registry settings or config files.
At the most basic level you could just snif all IP traffic going out of the machine, similar to the way Wireshark does it, and just look for http requests to your URL. This is probably more difficult to code, but would work for all browsers without any special per-browser configuration stuff going on. You may need to write a driver. I dunno, I've never done work at this level in the stack.

What are the steps involved from entering a web site address to the page being displayed on the browser?

And how can the process be speeded up from a developer point of view?
There are a lot of things going on.
When you first type in an address, the browser will lookup the hostname in DNS, if it is not already in the browser cache.
Then the browser sends a HTTP GET request to the remote server.
What happens on the server is really up to the server; but it should respond back with a HTTP response, that includes headers, which perhaps describe the content to the browser and how long it is allowed to be cached. The response might be a redirect, in which case the browser will send another request to the redirected page.
Obviously, server response time will be one of the critical points for perceived performance, but there are many other things to it.
When a response is returned from the server, the browser will do a few things. First it will parse the HTML returned, and create it's DOM (Document Object Model) from that. Then it will run any startup Javascript on the page; before the page is ready to be displayed in the browser. Remember, that if the page contains any ressources such as external stylesheets, scripts, images and so on, the browser will have to download those, before it can display the page. Each resource is a separate HTTP get, and there are some latency time involved here. Therefore, one thing that in some cases can greatly reduce load times is to use as few external ressources as possible, and make sure they are cached on the client (so the browser don't have to fetch them for each page view).
To summarize, to optimize performance for a web page, you want to look at, as a minimum:
Server response time
Bandwith /content transfer time.
Make sure you have a small and simple DOM (especially if you need to support IE6).
Make sure you understand client side caching and the settings you need to set on the server.
Make sure you make the client download as little data as possible. Consider GZipping resources and perhaps dynamic content also (dependent on your situation).
Make sure you don't have any CPU intensive javascript on Page load.
You might want to read up on the HTTP Protocol, as well as some of the Best Practices. A couple of tools you can use are YSlow and Google Page Speed
What are the steps involved from entering a web site address to the page being displayed on the browser?
The steps are something like:
Get the IP address of the URL
Create a TCP (HTTP) connection to the IP address, and request the specified page
Receive/download the page via TCP/HTTP; the page may consist of several files/downloads: e.g. the HTML document, CSS files, javascript files, image files ...
Render the page
And how can the process be speeded up from a developer point of view?
Measure to discover which of these steps is slow:
It's only worth optimizing whichever step is the slow one (no point in optimizing steps which are already fast)
The answer to your question varies depending on which step it is.

Resources