Jump to:

23493 Posts in 18996 Topics by 2878 members

General Questions

SilverStripe Forums » General Questions » Images not displaying in content editor

General questions about getting started with SilverStripe that don't fit in any of the categories above.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Page: 1
Go to End
Author Topic: 826 Views
  • steveo
    Avatar
    Community Member
    4 Posts

    Images not displaying in content editor Link to this post

    I'm picking up a site that has been designed another web diesgner and they have images on their pages within their content, but it's not displaying up in their editor, at first I thought it was a CSS or .ss hack/build but it's not... even when I select the HTML option it's not coming up in the HTML viewer... Any thoughts?

  • Aram
    Avatar
    Community Member
    598 Posts

    Re: Images not displaying in content editor Link to this post

    Hi Stevo,

    If the images are not in the WYSIWYG HTML then they must be being inserted some other way. Could you post the .ss file for that page. Are there any JS files being included in the page? Try removing all the Requirements in Page.ss so it just outputs the template HTML and see if the images are still there.

    Aram

    ---------------------------------------------------------------------------------

    www.ssbits.com - Your one stop SilverStripe learning resource

  • steveo
    Avatar
    Community Member
    4 Posts

    Re: Images not displaying in content editor Link to this post

    Hi Aram,

    Thanks for your reply, this is the page.ss file below. At the moment I've gotten around it by simply replacing the images with a white 1 pixel image with the same file name, but I'd like to fix it properly.

    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml" lang="en" >

    <head>
          <% base_tag %>
          $MetaTags
          <link rel="shortcut icon" href="/favicon.ico" />
          
          <!--[if IE 6]>
             <style type="text/css">
              @import url(themes/blackcandy/css/ie6.css);
             </style>
          <![endif]-->
          
          <!--[if IE 7]>
             <style type="text/css">
              @import url(themes/blackcandy/css/ie7.css);
             </style>
          <![endif]-->
    <title>$Title</title>
       </head>
    <body>
    <div id="wrap">
    <div id="header" >
    <a href="/"><h1 class="logo"><span>TAPS Training and Apprentice Plumbing Service</span></h1></a>

    <div id="Navigation">
             <% include Navigation %>
           </div>
    </div>      

    <% if Level(3) %>
          <div id="main" class="level3">
       <% else %>
       <div id="main" class="level2">
       <% end_if %>
        <div id="subNav">

             <% include SideBar %>
    </div>   
       
           $Layout
       
       
       <% if Level(3) %>
          </div>
          
       <% else %>
       
       </div>
       <% end_if %>
       
       

       <div id="Footer">
          <% include Footer %>
    </div><!--end foooter-->
    </div><!--end wrap-->

    </body>
    <script type="text/javascript">
    var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
    document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
    </script>
    <script type="text/javascript">
    try {
    var pageTracker = _gat._getTracker("UA-7838523-1");
    pageTracker._trackPageview();
    } catch(err) {}</script>
    </html>

  • Ryan M.
    Avatar
    Community Member
    309 Posts

    Re: Images not displaying in content editor Link to this post

    You pasted the top-level Page.ss template. Dig deeper into the Layout folder and find the right template.

    826 Views
Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.