-
00:00:00In this tutorial, I will be discussing the code slash script widget
-
00:00:04Now the code script widget, this is used to enter any JavaScript code that you want to embed in a specific point of the website
-
00:00:12It's located right down here
-
00:00:15Now, once you create that widget, it's going to ask for that JavaScript code
-
00:00:20And I'm not going to go into too much detail as far as JavaScript is concerned because that's not what this tutorial is about
-
00:00:26But I will introduce the basics of the internet languages
-
00:00:30Right over here, we have three main languages that make up the average website
-
00:00:35The primary language is called HTML, also known as hypertext markup language
-
00:00:41And that is the core language that websites are built upon
-
00:00:44And that's basically what is in a website and the content of a website
-
00:00:49And that goes hand in hand with CSS called cascading style sheets
-
00:00:54And that is what determines the look and the layout of a website, such as the fonts, the colors, the styles, and the positioning of that content
-
00:01:03And that goes hand in hand with HTML
-
00:01:05And there's also JavaScript, which is a third language
-
00:01:08And that's used to add enhanced functionality onto a website and add more interactivity and extra features as well
-
00:01:15So like I said, we're not going to actually teach JavaScript coding today
-
00:01:19We're just going to show how the widget works in our platform
-
00:01:22Once you have created the widget, it's going to ask for the JavaScript code
-
00:01:27You can type in your own code or you can copy some existing code
-
00:01:30I have over here just some sample codes on this website used for demonstration purposes
-
00:01:36This code right here, what this is going to do is it's going to generate the exact date
-
00:01:41So if you were to copy this code and paste that into the code box for the widget and you save that, it'll now generate
-
00:01:50That's the date that this video was filmed
-
00:01:53And if you were to come in on a different day, that would then update to the current date
-
00:01:57So that's what the JavaScript code does is it's interactivity and extra functionality
-
00:02:01We can also add the current time
-
00:02:05So if I copy this full code and paste it into the box, it'll also show the time
-
00:02:09So you don't have to make a new widget for each code that you want to paste
-
00:02:15You can if you want to separate the widgets
-
00:02:18However, as long as there's space in between the different codes, when you save them, it'll put them right next to each other
-
00:02:26So you see right there, now is the current date and the current time
-
00:02:29And you can do a whole lot with JavaScript
-
00:02:33Once you learn what it is and how it works, it'll add a whole bunch of extra functionality to your website
-
00:02:38We've also got one more I wanted to demonstrate
-
00:02:40This here is going to refresh the page on the click of a button
-
00:02:44So let's add this in a separate widget, just so you can see you can separate them and space them out easier this way
-
00:02:51Once you save this, it has now added that button and that code directly below
-
00:02:59So if I refresh the page, you'll see it automatically refreshes the page once that button is pushed and it generates a different number each time
-
00:03:08And that is just some sample functionality of JavaScript
-
00:03:13I encourage you to learn a little bit more about JavaScript as well as HTML and CSS if you don't already
-
00:03:20Learning about how those work and at least just the basics would make building websites a lot easier
-
00:03:26And once you know them, you can edit the code on your current website as well
-
00:03:30And if you want to ever edit or add JavaScript, you would simply use the code script widget