Barry wrote:
> Thanks to all who replied to my post. But many of you are missing
> the point
> of what I was trying (apparently poorly :) to say. Here's another attempt.
>
> I have a new client. I ftp their site files to my local system. I go to
> open a page, any page, and nearly all the images are broken and the links
> don't work. I know I have all the files on my system in the same directory
> structure as is on the server. With me so far?
>
> It turns out that the reason they don't work on my local system (which is
> _not_ running a web server!) is that the paths are coded as
> absolute paths.
> So of course they don't work on my local drive.
>
> Now, if the original site designer had coded relative paths, they would
> work on the server and work on my local drive. But they didn't. This seems
> foolish to me. The orginal designer could of course sit in their
> web design
> shop on a system running a server and everything would be fine. I'm not in
> that situation.
>
> For me to sit at my local system, edit a page (coded with absolute paths),
> upload it to the server and test it to make sure my editing looks
> the way I
> want in the browser, is time-consuming and inefficient. I want to edit and
> preview it locally. But with the pages coded with absolute paths I can't.
>
>
> >Hmmm...is anyone on the list running a web server on their local system
> >(like WebStar for Mac) who knows from experience that /images links work
> >when your local machine is also a server? I'd be interested in knowing
> >that....
>
> And Tamara, that is my next question :>) I know nothing about running a
> web server. What about either of the two free Mac web servers out there:
>
> The common lisp hypermedia server
> http://www.ai.mit.edu/projects/iiip/doc/cl-http/home-page.html
>
> httpd4MaC
> http://sodium.ch.man.ac.uk/pages/httpd4Mac/home.html
>
> are these hard to set up? Are they solid and reliable? I don't like to
> install software on my Mac that I know nothing about. If I run them on my
> local system, will the web files coded with absolute paths work
> properly? I
> don't want to re-code over 100 html pages!
Barry, I can't answer your questions about the Mac web servers, but I can
say that setting up a web server on your machine will probably be the "least
sloppy" way to "solve" (converting to relative paths would provide more
portability) your problem. On Win95/98 or NT installing web server software
is pretty simple...chances are that the Mac packages are relatively easy to
setup, too.
After you setup the web server, you'll need to map the directory that you've
copied the html files into so that the files will load through the web
server. In other words, there will be a utility that comes with your web
server that will allow you to set it up so that:
c:\projects\newproject (or the Mac equivalent)
maps to the url:
http://yourlocalserver/
This way, you'll be able to load the file:
c:\projects\newproject\whatever.html
by loading the url:
http://yourlocalserver/whatever.html
The subdirs of your project will all fall in line, so:
http://yourlocalserver/this/that/images/image1.gif
will load:
c:\projects\newproject\this\that\images\image1.gif
Make sense?
Your other alternative is to do a search and replace on all files, replacing
the absolute paths with relative paths. If you want to go that route, and
need some tips, let me know.
Jack
____________________________________________________________________
--------------------------------------------------------------------
Join The Web Consultants Association : Register on our web site Now
Web Consultants Web Site : http://just4u.com/webconsultants
If you lose the instructions All subscription/unsubscribing can be done
directly from our website for all our lists.
---------------------------------------------------------------------