Day 36: Making a List and Checking it Twice…

We are embarking on the big capstone project this week! I’ve finally decided on my theme. For my site, I’m going to have a fictitious charity knitting and crocheting drive to knit squares to make afghans for local organizations: a senior center, a homeless shelter, an animal shelter, and a daycare center. Those will be my four “leagues.” I will have two knitting and two crocheting teams per league, with five members on each team—although, come to think of it, I shouldn’t limit it to five if I want people to produce enough squares for an afghan in a timely manner. I’ll have to figure out certain logistics of my drive…for instance, who’s going to sew all the squares together??? Also, I’ll probably have to have certain guidelines, such as square size, type of yarn used, leaving tails to aid in sewing the squares together, etc. I’ll also have to determine who is able to access my site to enter teams and members.

The entertaining part has been in coming up with the fake member names, phone numbers, and email addresses. As much as I’d love to make it easy and use my real knitting and crocheting friends’ information, that would be a terrible idea. I’m trying to use innocuous names like “Smith,” “Jones,” etc. Also, I’m trying to keep the phone numbers to “555” numbers. Honestly, I’m beginning to run out. I may have to start throwing in some weird names for entertainment.

I’ve already got some funny team names. So far, I have:

  • Knitting Chicks with Sticks
  • Crocheting Happy Hookers
  • Knitting Fools
  • Crocheting Yarns

I may need to rethink one or two of these, as Chicks with Sticks and The Happy Hooker are indeed knitting and crocheting books, respectively. Also, Knitting Fool is a web app sweater pattern generator. I know this is a fictitious class site, but I’d just as soon not be SUED.

I’ve also been scouring my pictures to come up with some good illustrations for the site. For once, I don’t think I’m going to be at a loss for photo material!

Day 35: Stretching the Limits…

So much for needless worry! Our Friday project was a retread of the code we tore our collective hair follicles out over the day before. The only real thing that changed was the data (spa services rather than products). Also, as it was a single page application, I didn’t need to hunt down 560 photos. I just needed one for the cover page. Our instructor wanted us all to have a stress-free weekend before the capstone work begins in earnest next week.

Speaking of which, I WILL need pictures for that project, so I’m going to need to start hunting for nice-looking knitting and crocheting examples for my fictitious square contest. We have a copy of the data file setup to which we can add our own data. The only issue I see is that we’re supposed to have LEAGUES, in addition to teams. I’m not quite sure how to work that into a knitting and crocheting square contest, unless I divide the teams into two leagues—knitters and crocheters (I can hear the screaming now).

In the meantime I did a wild & crazy thing. At the beach today (Saturday) I managed to swim all the way to the buoy — twice! In an indirect way I credit it to the Code Academy program. Mentally, I’m stretching myself on a daily basis in ways I never thought possible. In turn, it’s prompted me to challenge myself in other areas of my life.

I’m going to be massively sore tomorrow, but it was SO worth it…

Day 33: Pondering Capstone Project Scenarios

I’m happy to report I’ve managed to at last get my “Friday” project to a good place, where I’m not tempted to hide it under a rock in shame. Everything is correctly functioning, and I even managed to make the UI look nice. One of my classmates helped me out with using Font Awesome icons to make my edit, view, and unregister links look sharp. Another helped me a few days ago with the “Select One” option for the dropdown, so that looks good.

I’m still pondering what to do for the capstone and the “team” concept. I had an insane idea of making my fictitious crafting teams compete to see who could knit and/or crochet the most squares for Warm Up America, with the winners getting a $100 gift certificate to Webs. However, if this were a real online contest, I can see a few pitfalls:

1. For one thing, I’d need to limit the number of team members, so that I wouldn’t end up with 100 people on the winning team getting $100 apiece (“Um, Sweetums, about that retirement fund…). I could perhaps have the winners as a group getting a $500 gift certificate—though I can just see the ensuing cat fight in the yarn store now. I know, I know…before I start getting hate mail, I’m fully aware that there are male knitters and crocheters! Perhaps I could limit the groups to five people, with the winners each getting $100 apiece.

