Posts Tagged ‘Firefox’

MeasureIt for Firefox

Monday, August 10th, 2009

Ever wanted to know how many pixels wide something is on a web page. I used to find myself doing a print screen, pasting into my favorite editor and then measuring it using that application’s measuring device. I wanted to know how I could speed this up, because in my line of work it is necessary to know the measurement of elements on a web page. How could I accomplish this easily? I found a plug in that enables you to do this on the fly using Mozilla Firefox. This plug in is great, you just install it, then a small tool appears int he bottom left hand corner of your browser!

Example of the Firefox add on called MeasureIt

Example of the Firefox add on called MeasureIt

Just click on the tiny ruler icon and a cross-hairs will appear. Drag the cross-hairs over the desires area of measurement, and a measurement will appear.

Firefox MeasureIT add on in action!

Firefox MeasureIT add on in action!

After you are finished the measurement, just click the ESC key. Yes, it is that easy!

Click here to download this add on directly from the Mozilla add on site.

How to refresh or reload an iframe that works in Firefox and IE

Monday, June 8th, 2009

Ever have a problem where an iframe that you have in your web page will just not refresh or reload? This is definately a problem if you have updated the source file of the iFrame, yet it does not show recent changes. How do fix this, with a little bit of Javascript!

All you need is just a few lines of code.

First set up your iframe:

<iframe id="yourframe" src="yourframe.html" width="840px" height="3200px" frameborder="0"></iframe>

Next drop this javascript above your body tag:

<script type="text/javascript">
window.reload = refreshFrame;
function refreshFrame() {
document.getElementById('yourframe').src = "yourframe.html";
}
</script>

What reloads the frame, its the window.reload call. By defining the id of the frame and calling it to window.reload will automatically reload the frame every time you refresh or come back to the page. Very easy and it works great. Good luck!