Hardware Limitations
The simplest answer is also the most elusive. One of the reason you do not use phasers as a cane to tap around in space to find enemy ships is that it takes time to charge, use and recharge the phaser arrays on Federation ships. While their recharge time during the series varied wildly, on average, it was not likely to be fast enough to allow an effective blanketing of space enough for detection of enemy vessels. Most Federation ships have 4-8 phaser banks, hardly enough to cover an area sufficient to relay information useful for targeting. More on that in a second.
First Limit: Activity and Activation
Since the discharge of a phaser means it is not ready for combat, trying to use the phasers, even at reduced power to blanket an area effectively AND then scan that area as well for more sophisticated targeting would take both power and an effectively running sensor array.
Cloaking Technology Advantages
It was possible to track cloaked vessels poorly by certain emissions, notably, from the impulse engines waste gas emissions, it was still unlikely that you would be able to target the ship well enough to shoot at them, so the cloak must actively prevent ships from gaining a lock, even if they were able to phaser-locate them. The cloak did not just block line of sight targeting from any and all normal spectral emissions, it also blocked subspace field emissions detection.
Sensor Technology: The basics
Sensor technology in the Alpha Quadrant was based on the idea of gathering information at faster than light speeds by penetrating and gathering information from subspace. A ship is always gathering subspace information because that information can travel faster-than-light, giving ships the opportunity to know about things around them that affect the space-time continuum deforming the fabric of space.
This would include objects with great gravitational effects such as stars, planets, black holes (which would be completely invisible otherwise) or artificial means of inducing space time fluctuations such as subspace-distorting-drive systems. With this faster-than-light sensor array, and the supporting computational power required to parse that information, they would have time to maneuver around and target anything that disrupted subspace.
Starship sensor arrays have to always be receiving subspace information about a target in space already for faster-than-light targeting to even take place, so the cloak doesn't just hide the ship physically from sight, it also hides its submersion into the subspace field, so a seeking ship's sensors are unable to detect the deformation of the space-time continuum, that allows sensors to detect that ship in the first place.
The odds of hitting that ship are...
What that means is even if you could phaser-echo-locate the ship, you would have to target it by hand because you would receive no support from the sensor array systems (which are the primary means of a starship getting information about its position in relation to another ship). This means you would have to be shooting blindly based on a signal received in real time, at light speeds.
Your chances of hitting it would be very, very low because you would only receive a second of information and would have to guess the direction, momentum and speed of the ship in that single second with a single bit of information (very difficult to do, weapons triangulation usually takes at least three points of information to effectively target anything.) At near-light speed, assuming a battle at impulse, you could miss by several thousands of miles even if your reaction time could be reduced to a fraction of a second.
What surprises me, is that more torpedoes were not configured to track ships by the energy emission signals. Likely after Kirk's time, this emission detection loophole was closed, so gas emissions from a ship's reactor could not be used a second time, refining the cloaking device's utility even further.