Jump to content

RawrRawrRob

Members
  • Content Count

    15
  • Joined

  • Last visited

Community Reputation

0 Neutral

About RawrRawrRob

  • Rank
    Newbie
  1. Hmmm ya, I thought it might have something to do with that. How would I fix this?
  2. Hey everyone, I'm trying to create a simple form where a user enters their name. I have the text field with an onfocus function that creates a div next to the field telling the user to enter their name. Now, with the onblur function, if the user enters nothing, using innerHTML the div will tell them again to enter their name. If they enter any text, the innerHTML in the div will change and say thank you. Here's my code so far, I feel like I have done it right, but it doesn't seem to work the way I want it to. Any help to point me in the right direction is greatly appreciated window.onload =
  3. Thank you, this helped! This is what I have so far now and it adds the text to the list window.onload = init; function init(){document.querySelector("#btnList").onclick = addToList; } function addToList(){ var textbox = document.getElementById('txt');var content = document.getElementById('listContent'); var addtext = document.createElement('li'); addtext.value = textbox.value;addtext.innerHTML = textbox.value;listContent.appendChild(addtext);} Now, how do I get it so when you add the text, it also adds a span class (in my case the class is called "remove") infront of the text to the list?
  4. This is what I have so far, window.onload = init; function init(){document.querySelector("#btnList").onclick = addList;} function addList(){//this creates the paragraph to add to #listContentvar p = addParagraph(); //append the var pdocument.querySelector("#listContent").appendChild(p);} I'm wondering how I get the text from the input filed into the #listContent div. You don't need to give me the code, I just need an explanation and I can then try to figure things out myself, I appreciate the help!
  5. Here's what the HTML file looks like in the browser, with 3 instructions on the right link The button's id is "btnList"
  6. Hello, attached is a Javascript exercise for school that I'm having some troubles with! Any help/explanation is greatly appreciated! List.zip
  7. Thank you for the help! I finally got the buttons working properly!
  8. I got everything working! But now when you click on the next/back button, it doesn't go to the right image! link
  9. Thank you that worked! But I seem to have noticed another problem, when I click on either the back or next buttons, it displays the thumbnail for the corresponding image and not the large version :/
  10. Hello, I'm having trouble getting my back and next buttons in my lightbox to work! Any help will be greatly appreciated! http://imd.edumedia....term/index.html
  11. I'm still having some troubles... inside of the showIMG function this is what I have before I got stuck:var overlay = document.createElement("div");//give the new div an idoverlay.id = "overlay";//add the div to the page (inside of the parent, the body tag)document.querySelector("body").appendChild(overlay); //create the container for the lightboxvar boxer = document.createElement("div");boxer.id = "boxer"; document.getElementById("boxer").innerHTML = '<img src="images' + name + '.jpg">';
  12. Hello, thank you for replying! I've uploaded what I have so far, as you can see, when you click on an image thumb, the larger image shows up, but behind the Lightbox in a div. Why is this? Thank you!
  13. Hello, in my HTML file I have 3 rows with 5 pictures in each, and when you click on them a larger version of it appears under. How could I use Javascript so when you click on the smaller version, the larger version appears but in a lightbox? This is what I have so far in my attempts to get this working. Any help will be greatly appreciated! Here is my HTML code: <!doctype html><html><head><meta charset="UTF-8"><title>Untitled Document</title><link href="css/css.css" rel="stylesheet"/><script src="java.js"></script></head><body id=
  14. Hello, I'm new to JavaScript and I'm trying to use JavaScript for my website. I want to have a sample sentence, where you can select the font family it is in and then you can also click on a size option to change the display size for the font. I've tried to get this to work for a while but just can seem to do it! If anyone can help it will be greatly appreciated!
×
×
  • Create New...