Website Toolbox Pro

What Does “Javascript”, “Dreamweaver”, “CSS” Mean And How Does It All Fit Together?

Javascript, Miscellaneous, PHP / MySQL Comments »
I’m new to this whole thing, I need to know for journalism class please!

How does HTML, CSS, Python, Dreamweaver, InDesign, PHP…. what do these things have to do with websites?

Continue reading What Does “Javascript”, “Dreamweaver”, “CSS” Mean And How Does It All Fit Together? »

What Is The Best Program To Reduce The Size Of A JavaScript File?

Javascript Comments »
I have a menu on my website that is composed of JavaScript. What is the best program or method to make this as small of a file as possible?
I want it as small a file as possible but still displayed online, i.e I want a fully functioning menu that doesn’t make my webpage have a ridiculously large filesize.
Javascript Compressor is one of many free online tools to reduce the size of a JavaScript file.

Javascript: Using A String As A Variable

Javascript Comments »
I have a function that I send a javascript array to like so:

if (VAR_clicked == "one") {
    FUN_Table(VAR_array_one);
} else if (VAR_clicked == "two") {
    FUN_Table(VAR_array_two);
} else if (VAR_clicked =="etc") {
    FUN_Table(VAR_array_etc);
}

My problem now is I have many more arrays and want to do something like this:

FUN_Table("VAR_array_" + VAR_clicked);

I’m trying to use a string to pass a variable to the function, this does not work.
Any ideas as to how I can do this?

Continue reading Javascript: Using A String As A Variable »

How To Enable Javascript?

Javascript Comments »
Can you tell me how to enable javascript? All of a sudden, AIM chat says I must enable javascript to enter chat.

Continue reading How To Enable Javascript? »

Picture Change On Click Without Javascript

Images, Javascript Comments »
Do you know how to make a picture change when you click it, and then change back when you click it again? Preferably without Javascript if possible.
You can’t do something like that without Javascript. A mouse click is an event, and there is no way to process events but with Javascript. Use the onclick property of the img, div or a tag.

How Can I Declare A Global Variable Inside A Javascript Function?

Javascript Comments »
Is it possible to declare a global variable inside a javascript function?
If you create any variable inside a function, its scope will be local to that function only and not global. Declare your variable outside the function.

How Do I Update Select Options From Javascript?

Javascript, Meta Tags Comments »
I want to change the available list in the <select> drop-down menu using a pre-defined array in javascript.

Continue reading How Do I Update Select Options From Javascript? »

How Can I Use Javascript To Check If The Value Of A Text Box Has Been Deleted ?

Javascript Comments »
How Can I Use Javascript To Check If The Value Of A Text Box Has Been Deleted?
Look up the onchange() event. That should point you in the right direction.

How Do I Create A Javascript Command To Close The Window?

Javascript Comments »
Is there a code I can paste on my website that will create a Javascript command to close the window?
The basic code is:
window.close();

Javascript: Variables Within Regex?

Javascript, Regular Expressions Comments »
Is it possible to use a variable within a regular expression declaration? For example:

var findThs="test123";
var mystring = "This is some test123 text";
var result = myString.match(/findthis(?:,| |$)/);

This doesnt return a result since findthis is being interpreted as text rather than a variable. I want its contents to be inserted into the regex expression.

Continue reading Javascript: Variables Within Regex? »