I am confused about the following:
The exponential function (by definition) is a function of the form $f(x)=a^x$ where $a>0$. However, when $a=1$, we get the constant function $f(x)=1^x=1$. Is the constant function $f(x)=1^x=1$ still considered an exponential function even though it does not have behave like an exponential function? Is the definition of the exponential function that I gave above (that I read in many textbooks) not entirely correct? Should we define the exponential function by:"a function of the form $f(x)=a^x$ where $a>0$ and $a\neq 1$"? I welcome any answer. Thanks!
Well, an exponential function is one whose rate of change is proportional to its current $y$-value. i.e. one satisfying the differential equation $\frac{dy}{dx}=ky$ for some constant $k$.
$\frac{d}{dx}[a^x]=a^x\ln(a)=ka^x$ for $a \neq 0$.
Now, if $a=0$, i.e. if we want to evaluate $\frac{d}{dx}[1^x]$, we see that $\frac{d}{dx}[1^x]=1^x\ln(1)=1^x(0)=0 \neq k(1^x)$ (unless $k=0$, in which case $ \frac{dy}{dx}$ is not proportional to $y$).
So, essentially, your way is the way to go! As far as definition is concerned, an exponential function is any $f(x)=a^x$, where $a\in \Bbb{R^+} \setminus \{1\}$.