images not showing [SOLVED]

Problems with the Windows version of XAMPP, questions, comments, and anything related.

images not showing [SOLVED]

Postby tchboy » 22. January 2012 23:31

I have xampp running on my development machine and all is working well I have an image that is in a folder on my c drive formy project it needs to that there. In design view in dreamweaver it shows perfectly fine, but when I go to the preview in browser it dissapears. my tag is simple and is this entry.

<img src="file:///C:/movies/ghost/folder.jpg" width="107" height="107" />

I am thinking it's some sort of permissions problem but I don't see why it would have a problem when I can view in the design view of dream weaver.

thanks in advance for any help!!
tchboy
 
Posts: 14
Joined: 07. December 2011 12:04
Operating System: xp

Re: images not showing

Postby Sharley » 23. January 2012 00:34

DreamWeaver is not a web server and so can access files in folders outside the DocumentRoot which is the \xampp\htdocs folder of the Apache server - configuring DreamWeaver is not supported in this forum.

The Apache server can access files and folders in the DocumentRoot only by default...

...but there may be a solution for you in this on topic page of answers on the Stack Overflow Q&A web site or the DW web site may also have a configuration solution.

Please let us know if you were successful in finding a solution.

Good luck.:)
User avatar
Sharley
AF Moderator
 
Posts: 3316
Joined: 03. October 2008 05:10
Location: Yeppoon, Australia Time Zone: GMT/UTC+10
Operating System: Win 7 Pro 32bit/XP Pro SP3

Re: images not showing

Postby tchboy » 23. January 2012 12:28

I think the alias way is the way to go, think I may have misunderstood something. but say for example the image I want to display is

c:\my_movies\StarWars\folder.jpg

Am i creating an alias Alias /mymovies c:/mymovies

In design view dreamweaver won't display it correctly but when I change to the live view in browser it will display correctly?

this is just a design machine and since I am new to this is it possible to get the image to display in design and live environment
tchboy
 
Posts: 14
Joined: 07. December 2011 12:04
Operating System: xp

Re: images not showing

Postby tchboy » 23. January 2012 12:38

Meant to say I am making the link /mymovies to c:/mymovies as the next level down is my film collection and eventually I would like the web page display all the films I have

thanks
tchboy
 
Posts: 14
Joined: 07. December 2011 12:04
Operating System: xp

Re: images not showing

Postby JonB » 23. January 2012 15:21

You have the right idea with a Alias directive when referencing anything outside the DocumentRoot.

Good Luck
8)
User avatar
JonB
AF Moderator
 
Posts: 3210
Joined: 12. April 2010 16:41
Location: Land of the Blazing Sun
Operating System: Windows XP/7 - Fedora 15 1.7.7

Re: images not showing

Postby tchboy » 23. January 2012 15:40

so am I right in thinkning that the value for img src should be "/movies/ghost/folder.jpg". I dont have to include file:///C:??

Hope to see my images in the browser tonight.
tchboy
 
Posts: 14
Joined: 07. December 2011 12:04
Operating System: xp

Re: images not showing

Postby JonB » 23. January 2012 17:18

AFAIK, the Alias will need the complete path as the files are not in the ServerRoot.

Good Luck
User avatar
JonB
AF Moderator
 
Posts: 3210
Joined: 12. April 2010 16:41
Location: Land of the Blazing Sun
Operating System: Windows XP/7 - Fedora 15 1.7.7

Re: images not showing

Postby Altrea » 23. January 2012 18:09

:shock:
Do you want to create X Alias just because you have files in different folders in your harddisk you want to use in your project?

why don't you save image files relating to the webproject, INSIDE the webproject directory?
Thats for sure the cleanest and best way to work with it.
And Dreamweaver will love that behavior too.

best wishes,
Altrea
We don't provide any support via personal channels like PM, email, Skype, TeamViewer!

It's like porn for programmers 8)
User avatar
Altrea
AF Moderator
 
Posts: 11935
Joined: 17. August 2009 13:05
XAMPP version: several
Operating System: Windows 11 Pro x64

Re: images not showing

Postby tchboy » 23. January 2012 19:09

I am moving all my dvds on to my harddisc in the folder mymovies, i would rather the webpage read them from that location, instead of copying everything into my website folder.
tchboy
 
Posts: 14
Joined: 07. December 2011 12:04
Operating System: xp

Re: images not showing

Postby JonB » 23. January 2012 19:31

Altrea is both right about Dreamweaver, and from a tidiness and debugging point of view, it decreases the likelihood of problems, particularly if you want to use other's scripts.

Good Luck
8)
User avatar
JonB
AF Moderator
 
Posts: 3210
Joined: 12. April 2010 16:41
Location: Land of the Blazing Sun
Operating System: Windows XP/7 - Fedora 15 1.7.7

Re: images not showing

Postby tchboy » 24. January 2012 09:00

It worked first time now that is a first!! I may change things in future as I get further into this, thanks for everyone's help. Much appreciated.
tchboy
 
Posts: 14
Joined: 07. December 2011 12:04
Operating System: xp

Re: images not showing

Postby Sharley » 24. January 2012 09:07

Thanks for the feedback and happy with your success.

I will close this topic and mark it solved.

Please feel free to start a new topic if you have other issues with XAMPP for Windows.

Best wishes. :)
User avatar
Sharley
AF Moderator
 
Posts: 3316
Joined: 03. October 2008 05:10
Location: Yeppoon, Australia Time Zone: GMT/UTC+10
Operating System: Win 7 Pro 32bit/XP Pro SP3


Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 112 guests