# Quick HTML question

**URL:** <https://boards.straightdope.com/t/quick-html-question/344701>\
**Category:** Factual Questions\
**Created:** [February 15, 2006, 10:15pm UTC](https://boards.straightdope.com/t/quick-html-question/344701 "2006-02-15T22:15:55Z")\
**Posts on this page:** 16\
**Page:** 1

<div class="post-metadata">

**Author:** ![World\_Eater](https://avatars.discourse-cdn.com/v4/letter/w/f04885/32.png) [@World\_Eater](https://boards.straightdope.com/u/World_Eater)\
**Post date:** [February 15, 2006, 10:15pm UTC](https://boards.straightdope.com/t/quick-html-question/344701/1 "2006-02-15T22:15:55Z")

</div>

When I click on a link, how can I have it load a new version each time? I google it, and all these crazy javascripts for bypassing the cache come up. I’m experiencing some caching problems, and I’ve decided to just have it load a new page each time.

Any suggestions?

---

<div class="post-metadata">

**Author:** ![VenusProbe](https://avatars.discourse-cdn.com/v4/letter/v/e495f1/32.png) [@VenusProbe](https://boards.straightdope.com/u/VenusProbe)\
**Post date:** [February 15, 2006, 10:19pm UTC](https://boards.straightdope.com/t/quick-html-question/344701/2 "2006-02-15T22:19:11Z")

</div>

I believe that is a browser setting, what are you using?

---

<div class="post-metadata">

**Author:** ![Slacker](https://avatars.discourse-cdn.com/v4/letter/s/6bbea6/32.png) [@Slacker](https://boards.straightdope.com/u/Slacker)\
**Post date:** [February 15, 2006, 10:23pm UTC](https://boards.straightdope.com/t/quick-html-question/344701/3 "2006-02-15T22:23:43Z")

</div>

You’ll need one of those crazy javascripts. Here’s an article that explains 'em pretty simply.

[http://www.htmlgoodies.com/beyond/reference/article.php/3472881](http://www.htmlgoodies.com/beyond/reference/article.php/3472881)

---

<div class="post-metadata">

**Author:** ![Beadalin](https://avatars.discourse-cdn.com/v4/letter/b/3be4f8/32.png) [@Beadalin](https://boards.straightdope.com/u/Beadalin)\
**Post date:** [February 15, 2006, 10:27pm UTC](https://boards.straightdope.com/t/quick-html-question/344701/4 "2006-02-15T22:27:32Z")

</div>

Do you mean a link within your own website, or other sites? Because JavaScript can’t help you on other people’s sites.

If it’s other sites, **VenusProbe** is right, it’s a browser setting. Or, you can hold down your \<Shift\> key and click on Refresh/Reload in your browser’s toolbar.

---

<div class="post-metadata">

**Author:** ![World\_Eater](https://avatars.discourse-cdn.com/v4/letter/w/f04885/32.png) [@World\_Eater](https://boards.straightdope.com/u/World_Eater)\
**Post date:** [February 15, 2006, 10:34pm UTC](https://boards.straightdope.com/t/quick-html-question/344701/5 "2006-02-15T22:34:25Z")

</div>

It’s kind of tough to explain, so heres the walk through if you have a moment.

(This is my new website I’m building)

[www.subtechbeats.com/frametwo.html](http://www.subtechbeats.com/frametwo.html)

1. Click on “all music”

2. Roll over the song names, see how they change color?

3. Click on a song name, a window will pop up. Close it.

4. Rollover still works.

5. Click any other button, say “links” for example.

6. Click “all music” again. the links no longer rollover.

wtf?

I figure if it doesn’t cache, maybe it will load a new all music with rollovers

---

<div class="post-metadata">

**Author:** ![ultrafilter](https://avatars.discourse-cdn.com/v4/letter/u/3d9bf3/32.png) [@ultrafilter](https://boards.straightdope.com/u/ultrafilter)\
**Post date:** [February 15, 2006, 10:36pm UTC](https://boards.straightdope.com/t/quick-html-question/344701/6 "2006-02-15T22:36:23Z")

</div>

Works fine for me. What OS/browser are you using?

---

<div class="post-metadata">

**Author:** ![gotpasswords](https://avatars.discourse-cdn.com/v4/letter/g/c57346/32.png) [@gotpasswords](https://boards.straightdope.com/u/gotpasswords)\
**Post date:** [February 15, 2006, 10:40pm UTC](https://boards.straightdope.com/t/quick-html-question/344701/7 "2006-02-15T22:40:46Z")

</div>

Looks like you need to tweak your styles:

.musiclink:link {color: blue; font-weight: bold;}  
.musiclink:hover {color: orange; text-decoration: underline; font-weight: bold;}  
.musiclink:visited {color: blue; font-weight: bold;}  
.musiclink:active {color: blue; font-weight: bold;)

I’m guessing you want to change visited to the same formatting as hover.

---

<div class="post-metadata">

**Author:** ![ultrafilter](https://avatars.discourse-cdn.com/v4/letter/u/3d9bf3/32.png) [@ultrafilter](https://boards.straightdope.com/u/ultrafilter)\
**Post date:** [February 15, 2006, 10:41pm UTC](https://boards.straightdope.com/t/quick-html-question/344701/8 "2006-02-15T22:41:42Z")

</div>

Spoke too soon. In the “tracks from our album” section, the first, third and fifth links never display the rollover behavior, but everything else works. I’m using win2k and IE 6.0. Have you tried replacing the musiclink:hover with a rollover event handler?

---

<div class="post-metadata">

**Author:** ![World\_Eater](https://avatars.discourse-cdn.com/v4/letter/w/f04885/32.png) [@World\_Eater](https://boards.straightdope.com/u/World_Eater)\
**Post date:** [February 15, 2006, 10:42pm UTC](https://boards.straightdope.com/t/quick-html-question/344701/9 "2006-02-15T22:42:52Z")

</div>

Two things to mention.

1. That orange panel that links are in is an iframe, could that affect behavior?

2. the Css is within the head of the html file. Would it help if I made it global?

---

<div class="post-metadata">

**Author:** ![Tevildo](https://avatars.discourse-cdn.com/v4/letter/t/b9bd4f/32.png) [@Tevildo](https://boards.straightdope.com/u/Tevildo)\
**Post date:** [February 15, 2006, 10:47pm UTC](https://boards.straightdope.com/t/quick-html-question/344701/10 "2006-02-15T22:47:46Z")

</div>

It’s simpler than that.

In the \<A\> tags, you should have class=“musiclink” rather than class=musiclink.

---

<div class="post-metadata">

**Author:** ![gotpasswords](https://avatars.discourse-cdn.com/v4/letter/g/c57346/32.png) [@gotpasswords](https://boards.straightdope.com/u/gotpasswords)\
**Post date:** [February 15, 2006, 10:51pm UTC](https://boards.straightdope.com/t/quick-html-question/344701/11 "2006-02-15T22:51:44Z")

</div>

Soon as I hit post… You don’t really want visited posts to be permanently orange, right? 😃

Looks like the styles are defined in the [wrong order.](http://www.yourhtmlsource.com/stylesheets/csslinks.html) Try re-arranging them as:

.musiclink:link {color: blue; font-weight: bold;}  
.musiclink:visited {color: blue; font-weight: bold;}  
.musiclink:hover {color: orange; text-decoration: underline; font-weight: bold;}  
.musiclink:active {color: blue; font-weight: bold

---

<div class="post-metadata">

**Author:** ![World\_Eater](https://avatars.discourse-cdn.com/v4/letter/w/f04885/32.png) [@World\_Eater](https://boards.straightdope.com/u/World_Eater)\
**Post date:** [February 15, 2006, 10:57pm UTC](https://boards.straightdope.com/t/quick-html-question/344701/12 "2006-02-15T22:57:36Z")

</div>

Nice guys, I knew it was me, because the behavior was the same on mac and pc and ff and Ie.

One other question. Does the link stay underlined unless I specifically use text decoration none?

---

<div class="post-metadata">

**Author:** ![jjimm](https://avatars.discourse-cdn.com/v4/letter/j/ba8739/32.png) [@jjimm](https://boards.straightdope.com/u/jjimm)\
**Post date:** [February 15, 2006, 11:02pm UTC](https://boards.straightdope.com/t/quick-html-question/344701/13 "2006-02-15T23:02:01Z")

</div>

I can’t get it to recreate your error (Firefox and IE on Win2K). Never had the problem myself, but I have had strange mouseover problems before in IE, and it was down to the format of the CSS tag.

Two things to try:

1. Change the “musiclink” tags to the following format respectively:

A.musiclink { }  
A:hover.musiclink { }  
A:visited.musiclink { }  
A:active.musiclink { }

1. I managed to recreate one link not working after I’d clicked it , because the “active” tag doesn’t tell it to, and the link was left in an active state once it had been clicked (because another page had launched and the browser had re-focussed on it). I recommend you remove the “active” tag altogether; don’t know if this will avoid it, but it isn’t really necessary.

No guarantees that either of these things will work, but worth a try.

BTW, the iFrame and placement of the style instruction shouldn’t make any difference.

PS shame on you for using frames. Grr.

---

<div class="post-metadata">

**Author:** ![fluiddruid](https://avatars.discourse-cdn.com/v4/letter/f/c2a13f/32.png) [@fluiddruid](https://boards.straightdope.com/u/fluiddruid)\
**Post date:** [February 15, 2006, 11:36pm UTC](https://boards.straightdope.com/t/quick-html-question/344701/14 "2006-02-15T23:36:30Z")

</div>

This really isn’t Cafe Society material. I’ll move this thread to General Questions.

---

<div class="post-metadata">

**Author:** ![World\_Eater](https://avatars.discourse-cdn.com/v4/letter/w/f04885/32.png) [@World\_Eater](https://boards.straightdope.com/u/World_Eater)\
**Post date:** [February 15, 2006, 11:39pm UTC](https://boards.straightdope.com/t/quick-html-question/344701/15 "2006-02-15T23:39:49Z")

</div>

Thanks all, problemo solved.

Just out of curiosity **JJimm** , what’s wrong with using frames? I couldn’t fathom doing this layout in CSS.

---

<div class="post-metadata">

**Author:** ![jjimm](https://avatars.discourse-cdn.com/v4/letter/j/ba8739/32.png) [@jjimm](https://boards.straightdope.com/u/jjimm)\
**Post date:** [February 16, 2006, 8:56pm UTC](https://boards.straightdope.com/t/quick-html-question/344701/16 "2006-02-16T20:56:47Z")

</div>

Well I’m probably being unfair. I work in corporate websites, and the use of frames is pretty much banned in my world - here’s an edit of an email I wrote to someone recently on the same subject:

> [@](#):
>
> The search engine spider will look at the site’s index page for site content. It will find nothing, because the index page is a frameset instruction with no text.
> 
> If the spider can be bothered to follow the frame links, and Google _does_ actually index the site, someone doing a search gets a nice link on Google to your search terms, but ends up getting a sub-frame when they click the link. So when they load it in, it has the content, but no navigation elements on it, nor does it have any company branding. The punter can’t get anywhere else in your website and will leave it. Bye bye prospect. There are of course bits of code to make sure that if someone hits a sub-frame the browser jumps to the main frame, but JS redirects are frowned upon by search engines.
> 
> Another major problem: I’m Joe Punter and I want to send my colleage John Doe an interesting URL from the Acme Co. site. Can I? No I can’t, because it’s buried in a frameset and the browser only ever displays the main frame page, which is index.html. I therefore have to email John Doe “go to this site, hit ‘products’, then ‘gizmos’ then bla bla bla”. Either that or I just give up, and that little piece of word-of-mouth marketing is lost.

Most of these consideration probably don’t apply to your site. As for building it in CSS, I agree - nightmare. Personally I’d use tables and just repeat the tableset per page - once the images are cached it shouldn’t take too long to load in - but I’m probably a bit old-skool.

Having said all that, it looks great (as did your last one). Do you do the graphics too?
