Jump to:

23360 Posts in 18124 Topics by 2862 members

General Questions

SilverStripe Forums » General Questions » Working with XML and Database (CU3ER Slideshow).

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: 1312 Views
  • Vladas
    Avatar
    Community Member
    17 Posts

    Working with XML and Database (CU3ER Slideshow). Link to this post

    Hello.

    I've got a question about working with database and xml file. I've added a slideshow to my work, which reads data from XML file(it contains all the required information and URLs to files). More specifically - I'm working with CU3ER.

    Now what I need to do is to be able to work with the images. My CMS is ready, and I'm able to add, delete, edit images to the database in the SilverStripe admin control panel.

    The problem is that I want to connect CU3ER with the database. Should I use XML file as template and where images are defined, I should retrieve information from database?
    If yes, then how, because I've tried to use DB:sqlquery, but it can't find DB class(I don't know how can I access DB class from separate php file).

    Another way I thought of doing is to generate whole new xml file with entries of database(images) and save it in Page_Controller, so the CU3ER could read new XML file every single time the web is loaded.

    Any ideas and how can I work this out?

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