all groups > flash (macromedia) > november 2004 >
You're in the

flash (macromedia)

group:

Absolute vs Relative URI's etc...



Re: Absolute vs Relative URI's etc... urami_
11/14/2004 8:45:14 PM
flash (macromedia):

[quoted text, click to view]

It refer to files from the location of it's html holder.
Flash does not care where it lays on server. If you index.html is
in wasabi on the root , it will look for files from there not from it's
folder.




--


Regards


urami_*

<hol>
http://flashfugitive.com/
</hol>


By The way:
Absolute vs Relative URI's etc... bruce_code *BASE*
11/14/2004 9:25:36 PM
Hi All,

I spent half an hour or so going through many of the posts on linking, and I
didn't find anything that seems to so what I want, so I'm sorry if this has
already been asked...

I have my site root which contains my index.html, and within that folder, I
have a 'content' folder with all other pages and a 'flash' folder with my
one flash file in it. e.g.

f:\wasabi\wasabi\ (root & index.html)
f:\wasabi\wasabi\content\ (all other html)
f:\wasabi\wasabi\flash\ (wasabi.swf)

My problem is that the flash file appears in the index.html and in all the
other html files in the sub folder. I have tried
'getURL(/content/info.html);' and also 'getURL(../content/info.html);', but
neither works.

Does Flash reference the URL as relative to the site root, the flash file,
or to the HTML file from which the getURL is called?

When I tried the '/content/info.html' as the URL it tried to find a file in
the root of the hard drive (i.e. F:\), which it was never going to do
because the file is two folders deeper.
When I tried the '../content/info.html' it tried to go back down one folder,
therefore leading me to assume that it is relative to the calling HTML
document, which will screw up my whole folder layout...


Any help?


Thanks,

Bruce

Re: Absolute vs Relative URI's etc... bruce_code *BASE*
11/15/2004 9:12:07 AM
[quoted text, click to view]

Hi Urami_,

Thanks. Other than storing ALL my HTML files in the root with the
index.html, is there another way that I can get this to work? We use a
standard directory structure, and I'm reluctant to go against that. Is there
a way to use an 'IF' statement to detect what folder the HTML doc is in or
originates from? Maybe by error trapping (but I assume that error trapping
would cause a time lag)?

Thanks,

Bruce

Re: Absolute vs Relative URI's etc... urami_
11/15/2004 1:26:11 PM

i Urami_,
[quoted text, click to view]

You could always use absolute url http://www.name.com/folder/htm.html document.
this way it always find it w/o problem.
Also ,the /name/file.html should work , it always doe to me you just have to write the paths
from perspective of the html document which use flash , not from perspective of SWF file.
SWF will follow paths the document that calls it not paths from its location on server.



--


Regards


urami_*

<hol>
http://flashfugitive.com/
</hol>


By The way:
AddThis Social Bookmark Button