2. Another issue—how does anyone PROVE how many squares they really produced? The only way to really prove it would be if the teams sent the squares to me, which would be its own logistical nightmare—I’d have to mail all the squares to Warm Up America MYSELF ($$$). Also, people in the home environment probably wouldn’t take too kindly to an entire room being filled to the rafters with tiny 7” x 9” squares (yes, I’m aware this would technically make them rectangles). Perhaps I could have people post a picture of themselves with all their squares before they mail them to Warm Up America. Surely no one could fake piles of squares. I mean, even I—the ultimate crazy yarn woman—don’t have 100 squares lying around to pile up and fake for a picture…However, one can never underestimate the sheer prowess of the truly delusional among us.

I do have time to suss this out before next week.

(I’m sorry Randy and Gary! I know you’d never stage a cat fight in a yarn store! However, I can see one of you convincing the other team members that Webs was no longer in existence… 😈)

Day 32: Up, up, and array!

Today we continued to modify our projects to add new courses, and do put requests to modify a table. I swear I felt like EINSTEIN when I dynamically created a pre-filled input form to modify data and IT WORKED. I even managed more validations.

For some reason, the wheels fell off the wagon for me when we proceeded onto multistring queries. I’ve gotten so used to doing long concatenations to create dynamic HTML that, oddly, something that’s supposed to be much simpler just threw me. Also, we’ve started using functions like find(), findIndex(), etc. which are simpler, but seemed ALIEN after what we’ve coded before.

It’s sort of like that expression, “why go through the door when there is a perfectly good wall right there?”

I muddled through but it was both frustrating and infuriating.

I did get out this evening with the knitting peeps, though!

Day 30 and a half: UI Envy

It was an UGLY day of trying to pump out yet another Friday project. I stayed at class until almost 7:00 p.m. on Friday, trying to finish. The good news is that I got the jQuery/JavaScript working, and I managed to throw in field validations by the end of the day. I still struggle with where to put events in relation to the JSON callbacks. I did manage to validate the dynamic HTML, which was a good thing, as I had some ghastly error involving my generation of dynamic links onto a page.

This morning (Saturday) we had an email from our other instructor. He had some general feedback on the sites he’d seen so far in GitHub. It actually was a good thing, as I was able to check on and update my site. Despite looking it up on stackoverflow.com, I struggled with getting an image into my readme.md file until I just downloaded one of his readme files out of GitHub and reverse-engineered it to fit my needs.

So, the only thing I had left to do before the Saturday 5:00 p.m. deadline was to make the user interface look good…

I have a confession. I’m artistic at certain things, but not others. Even with my knitting and crocheting, I great at techniques, but struggle over what colors to choose that will work together. It’s always the way…I’ll think I have a great-looking website, but then I’ll look at other classmates’ Friday projects and mine is pathetic-looking in comparison! When it’s a matter of coming up with funny-sounding or interesting text, I’m good at that, but my illustrations and placements are usually plain and downright dreary.

For instance, I FINALLY got an image to cover my Jumbotron on the main page, without looking stretched-out, blurry, or just plain ridiculous. I was so excited! Then I glanced over at other pages and people have carousels going, and multiple interesting illustrations, and beautiful interfaces that just made mine look like the sad, pathetic wallflower of all sites.

I’ll need to up my game for the capstone project coming up…

Day 28: Reason Things Out

Today, as most of my days, was a day of desperately trying to figure out how to do things. Add jQuery into the mix, and you get something like THIS:

Today we learned (the hard way) how to dynamically create a table using jQuery. We just learned to do this 5 minutes ago using regular JavaScript, so it was one of those ugly—I REALLY hate the expression “I can’t wrap my head around this,” but it was just like that. It was the mental equivalent of turning around an ocean liner on a dime. I had to stare at the example in our workbook for ages until it clicked. I have to say, once I figured it out, dynamically creating tables is much easier to accomplish via jQuery.

