When am I allowed to remove a term by dividing 0 by the term It seems that you are allowed to remove terms from an equation if there is a 0 on the other side of the equals sign:
$$
3x = 0
$$
$$
\frac{3x}{3} = \frac{0}{3}
$$
$$
x = 0
$$
However, you can't just do whatever you want:
$$
3x = 0
$$
$$
\frac{3x}{x} = \frac{0}{x}
$$
$$
3 \ne 0
$$

$$
3x^2 + 2x - 4 = 0
$$
$$
\frac{3x^2 + 2x - 4}{3x^2 + 2x - 4} = \frac{0}{3x^2 + 2x - 4}
$$
$$
1 \ne 0
$$
What exactly is the rule here? Is it simply unsafe only when the denominator would contain a variable or be 0? When is dividing 0 by something to remove that something from the equation allowed/safe, if ever?

You can't ever divide by something that is zero.  And if something might be zero, you must consider that it might not be to divide by the thing you are dividing.
Suppose you had $x^2 +x -6 = (x+2)(x-3) = 0$
But you are allowed to try.  If you do try and get a valid result you can state the result is valid but only if the thing you were dividing by was not $0$.
So I can say if $x-3 \ne 0$ then I can do the following
$\frac {(x+2)(x-3)}{x-3}=\frac {0}{x-3} $ (!!!IF!!! $x -3 \ne 0$)
$x+2 = 0$
$x=-2$.
So I can conclude $x = 2$ IF $x -3 \ne 0$.
But if  I do that I MUST immediately also consider the case that will happen if $x-3$ DOES equal $0$.
So I must conclude.
$x = -2$ if $x-3 \ne 0$ and if $x -3$ does equal $0$ then $x = 3$.
So either $x = -2$ or $x = 3$.
However if I try to divide and don't get a valid result, then we can conlcude we weren't allowed to do that.
Example:  Let $(x^2 + 2)(x-3) = 0$
And I try:  IF $x - 3 \ne 0$ then 
$\frac {(x^2 + 2)(x-3)}{x-3} =\frac 0{x-3}$
$x^2 + 2 = 0$
so $x^2 = -2$.  .... but that's impossible.  
Then I must conclude, hmmm, I guess $x - 3\ne 0$ was false, and instead $x -3 = 0$ so $x = 3$.
Note: that is exactly the result we would have gotten if we had divide by $x^2 + 2$ instead.
Ex:  Now we know $x^2 \ge 0$ so $x^2 + 2 \ge 2$ so $x^2 + 2 \ne 0$.  So we can do
$\frac {(x^2 +2)(x-3)}{x^2 + 2} = \frac 0{x^2 + 2}$
$x -3 = 0$
$x = 3$.
Now one nifty thing about $a*b = 0$.
If you have that, then you know without a doubt, that one of $a$ or $b$ (or possibly both) is equal to $0$.
