Anyone ever try to load up view files directly from the CMS?

edited May 2013 in Modules
Hi everyone,

I've been using fuelcms for a few weeks now. So far, I'm really liking it. Some areas have been tough but my overall experience so far has been positive. I'll be pushing out a website soon with it, and I'm very happy I chose fuelcms to build on top of. Saved me days, if not months, of time by not having to build my own cms.

Anyway, I was wondering if anyone has ever tried to build a module that allows you to update static view pages directly from the CMS? For example, allowing users to modify the view files for /application/views/_blocks and application/views/home.php

Thanks!

Comments

  • edited 2:04AM
    I don't know of any modules at the moment. To do that would require those folder to be writable. As an alternative, you can use FUEL's import functionality which allows you to edit view files at the same location path and it will allow you to import those views into the pages module in the cms if it sees a last modified date after the last time the page was saved in the CMS. By default, it will load the view contents into the "body" variable. The same feature exists for blocks.
  • edited 2:04AM
    when i try to add the following code within a block using CMS, it won't save. it works for simple html code like

    test



    Interested in in-home tutoring?

    Click here to see if it's available in your area.



  • edited 2:04AM
    Update: I was able to find a work-around. I saved the block of code on my local machine then uploaded it. It works now... but for some reason, if I add certain html directly through the CMS, it won't save properly...
  • edited 2:04AM
    Can you post the code you were trying (you can wrap it in "code" tags for it to appear in the forum)? Did the code perhaps have special characters or was there anything like an iframe or javascript code?
  • edited May 2013
    Here's the code:
    
    <div class="row">
    <div class="span12 center">
    <div class="well well-contact_us">
    <h4>Interested in in-home tutoring?</h4>
    
    <p><a class="iframe" href="#" style="text-decoration: underline;">Click here</a> to see if it's available in your area. Or you can call us at <strong>(999) 999-9999</strong>.</p>
    </div>
    </div>
    </div>
    
    What's odd is that even if I strip it out most of the html, including the word iframe, it still doesn't save properly.. I tried:
    <p><a class="" href="#" style="text-decoration: underline;">Click here</a> to see if it's available in your area. Or you can call us at <strong>(999) 999-9999</strong>.</p>
    Not sure if it matters, but I am using ckeditor. I tried switching to the original editor also but still no luck. Odd..
  • edited 2:04AM
    Try removing the inline style and see if that helps. I've had problems with CKEditor and inline styles.
Sign In or Register to comment.