6 Replies Latest reply on Nov 14, 2010 1:23 PM by hincauti

    SSI doesn't bring image files on the page.

    hincauti Level 1

      Hi, I'm using DW CS5. On my webiste I have an SSI file which is included on my home page index.shtml. Now, SSI file contains a table with image place holders in it. When I'm replacing the image place holder with a real image file, it doesn't show up on index.shtml in DW and browser either (instead of jpg file I have this error.jpg) . I'm using localhost server and all folders were uploaded on my server from my local directory.

       

      Thanks!

        • 1. Re: SSI doesn't bring image files on the page.
          John Waller Adobe Community Professional & MVP

          It's probably a file path issue. Without seeing the code, it's hard to help further. Can you paste it here?

          • 2. Re: SSI doesn't bring image files on the page.
            hincauti Level 1

            index.shtml file

             

            <!--#include file="includes/tbo_table.html" -->
            <!-- Dreamweaver begin include contents: C:\Data\Web\MyOnlineTheatre.com\includes\tbo_table.html -->
            <table width="100%" border="0" cellspacing="0" cellpadding="0">
                  <tbody><tr align="center" valign="middle">
                    <td width="80" height="116"><img src="../movies/saw_3d_2010/images/saw_3d_main_small.jpg" alt="" name="top_box_1" width="75" height="111" id="top_box_" style="background-color: #E2DB45"></td>
                    <td width="80" height="116"><img src="" alt="" name="top_box_2" width="75" height="111" id="top_box_2" style="background-color: #E2DB45"></td>
                    <td width="80" height="116"><img src="" alt="" name="top_box_3" width="75" height="111" id="top_box_3" style="background-color: #E2DB45"></td>
                    <td width="80" height="116"><img src="../movies/saw_3d_2010/images/saw_3d_main_small.jpg" alt="" name="top_box_4" width="75" height="111" id="top_box_4" style="background-color: #E2DB45"></td>
                    <td width="80" height="116"><img src="" alt="" name="top_box_5" width="75" height="111" id="top_box_5" style="background-color: #E2DB45"></td>
                    <td width="80" height="116"><img src="" alt="" name="top_box_6" width="75" height="111" id="top_box_6" style="background-color: #E2DB45"></td>
                    <td width="80" height="116"><img src="" alt="" name="top_box_7" width="75" height="111" id="top_box_7" style="background-color: #E2DB45"></td>
                    <td width="80" height="116"><img src="" alt="" name="top_box_8" width="75" height="111" id="top_box_8" style="background-color: #E2DB45"></td>
                    <td width="80" height="116"><img src="" alt="" name="top_box_9" width="75" height="111" id="top_box_9" style="background-color: #E2DB45"></td>
                    <td width="80" height="116"><img src="" alt="" name="top_box_10" width="75" height="111" id="top_box_10" style="background-color: #E2DB45"></td>
                  </tr>
                  <tr>
                    <td height="40" align="center" class="index_a_z">saw 3d</td>
                    <td> </td>
                    <td> </td>
                    <td> </td>
                    <td> </td>
                    <td> </td>
                    <td> </td>
                    <td> </td>
                    <td> </td>
                    <td> </td>
                  </tr>
                </tbody></table>
            <!-- Dreamweaver end include contents -->

             

            SSI file:

             

             

            <table width="100%" border="0" cellspacing="0" cellpadding="0">
                  <tr align="center" valign="middle">
                    <td width="80" height="116"><img src="../movies/saw_3d_2010/images/saw_3d_main_small.jpg" alt="" name="top_box_1" width="75" height="111" id="top_box_" style="background-color: #E2DB45" /></td>
                    <td width="80" height="116"><img src="" alt="" name="top_box_2" width="75" height="111" id="top_box_2" style="background-color: #E2DB45" /></td>
                    <td width="80" height="116"><img src="" alt="" name="top_box_3" width="75" height="111" id="top_box_3" style="background-color: #E2DB45" /></td>
                    <td width="80" height="116"><img src="../movies/saw_3d_2010/images/saw_3d_main_small.jpg" alt="" name="top_box_4" width="75" height="111" id="top_box_4" style="background-color: #E2DB45" /></td>
                    <td width="80" height="116"><img src="" alt="" name="top_box_5" width="75" height="111" id="top_box_5" style="background-color: #E2DB45" /></td>
                    <td width="80" height="116"><img src="" alt="" name="top_box_6" width="75" height="111" id="top_box_6" style="background-color: #E2DB45" /></td>
                    <td width="80" height="116"><img src="" alt="" name="top_box_7" width="75" height="111" id="top_box_7" style="background-color: #E2DB45" /></td>
                    <td width="80" height="116"><img src="" alt="" name="top_box_8" width="75" height="111" id="top_box_8" style="background-color: #E2DB45" /></td>
                    <td width="80" height="116"><img src="" alt="" name="top_box_9" width="75" height="111" id="top_box_9" style="background-color: #E2DB45" /></td>
                    <td width="80" height="116"><img src="" alt="" name="top_box_10" width="75" height="111" id="top_box_10" style="background-color: #E2DB45" /></td>
                  </tr>
                  <tr>
                    <td height="40" align="center" class="index_a_z">saw 3d</td>
                    <td> </td>
                    <td> </td>
                    <td> </td>
                    <td> </td>
                    <td> </td>
                    <td> </td>
                    <td> </td>
                    <td> </td>
                    <td> </td>
                  </tr>
                </table>

            • 3. Re: SSI doesn't bring image files on the page.
              hincauti Level 1

              Images are showing up on SSI file "tbo_table.html" but does not showing when I include it on index.shtml. index.shtml shows up just the table without images on it, so that means the path tot the included file is correct.

              • 4. Re: SSI doesn't bring image files on the page.
                Nancy OShea Adobe Community Professional & MVP

                The trick to working with includes is remembering that paths to images and other assets need to be relative to the parent document containing the include statement; not the include file.

                 

                Once the server parses the include into your web page, those leading dots and slashes on your image path won't work.

                 

                You can use an absolute URL to the image file "http://yourdomain.com/images/image.jpg" or simply remove the leading dots and slashes from the image path in your include file.

                 

                 

                Nancy O.
                Alt-Web Design & Publishing
                Web | Graphics | Print | Media  Specialists
                http://alt-web.com/
                http://twitter.com/altweb

                1 person found this helpful
                • 5. Re: SSI doesn't bring image files on the page.
                  MurraySummers Level 8

                  You can use an absolute URL to the image file "http://yourdomain.com/images/image.jpg" or simply remove the leading dots and slashes from the image path in your include file.

                   

                  The latter half of Nancy's suggestion is to use ROOT relative links in your include files.  You should always use only root relative links in include files.

                  • 6. Re: SSI doesn't bring image files on the page.
                    hincauti Level 1

                    Thanks a lot, It worked! I renamed the files deleting "_" characters and when selecting an image file for image place holders I changed Relative to "Site Root" instead of "Document" which is by default option.

                     

                    Thank you Nancy and Murray for your help!