We also had to redo another earlier script in jQuery. For the life of me, I could NOT figure out what was wrong with my code until our instructor had me look at the stack trace. She was so excited to have a real-life multi-line jQuery goof that she called over people in groups of three to look at my screen, and showed everyone how to debug code that uses jQuery. Spoiler Alert: when it says you screwed up in some weird obscure line that’s decidedly NOT yours, you have to trace it back to your original issue (mine being using a $ rather than a # in an id object). I’m not sure how I feel about being held up as an example of bad code…

Day 27: All jQuery-ing aside…

After my rant yesterday about nitpicking errors, today I added more to my blossoming collection, including an issue with the character countdown on my <textarea> box starting at 33 characters instead of 50. You guessed it. I’d inadvertently added spaces between the <textarea> tags in my html, so the box already had 17 spaces to be in with.

Today was our exciting foray into jQuery. I can’t believe I’m saying this, but I’m finding it easier than regular JavaScript. Probably because we are taking past exercises and modifying them to have jQuery where applicable. We also have to create a spreadsheet to keep track of how to do certain things the JavaScript way vs. the jQuery way. Seeing as this is a library, it’s sort of the “Bootstrap” of JavaScript.

The good news is that we managed to get out in time for me to make it to my knitting group this evening! I’ve started on the sheep on the front of the sweater which, after dealing with JavaScript and jQuery all day, isn’t as hard as I thought.

Day 25: Got the project done!

I woke up in the morning with a migraine from hell, including nausea and hurling. I had to down a bunch of Advil and caffeine, and just lie down quietly until it was time to get to class.

Despite this, I’m happy to report that I was able to complete Friday’s project! I even managed a few of the extra-credit things, too. I’m going to hold off on sending the “I’m done” email to the instructor until I have a chance to look it over once more. This time I didn’t put any “extra” invalidated pages in GitHub that I was going to get to later.

I really do need to remember, when I’m struggling and wailing and gnashing teeth all week, that it all pays off on Friday when I’m able to complete the project with everything I’ve learned over the week. I showed my resultant site to my loved ones, who were all impressed!

Now onto some fun and games!

Day 23: Dynamically creating things…

…Mostly a scene…

Today was a VERY long day. Thankfully, with a bit of help, I figured out my issue from yesterday. I was off by ONE lousy line of code.

Our next adventure was adding, creating, and manipulating things to the html (appendChild, etc.) I managed to figure out how to do all this, but I’m still fuzzy on how to get rid of a dynamically-created table, once it’s created. I know I can just put a blank string in the div that holds it, but that wipes out the table element within the div, which fixes it so you can’t repeat the selection process when you choose another category from the drop down. I carefully inspected the elements after the first table gets created, and it’s odd. The <tr> and <td> tags are created in the html AFTER the <table> <\table> grouping, so one can’t even erase out the table, as technically nothing is in there—even though a table is definitely created on the screen. The only way I see around this is to perhaps figure out a way to dynamically recreate the table element after the div is blanked out. Either that, or do a routine to specifically delete out the <tr> and <td> tags.

After 10:30 pm, I decided to call it a night and to tackle this again tomorrow. Right now, I have the lazy fix in there to just reload the page if you hit the “Start Over” button. I do need to figure out how to erase the rows correctly though, as the OTHER issue is that if you just keep selecting category options from the drop down, and don’t reset, the choices just get added over and over again to the page every time you select a category—they don’t get replaced with the new category’s table entries.

Knitting fair isle with five colors would be easier…

Day 22: Lost in the DOM…

Day 22: Lost in the DOM…

This was just one of those days. It began well enough…I was understanding everything, and the first exercises went well. Then the **** hit the fan. I do realize that a huge part of what we do concerns interacting with the browser and the DOM; but I swear, at times I really miss our beginning labs, when all we did was code and run in the Code Runner console. The worst dread on earth is when you try to run your code, NOTHING HAPPENS, and then you have to hit F12 in the browser. Whenever I see that dreadful flaming red type, flashing angry error messages across the console, I always want to scream at the top of my lungs, “Dear God, WHAT FRESH HELL IS THIS???” Then I remember that I’m old enough have parented the vast majority of my fellow students, and that it would probably be undignified to cry and throw things.

Today, I spent a good part of the afternoon with the bloody F12 console. We’re doing some god-awful routine where we have to take a substr of similar <img> ids (image1, image2, image3) to get the numbers on the ends (1, 2, 3). Then we have to concatenate the “para” part of the paragraph <p> ids (para1, para2, para3) to these like some nightmare from Frankenstein, and — I’m not making this up — take the alt attributes of the img tags and shove that alt text into the <p> html.

I think it was after the 12th time I tried to make this work that I decided I really needed to knit…

I know…all the ghastly code is going to be waiting for me in the morning. On the other hand, I got a mental health break, and my little intarsia sheep are really coming along!