Web Hosting, Design, & Coding forum

General discussion

href="file:///C:/ not working

by vmars956 / December 15, 2008 9:11 AM PST

Thanks in advance!

I can't figure out WHY this link does not work. No action when I click on it.

<P align=center><FONT face="Eras Medium ITC" size=4><A
href="file:///C:/Documents%20and%20Settings/Vernon%20Marsden/My%20Documents/bookmark.htm"> A60 bookmark.htm</A>

Its the same address as my local home page.


Discussion is locked
You are posting a reply to: href="file:///C:/ not working
The posting of advertisements, profanity, or personal attacks is prohibited. Please refer to our CNET Forums policies for details. All submitted content is subject to our Terms of Use.
Track this discussion and email me when there are updates

If you're asking for technical help, please be sure to include all your system info, including operating system, model number, and any other specifics related to the problem. Also please exercise your best judgment when posting in the forums--revealing personal information such as your e-mail address, telephone number, and address is not recommended.

You are reporting the following post: href="file:///C:/ not working
This post has been flagged and will be reviewed by our staff. Thank you for helping us maintain CNET's great community.
Sorry, there was a problem flagging this post. Please try again now or at a later time.
If you believe this post is offensive or violates the CNET Forums' Usage policies, you can report it below (this will not automatically remove the post). Once reported, our moderators will be notified and the post will be reviewed.
Collapse -
What you need to know.
by R. Proffitt Forum moderator / December 15, 2008 9:42 AM PST
Collapse -
How should I code this local link?
by vmars956 / December 17, 2008 6:31 AM PST
In reply to: What you need to know.

In IE6 when I specify the following for (Tools!Internet Options!HomePage Address):
C:\Documents and Settings\V Mars\My Documents\My Home Page -ppHomePg.htm
IE6 (Tols) changes it to the following:
When IE6 then displays the page, it shows the address as:
C:\Documents and Settings\V Mars\My Documents\My Home Page -ppHomePg.htm

the Source Html shows:
href="file:///C:/Documents%20and%20Settings/Vernon%20Marsden/My%20Documents/bookmark.htm"] A60 bookmark.htm[/A]
(I replaced [ for <, and ] for >)

So, please, how should I code this local link?

Can you see anything inherently wrong with my code?


Collapse -
The %20 is just a space character in HTML
by MarkFlax Forum moderator / December 17, 2008 6:38 AM PST

but I see a difference in the two examples you gave.

When you specify the Home Page in IE6 the path includes V%20Mars, in effect it is the V Mars directory.

But in the (a href) anchor, you have specified Vernon%20Mars, or the Vernon Mars directory.

Is there such a directory as Vernon Mars?


Collapse -
oops! my typo
by vmars956 / December 17, 2008 8:33 AM PST

No its just a typo, getting ready to post it here.
I wanted to encrypt my actual name.
They are all supposed to be:


The question remains "How can I code a local link?"


Collapse -
OK, :)
by MarkFlax Forum moderator / December 17, 2008 7:47 PM PST
In reply to: oops! my typo

Other than what I said, I can't see anything inherently wrong with the (a href="") entry, and I have used similar many times when I write my own html.

For example, I use my own web pages in my browsers, not published, just to allow me to quickly navigate within my computer, and one of them is as follow;
(a href="../Work%20related/favourites.html" target="Display")(b)Bookmarks(/b)(/a).

(I am British, so I spell 'Favorites' properly Devil ).

The link is enclosed in quotes, it has a space signified by %20, and targets to a Frames component. The ../ is my HTML editor's way of truncating paths back through directories, and is standard format for HTML.

But when I mouse over the link I see;
so I see nothing significantly different to your entry below;
[A href="file:///C:/Documents%20and%20Settings/V%20Marsden/My%20Documents/bookmark.htm"]Text[/A]

(I used Text to allow the line to fit into the post window boundaries).

I can only suggest these options;

1] Are you using an HTML editor? If so, can you use that to create the link and navigate to the Bookmark.htm file?

2] If you are not, can you code the (a href) anchor with ../../../, etc, as many as required to move back through the directories?

3] In your browser, when you mouse over that link, what is displayed? How does that differ from the path displayed in Windows Explorer when you navigate to the folder where this file is? (Note, I am talking about Windows Explorer, eg My Computer, My Documents, etc, and not IE).


Collapse -
by Kees Bakker / December 17, 2008 8:05 PM PST
In reply to: OK, :)

