number needs to be in quotes here or it doesn’t work. That surprised me because I thought that would make it a string of the word number. I tried putting
into the console and it returned
So I guess that makes sense. It just surprised me. I guess because I’m asking to compare the typeof it would never return the value of a string, just what type. It still seems strange that it should be in quotes but there you go!
I’m going to start putting little things that were unclear to me before I have an a-ha! moment. This blog is about my journey learning to code so some of these will almost certainly be obvious to some people, but hopefully if someone else who is learning searches for an answer finds my post, well, good for me right? And more to the point good for the person whose question is answered! So here’s the first little a-ha.
- Input fields like ‘values’
- HTML elements have ‘innerHTML’
In other words, what’s in a <div> is it’s innerHTML but what’s in a text box is its value.
I know, probably remarkably simple and obvious to some folks but hey, it was something that briefly gave me a problem and I figured out so here you go.
I’m not starting with no web knowledge, but I’m not currently working in the field either. In fact, I’ve been out of it for about 15 years so I have a LOT to catch up on. One of the things I keep seeing from the tutorials, podcasts, and other sources I’ve been using is that you should have a blog so here we are.
Another thing they all say is that you need to get out there and network so tonight I went to my first meetup in NYC. It was a woo commerce thing with only a handful of people and I don’t think I really got too much out of it, but what the heck, I still got out there, made the trek into NYC and gave it a shot.
I have been keeping a list for myself on ideas for blog posts so hopefully as this progresses I will be able to help others who are on a similar journey. Now, off to do another tutorial!
This site will serve as my web design portfolio as well as my playground for learning WordPress and Woo Commerce. Speaking of which, you can buy me a virtual cup of coffee.