Jump to:

5514 Posts in 1733 Topics by 1219 members

Customising the CMS

SilverStripe Forums » Customising the CMS » Download image in Model Admin

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

Page: 1
Go to End
Author Topic: 753 Views
  • swaiba
    Avatar
    Forum Moderator
    1784 Posts

    Re: Download image in Model Admin Link to this post

    Hi,

    I temporarily hacked my system for this...
    sapphire\templates\FileIFrameField.ss

    you can probably put this in you mysite templates folder to override it without affecting the "core"

    <!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>
          <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />
          <% base_tag %>

          <title><% _t('TITLE', 'Image Uploading Iframe') %></title>
       </head>

       <body>
          <div class="mainblock editform">
             $EditFileForm
          </div>

          <% if AttachedFile %>
             <div class="mainblock">
    <!-- start hack -->
                <a href="$AttachedFile.Link" target="_new">$Name</a>
    <!-- end hack -->
                $AttachedFile.CMSThumbnail

                <% if DeleteFileForm %>
                   $DeleteFileForm
                <% end_if %>
             </div>
          <% end_if %>
       </body>

    </html>

    753 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.