(I thought I'd posted this a few hours ago, but it seems not).

Use relative addresses (that work on both the website and the local hard disk) in stead of absolute addresses (file://, http://) to link to your 'own' files.

It's what I do, and what you do, and what the OP should do, because it surely works.

Just for experiment, I'll play with an absolute address to my own harddisk tonight in link (I see no good reason why it should work in the address bar and in a link to a stylesheet, and not in an <a>-link, so I want to see myself), but - of course - there's no need at all to ever use it.


Collapse -
I tried, and it worked with me.
by Kees Bakker / December 19, 2008 9:20 PM PST
In reply to: Summary.

This was my page (replace [ with < and ] with >):

[a href="http://www.google.com"]google[/a]
[a href="file://C:/oewint/index.htm"]oew from hard disk[/a]
[a href="file:///C:/oewint/kalender.htm"]kalender from hard disk with three slashes[/a]

All links, both the http: and the file: (with 2 or 3 times the /) worked perfectly (the .htm files were on my hard disk). File names with spaces should work also, but I didn't try if you replace a space by %20.


Collapse -
Stranger than fiction...
by vmars956 / December 21, 2008 8:38 AM PST

Yes, its quite strange. If I take this address:
[A href="file:///C:/Documents%20and%20Settings/V%20Marsden/My%20Documents/bookmark.htm"]Text[/A]
and modify it to some other files in the same folder.
Like: [A href="file:///C:/Documents%20and%20Settings/V%20Marsden/My%20Documents/BookmarkS.htm"]Text[/A]
[A href="file:///C:/Documents%20and%20Settings/V%20Marsden/My%20Documents/bookmark-OLD.htm"]Text[/A]

There is no problem with these, only with:
[A href="file:///C:/Documents%20and%20Settings/V%20Marsden/My%20Documents/bookmark.htm"]Text[/A]

If I just click on bookmark.htm , all is fine.
Or when I start up IE6, it has no probs opening home page file:
[A href="file:///C:/Documents%20and%20Settings/V%20Marsden/My%20Documents/bookmark.htm"]Text[/A]

Stranger than fiction, eh?

Collapse -
by MarkFlax Forum moderator / December 21, 2008 7:22 PM PST

OK, another test.

Take that bookmark.htm file and place it in the directory where your web page is, then change the [a][/a] anchor temporarily. EG;

[A href="file:///C:/Documents%20and%20Settings/V%20Marsden/My%20Documents/bookmark.htm"]Text[/A]

becomes; [a href="bookmark.htm"]Text[/a]

Does that work?

If so, then the fault must be in the path. If not, then the fault is in the file. Well, that's what logic says, but I often find logic doesn't work when I'm coding html, Happy

Then further tests, (if the above works), copy the bookmark.htm file to other locations, to see where it fails.

Good luck, and let us know what you find out.


Collapse -
via IE6 [File| Import and Export] option
by vmars956 / December 22, 2008 2:37 AM PST
In reply to: Yep.

Ok, I tried that with:
href="file:///C:/Program%20Files/Internet%20Explorer/bookmark.htm"] A60


Looking at the link above, it seems to have extra spaces etc..
So I retyped it and tried:
href="file:///C:/Program%20Files/Internet%20Explorer/bookmark.htm"] A60


[A href="file:///C:/Program%20Files/Internet%20Explorer/bookmark.htm"] A60


