Continuing to expand Training Grounds tab - Learning JavaScript!

in utopian-io •  7 years ago  (edited)

Welcome, once again, to the New Year! As some of you may know, my long term goals around programming are continuing strong into this year, 2018. I have begun running through the Basic Algorithm Scripting on Free Code Camp. If you haven't heard of FCC, and you want to learn html, css or javascript, head over their now!

0 - freecodecamp.jpg
I wrote a function!

But after writing my function I felt confused. How would this work on a website? I couldn't just paste javascript anywhere I want.... I would have to have a form field, a submit button, and some where to display the output.

I pulled up the training grounds to see how far I could get.

1 - content block errors.jpg
2 content blocks? Thats ridiculous

The first thing I learned was that Django only can handle a single content block per page. I had added another, but I quickly deleted it after this error message. What I really needed there was

<div class='row'>

In order to separate what I had done before with what I was doing now.

I also learned that Django takes a JS block, below the content block to abstract the Javascript from the section. More appropriately would be to call the javascript from another file, which I will look into doing in the next development.

2 - final code.jpg
We did get it working!

My good friend kit.andres came over and I immediately bombarded him with questions about why my variables weren't playing well together. He helped me add the second function that takes the input on submit and feeds it into my original function. He also reminded me how to call id's properly in jquery.

3 - final functionality.jpg
Double Reverse!

I am very happy that I have not only a place to put the code that I work out, but also friends and a community to share it with. Questions, comments or requests are very welcome in the comments section!

Let's live this year as if were the best year EVER!

Love and Light to All!



Posted on Utopian.io - Rewarding Open Source Contributors

Authors get paid when people like you upvote their post.
If you enjoyed what you read here, create your account today and start earning FREE STEEM!
Sort Order:  
  ·  7 years ago (edited)

Hey @wehmoen, I just gave you a tip for your hard work on moderation. Upvote this comment to support the utopian moderators and increase your future rewards!

Hello Wehmoen. I have not changed it to a tutorial because I do not believe it to be a tutorial. I will do my best to make my next dev 'follow the rules'.

Thank you.

I am jealous. I want to learn JavaScript too. I just do not have the time. I may be jealous but, I am happy for you . Keep moving forward. I expect great things from you in 2018

Thank you Scott!

I expect for you too to make astounding progress on your goals this year, and that steem will help you do it!

I just wish am an IT person, I love your goal. Keep it going man.

Thank you! And you can get there:

practice.jpeg

good going

  ·  7 years ago (edited)