By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
440,058 Members | 1,336 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 440,058 IT Pros & Developers. It's quick & easy.

What is my error? I can't find why code doesn't work!

P: 785
This code works how I want it too work.
2 letter quiz

This code does not work how I want it too. The links refuse to load up in the frame no matter what I change the 2.html link to be.

The js file is the same between the two pages.
Its the jyz.js file thats the same. This file does work in the first link, but doesn't have the desired effect in the second link. When I had this issue on the other page, it was the iframe src that I had wrong. Thus,
I know that the iframe src=... must be the same as the page that the user starts on in order for the links to upload on that same page. However, no matter what link I put as the iframe src link, it won't work.

Please, write out between code tags exactly what that url should be as I'm not seeing it!
Apr 17 '07 #1
Share this Question
Share on Google+
6 Replies

P: 785
Relevant iFrame code that WORKS. All links load up in the iframe on the page 1g.html like it should.
Expand|Select|Wrap|Line Numbers
  1.     <iframe src="1g.html" width="700" height="550" name="content" id="content" align="right" frameborder="1">Your browser does not support iframes</iframe>
  2.     <ul> Click a Question </ul>
  4.     <li><a href="../2letter/g1.html"> Question 1</a><br />
  5.     <li><a href="../2letter/g2.html"> Question 2</a><br />
  6.     <li><a href="../2letter/g3.html"> Question 3</a><br />
  7.     <li><a href="../2letter/g4.html"> Question 4</a><br />
  8.     <li><a href="../2letter/g5.html"> Question 5</a><br />
  9.     <li><a href="../2letter/g6.html"> Question 6</a><br />
  10.     <li><a href="../2letter/g7.html"> Question 7</a><br />
  11.     <li><a href="../2letter/g8.html"> Question 8</a><br />
  12.     <li><a href="../2letter/g9.html"> Question 9</a><br />
  13.     <li><a href="../2letter/g10.html"> Question 10</a><br />
Relevant code that does NOT work. The links do NOT load up on to page 2.html like they should.
Expand|Select|Wrap|Line Numbers
  1.     <iframe src="" width="800" height="130" name="content" id="content" align="right" frameborder="1">Your browser does not support iframes</iframe>
  2.     <ul> Click a Question </ul>
  4.     <li><a href=""> Question 1</a><br />
  5.     <li><a href=""> Question 2</a><br />
  6.     <li><a href="../f/c/c3.html"> Question 3</a><br />
  7.     <li><a href="../f/c/c4.html"> Question 4</a><br />
  8.     <li><a href="../f/c/c5.html"> Question 5</a><br />
  9.     <li><a href="../f/c/c6.html"> Question 6</a><br />
  10.     <li><a href="../f/c/c7.html"> Question 7</a><br />
  12.     <li><a href="../f/c/c8.html"> Question 8</a><br />
  13.     <li><a href="../f/c/c9.html"> Question 9</a><br />
  14.     <li><a href="../f/c/c10.html"> Question 10</a><br />
Only c1 and c2 exist. The other pages haven't been made yet.
I do have a iFrame on page c1, but wanted only c1 to load normally within the iframe on 2.html Is this why its not working? ?I have a iframe on page c1 so is confusing for the browser?
Apr 17 '07 #2

P: 785
Not even g2.html will load into the frame! Thus, I just have to have a link wrong! And, it just has to be the iframe src="????" link that is wrong! Ugh!

Recap of what I've tried for links for iframe on page 2.html
Expand|Select|Wrap|Line Numbers
  2. ../2.html
  3. ../gaming/2/word/cipher/f/2.html
  4. ../2/word/cipher/f/2.html
  5. ../word/cipher/f/2.html
  6. ../cipher/f/2.html
  7. ../f/2.html
Apr 17 '07 #3

P: 785
Okay, so the main page and the pages you want to load into frames must be in the same folder - but why??? This is the only different between the two codes!
Apr 17 '07 #4

P: 785
That didn't even work! I put 2DOThtml in the same page as the c1 + files and it still didn't upload c1 onto the same page.
Put in code tags so that it wouldn't make them a URL.
Expand|Select|Wrap|Line Numbers
  1. I even put the jyz.js file into the same folder! 
  2. I copied jyz.js from the original file and copied it between folders. 
  4. Thus, 2.html, jyz.js and c1.html, and c2.html are all in the folder marked c. 
Apr 17 '07 #5

P: 785
I never found the error, but I did copy the 1g file over to the other folder. I then changed the links. I have no clue what was wrong, but it now works! I'm sure its the case of a little dot or tiddle out of place. LOL
Apr 17 '07 #6

P: 785
I found the problem. The 2 js files weren't playing nicely with each other.
Apr 17 '07 #7

Post your reply

Sign in to post your reply or Sign up for a free account.