Question about the dirac $\delta$-function I have a basic question about the dirac $\delta$-function based on the beginning of Chapter 1 of these notes.
The dirac $\delta$-function can be defined heuristically as the function that is $0$ everywhere except as $x = 0$, where it is $\infty$.
But formally, this is not the definition of the functional (since it's not a function).  Here is my question:

Since $\delta$(x) is not defined for each $x$, how can we talk about the product $(f(x)-f(0))\delta(x)$?  The author says this is identically $0$.  Why?  If we are using the heuristic definition of $\delta$, then when $x \neq 0$, $\delta(x) = 0$ so the product is $0$, and if $x = 0$, then we get $(f(0) - f(0))\cdot \infty$, but who is to say this is equal to $0$?  If $0 \cdot \infty$ always equaled $0$, then under this heuristic definition, we should have $\int \limits_{\Bbb R} \delta(x) \,dx = \int \limits_{\Bbb R - \{0\}} \delta(x) \,dx + \int \limits_{ \{0\} } \delta(x)\,dx = 0 + 0 \cdot \infty = 0$, but this integral is by definition equal to $1$.  But even so, what if we aren't using the heuristic definition?

 A: To say that $(f(x) - f(0)) \delta(x)$ is identically $0$ means that if we integrate $(f(x) - f(0)) \delta(x)$ against any test function, we get the same thing as if we integrate $0$ against that test function.  Let $\varphi$ be a test function.  Then
\begin{align}
& \int_{-\infty}^\infty \varphi(x)\Big( (f(x)-f(0)) \delta(x) \Big) \, dx \\[10pt]
= {} & \int_{-\infty}^\infty \Big(\varphi(x)(f(x)-f(0))\Big) \delta (x)\, dx \\[10pt]
= {} & \left. \varphi(x)(f(x)-f(0)) \vphantom{\frac 1 1} \,\right|_{x=0} = \varphi(0)(f(0)-f(0)) = \cdots
\end{align}
A: As the other answers testify, there are many useful viewpoints on "what's really happening" with Dirac's $\delta$. Also, there is the chronic confusion of whether "formal" means that something is really true/correct for trivial reasons, or, rather, that it is a suggestive heuristic that perhaps cannot be made legitimate but is useful.
The most specific response I have to the original question is simply about multiplying (compactly supported) distributions $u$ by smooth functions $f$ to obtain another distribution: $f\cdot u$ is the distribution defined by $(f\cdot u)(\varphi)=u(f\cdot \varphi)$ where $f\cdot \varphi$ is the pointwise multiplication, producing another test function.
Thus, in the case at hand, for any $f$ vanishing at $0$ (e.g., produced by replacing $f$ by the function $x\to f(x)-f(0)$), we have $(f\cdot \delta)(\varphi)=\delta(f\cdot \varphi)=(f\cdot\varphi)(0) = f(0)\cdot u(0)=0$. That is, such $f\cdot \delta$ is the $0$ distribution, not the number $0$. 
As some answers noted, $\int_{\mathbb R}\delta(x)\cdot 1\;dx$ can be construed as $\langle \delta,1\rangle$. Rather than disclaiming the integral expression by saying it's "just formal", why not say that it is to be interpreted as the extension to the pairing between distributions and test functions of the pairing of test functions and test functions by integrating-against. It is the extension-by-continuity of that pairing, using the weak-dual topology on distributions, after all.
There is some precedent for taking the viewpoint that "formally meaningless" integrals are in fact precise, meaningful extensions-by-continuity of pairings that are literal integrals on dense subspaces. Fourier transform and inversion on $L^2(\mathbb R)$ are examples of this: the integral itself only makes sense on $L^1$, but after proving Plancherel, we extend-by-isometry/continuity, and still write the integral, even though it is not literally that integral.
There is also the possibility of thinking of "multiplication by" $\delta$ as an operator mapping test functions to distributions, as suggested in some other answers. But here one might consider writing $\delta\otimes \delta$ when it's meant as an operator. Indeed, for two distributions $\alpha,\beta$, the operator $\alpha\otimes \beta$ is $(\alpha\otimes\beta)(\varphi)=\beta(\varphi)\cdot \alpha$. These are rank-one operators given by the "smallest" possible Schwartz kernels...
A: Dirac's $\delta$ is a distribution, not a function per se. Formally $\langle\delta,f\rangle=f(0)$. A common choice for the space where these things live is the dual of the Schwartz functions.
In physics the manipulation of these things is less rigorous in the notation. Since for some function spaces (like $L^2$) all linear functional into $\mathbb{R}$ are also functions ($\langle f,g\rangle=\int fg$) the notion of a generalized function is extended and the notation kept.
A more rigorous treatment is also to define $\int \delta f=\lim_{\epsilon\rightarrow\infty}\int f \rho_\epsilon$ where $\rho$ is a $C^\infty$ function with compact support around zero, and $\rho_\epsilon=\rho(r/\epsilon)/\epsilon$
$\delta g$ would be the distribution defined by $\langle\delta  g,f\rangle=f(0)g(0)$, so if $g(0)=0$, then $\delta g$ is always zero.
A: One can define
$$
\delta(x) = \left\{
\begin{array}{rcl}
|x| > \epsilon &:& 0\\\\
|x| \le \epsilon &:& \displaystyle \frac{1}{2\epsilon}
\end{array}
\right.
$$
Whence
$$
\int_{-\infty}^{+\infty} \delta(x) =
\int_{-\epsilon}^{+\epsilon} \frac{ 1 }{2\epsilon} dx = 1.
$$
and
$$
\int_{-\infty}^{+\infty} f(x) \delta(x) =
\int_{-\epsilon}^{+\epsilon} \frac{ f(x) }{2\epsilon} dx = f(0).
$$
A: 
See THIS ANSWER, where I provided a Primer on the Dirac Delta.

The heuristic statement $\delta(x)(f(x)-f(0))=0$ means that for each test function $f$, the functional $D[f(x)-f(0)]=0$, where $D[\cdot]$ is the Dirac Delta functional.
We write the functional for $D$ formally as
$$D[\cdot]=\int_{-\infty}^{\infty}\delta(x)[\cdot]dx \tag 1$$ 
But the right-hand side of $(1)$ is not an integral.  Rather, it shares many of the same properties with integrals and is therefore useful notation.  But it is only notation.
So, for a test function $f(x)$, we have 
$$D[f(x)]=f(0)$$
and therefore 
$$D[f(x)-f(0)]=f(0)-f(0)=0\tag 2$$
Finally, we interpret $(2)$ formally and write 
$$\delta(x)(f(x)-f(0))=0$$

Text books that heuristically discuss the Dirac Delta will often give the curiously nonsensical point-wise definition of $\delta(x)$
$$\delta(x)=
\begin{cases}
0,&x\ne 0\\\\
\infty,&x=0
\end{cases}
$$
which obviously is meaningless even with the additional condition that $\int_{-\infty}^{\infty}\delta(x)\,dx=1$.
This "hand-waving" description can be made rigorous by defining a family of functions $\delta_n(x)$ with the properties that 
$$\lim_{n\to \infty}\delta_n(x)=
\begin{cases}
0,&x\ne 0\\\\
\infty,&x=0
\end{cases}
$$
and 
$$\lim_{n\to \infty}\int_{-\infty}^{\infty}\delta_n(x)\,dx=1 \tag 3$$
One may then write, $\delta(x)\sim \lim_{n\to \infty}\delta_n(x)$ with the interpretation provided by $(3)$.  Examples of such families of functions include the pulse function
$$\delta_n(x)=
\begin{cases}
n/2,&-\frac{1}{n}\le x\le \frac{1}{n}\\\\
0,&\text{otherwise}
\end{cases}
$$
and the Gaussian function
$$\delta_n(x)=\frac{n}{\sqrt{\pi}}e^{-n^2x^2}$$
In this answer here, I discussed the regularization used in potential theory for the $\mathscr{R}^3$ Dirac Delta $\delta(\vec r)$.  There, the Dirac Delta is written 
$$\begin{align}
\delta(\vec r)&\sim \lim_{a\to 0}\delta_{a}(\vec r)\\\\
&=\lim_{a\to 0} \frac{3a^2}{4\pi(r^2+a^2)^{5/2}}
\end{align}$$
where $\lim_{a\to 0}\int_{\mathscr{R}^3}f(\vec r)\,\delta_{a}(\vec r)\,dV=f(0)$.
And finally in this answer here, I analyze the family of functions $\delta_{\epsilon}(x)=\frac{1}{\sqrt{\pi\,\epsilon}}e^{-\tan^2(x)/\epsilon}$ that describes the "train" of Dirac Deltas
$$\sum_{\ell =-\infty}^{\infty}\delta(x-\ell \pi)\sim \lim_{\epsilon \to 0}\frac{1}{\sqrt{\pi\,\epsilon}}e^{-\tan^2(x)/\epsilon}$$
