Jump to:

23368 Posts in 18143 Topics by 2863 members

General Questions

SilverStripe Forums » General Questions » displaying image of another page

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: 654 Views
  • Rishi
    Avatar
    Community Member
    97 Posts

    displaying image of another page Link to this post

    hello
    i have created a template where i am inserting a image via image filed in cms,i want to display this image into another page,so that if i create 6 different page with this template and insert an image in all this 6 pages, then thumbnail of all the pages will be displayed in the holder page.my site tree is like this

    -Teacher
    -student
    -Universities
    --university 1
    --university 2
    --university 3
    --university 4
    --university 5
    --university 6
    -about us
    -Contact us
    what i want is in page university1,university2,university3,university4,university5,university6 there will be a provision of uploading a image(not through default editor) and that image will be displayed on page Universities along with a link on it so that when anyone click on the image in page Universitiesc it will open the corresponding page in which it is inserted.
    Code will be a great help as i am new in silverstripe.

    thank you in advance

  • carlos
    Avatar
    Community Member
    41 Posts

    Re: displaying image of another page Link to this post

    Hi Rishi,

    So you want to create a template to display pages under Universities?

    if that's what you want, you can use <% control Children %> in your template, it will list all page children

    <% control Children %>
    $Title
    $Image
    <% end_control %>

    this will list all children title and image

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