[A href="file:///C:/Documents and Settings/vmars/My

Documents/bookmark.htm"] A60 BookMark.htm[/A]

I didn't type in any newLine, except for in front of "[A" and I edited file 'My Home Page

-ppHomePg.htm' in NotePad.
File 'My Home Page -ppHomePg.htm' links to file '[A href="file:///C:/Documents and

Settings/vmars/My Documents/bookmark.htm"] A60 BookMark.htm[/A] '

But none of them work.

BTW:file 'bookmark.htm' is created by IE6, via IE6 [File| Import and Export] option.

File 'My Home Page -ppHomePg.htm' looks like this:

[!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"]
[!-- saved from url=(0125)file://C:\Documents and Settings\v mars\Local

Settings\Temporary Internet Files\Content.IE5\A3JMODSG\ppHomePg-OLD.htm

--][!-- saved from url=(0022)http://internet.e-mail

[META http-equiv=Content-Type content="text/html; charset=windows-1252"]
[META content="MSHTML 6.00.2900.2180" name=GENERATOR]
[META content=General name=rating]
[META content="0 days" name=revisit-after]
[META content="Vern mars support @parentpresent.org"

rev=made href="mailto:support @parentpresent.org"]
[BODY text=#ffffff vLink=#99d5a4 aLink=#c09090 link=#99d5a4 bgProperties=fixed
[P align=center][FONT face="Eras Medium ITC" size=4]
[TABLE cellSpacing=0 cellPadding=0 align=center border=1]
[TD align=center][!-- Begin HyperDictionary --]Hyper_Dictionary
[FORM action=http://www.hyperdictionary.com/dictionary method=get][INPUT
maxLength=255 size=25 name=define] [INPUT type=submit value="Search

Dictionary" name=Submit1] [/FORM][!-- End HyperDictionary --][/TD]
[TD align=center]          [/TD]
[TD align=center][!-- Begin Google SafeSearch --]Google_Safe_Search
[FORM action=http://www.google.com/search method=get][INPUT

size=25 name=q] [INPUT type=hidden value=name=safe] [INPUT

type=submit value=" Google Search " name=sa] [!-- End Google SafeSearch --][!--

Begin Inspiration --]
[TD align=center]  Inspiration   a - z [FORM
style="BORDER-RIGHT: #000000 1px solid; BORDER-TOP: #000000 1px solid;

BORDER-LEFT: #000000 1px solid; BORDER-BOTTOM: #000000 1px solid"
tempform="tempform"][INPUT title=" Inspirational Quotes !"


type=button value=" Quotes "]
[/FORM][/TD][!-- End Inspiration --][/TR][/TBODY][/TABLE][A

[P align=center][FONT face="Eras Medium ITC" size=4][A

[P align=center][FONT face="Eras Medium ITC" size=4][A

face="Eras Medium ITC" size=3]
[P align=center][FONT face="Eras Medium ITC" size=4][A
[P align=center][FONT face="Eras Medium ITC" size=4][A
href="file:///C:/Program%20Files/Internet%20Explorer/bookmark.htm"] A60


[A href="file:///C:/Program%20Files/Internet%20Explorer/bookmark.htm"] A60


[A href="file:///C:\Documents and Settings\v mars\My

Documents/bookmark.htm"] A60 BookMark.htm[/A]



20Home%20Page%20-ppHomePg.htm --]

[A href="http://www.webfnb.com/"
LAST_VISIT="1225562583" LAST_MODIFIED="1220891740"

National Bank Personal
LAST_VISIT="1225562583" LAST_MODIFIED="1220891835"
ADD_DATE="1220891835"]forums.cnet.com XP
face="Eras Medium ITC" size=3]
[!-- End of ppHomePgHDR.txt --][!-- End of ppSearch.txt

--][/TR][/TABLE][!-- End of ppSearch.txt --]

[P align=center][!-- End of ppParCenter.txt --]

[P align=center][FONT face="Eras Medium ITC" size=1]Thoughts become words.


become actions.


determines destiny!

[P align=center]Happy Trails! [/P][/FONT][/FONT][!-- End of

ppHomePgTRL.txt --][/FORM][/FONT][/BODY][/HTML]

Collapse -
Now that's confusing.
by MarkFlax Forum moderator / December 22, 2008 7:13 PM PST

I thought you were trying to build your own web site for your own use, (not published), and wanted IE to accept a link back to your Home Page. But in your post it seems you are taking elements from your TIF folder, (Temporary Internet Files). This is purely a cache for IE, and is likely to be replaced regularly as you surf the internet and the cache refreshes. So that could be one problem.

The other one is, as Bob Proffitt said awhile ago, spaces. It didn't strike me at the time but these "Jive" forums strips spaces out of posts. For example, the spaces between the two words here, "Mark Flax", has been typed with 2 spaces. But Jive strips one, and just leaves one space. Because of that, any example you have given before, which you have copied and pasted into your posts, if there is more than one consecutive space anywhere, Jive strips one out. That makes it very difficult for us to error check.

Can you tell us more about this Home Page. Is it your own, or is it one from a web site where it gives the option of "Make this your Home Page now", pages?


Collapse -
See those spaces?
by R. Proffitt Forum moderator / December 17, 2008 8:27 AM PST

Now where is the quote mark?

I must stop here as I can't teach why we must use quote marks when our file paths have a space.

Collapse -
by semiller27 / December 15, 2012 5:41 AM PST

Because it is a local file and it can only be opened on a local desktop computer because the file is too big for a phone storage memory.

Popular Forums

Computer Newbies 10,686 discussions
Computer Help 54,365 discussions
Laptops 21,181 discussions
Networking & Wireless 16,313 discussions
Phones 17,137 discussions
Security 31,287 discussions
TVs & Home Theaters 22,101 discussions
Windows 7 8,164 discussions
Windows 10 2,657 discussions


Your favorite shows are back!

Don’t miss your dramas, sitcoms and reality shows. Find out when and where they’re airing!