Monday, 7 May 2018

D11: More work on the portfolio page


View this on my main page


Hey Everyone and Welcome to Day 11!


Today's Goal!

Today I wanted top do more JQuery tutorials, I learnt how to animate content, a little bit about AJAX, but most importantly (for today) I learnt how to use Reg Ex. My goal for today was to create my "Contact Me" page and have it working.

Tutorials!

So today's tutorials were around animating content using jQuery. I had fun doing this, don't quite see a way to fully include this in my web page at the minute but maybe one day I will. I then had a quick tutorial on AJAX. I can see how this could really become useful with the help of other back-end languages. I looks like it could help when it comes to making a social network style website (one that I have been asked to help out on) but I think i need more lessons on it. Then the tutorials turned to Reg Ex and form validation, this was just what I needed for the next stage of my website.

The contact page, it does a footer at the bottom
but this is the standard one
(not made yet)

Making the page!

My first step was to make the page, and style it using CSS how I wanted it. It involved a new CSS sheet as it would look different to the main landing page. This was designed to be simple to use but also look good. I decided to go for a bar at the top with my title, logo and social links. I'm thinking about changing the social links to be actual text and then include links to other parts of the website but for now, it looks good and works. I like the look of my form cells, I need to learn how to send them thought. I can't send them like a normal form as this breaks the error messages.

Zoomed in on just the form

Validating!

The error messages come from the form validation function. I made this using the jQuery that I had learnt. It first checks to make sure that the cells aren't empty. If they are, it creates an error message for each cell that is empty. If not it then goes on to check if the email address entered is of the correct format. Once again, if not, it throws an error to the error section. Finally if there are no errors, it re-hides the error section and will then be able to submit the enquiry to me.

Errors are thrown for the empty cells
It also does it if the email is incorrect

Tomorrow's Goal!

I'm back at work tomorrow so won't have quite as much time as I've had today. This means I may just do some work on the game engine, maybe adding some sort of play-ability and possibly even make a version that can be released and made available to play on my website. We shall see, but for now,

Happy bank holiday!

Matt

No comments:

Post a Comment