I appreciate the reasons "why not" but i'm trying to go for user-generated
content...

Would you have concerns with cake *generating* the content (i.e. parsing the
element, returning the output HTML) and then including that in the database
to be retrieved alter? kinda like using the database to perma-cache elements
or helper output?



On Wed, Oct 13, 2010 at 3:17 AM, Miles J <[email protected]> wrote:

> My suggestion, don't do any of what you asked in your first post.
>
> Either do straight HTML without connecting to Cake, or use a custom
> markup like BBCode and parse it yourself.
>
> On Oct 11, 5:29 pm, Greg Skerman <[email protected]> wrote:
> > Figured it out - well at least the process..
> >
> > going to have the users 'insert' elements via ajax - rendered ajax
> response
> > containing the element will be inserted into the page (straight HTML and
> > javascript) - that way the pages effectively cache the elements.
> >
> > means I can't have users insert dynamic content but thats no big loss,
> > landing pages probably shouldn't have/need dynamic content.
> >
> > On Mon, Oct 11, 2010 at 9:13 AM, Greg Skerman <[email protected]>
> wrote:
> > > The "users" will be administrators..not any-old-person who wants to
> create
> > > pages.
> >
> > > I'm open to *not* including the php...as obviously this isn't very
> secure.
> >
> > > I guess what i'm asking, is where would i throw a regular
> > > expression/replace to take a comment such as
> <!---Element(name,params)--->
> > > to replace with the correct cake code?
> >
> > > beforeRender?
> >
> > > And where is the view output stored?
> >
> > > On Mon, Oct 11, 2010 at 8:46 AM, cricket <[email protected]>
> wrote:
> >
> > >> On Sun, Oct 10, 2010 at 9:18 AM, Greg Skerman <[email protected]>
> wrote:
> > >> > Hi,
> >
> > >> > I'm writing a little content manager, and for this i've decided to
> > >> rewrite
> > >> > the pages controller so that it is database driven.
> >
> > >> > I'm using TinyMCE and markitup as the editors to allow content to be
> > >> > created.
> >
> > >> > My issue is, how do I go about getting cakephp's automagic elements
> > >> working
> > >> > with this? obviously when a user creates an img tag, I would like to
> > >> convert
> > >> > this to a HTMLHelper tag to get around relative paths etc,
> >
> > >> Use img tags with absolute paths and be done with it.
> >
> > >> > but I also want
> > >> > to be able to allow the users to include elements and other helper
> code
> > >> in
> > >> > their pages.
> >
> > >> Now you're looking for trouble.
> >
> > >> > Is it a case of parsing the stored page and converting it on the fly
> to
> > >> > include these elements, or is there a way to safely store and later
> > >> evaluate
> > >> > saved php code?
> >
> > >> How much do you trust these users?
> >
> > >> Check out the new CakePHP Questions sitehttp://cakeqs.organd help
> > >> others with their CakePHP related questions.
> >
> > >> You received this message because you are subscribed to the Google
> Groups
> > >> "CakePHP" group.
> > >> To post to this group, send email to [email protected]
> > >> To unsubscribe from this group, send email to
> > >> [email protected]<cake-php%[email protected]>
> <cake-php%[email protected]<cake-php%[email protected]>>For
> more options, visit this group at
> > >>http://groups.google.com/group/cake-php?hl=en
>
> Check out the new CakePHP Questions site http://cakeqs.org and help others
> with their CakePHP related questions.
>
> You received this message because you are subscribed to the Google Groups
> "CakePHP" group.
> To post to this group, send email to [email protected]
> To unsubscribe from this group, send email to
> [email protected]<cake-php%[email protected]>For
>  more options, visit this group at
> http://groups.google.com/group/cake-php?hl=en
>

Check out the new CakePHP Questions site http://cakeqs.org and help others with 
their CakePHP related questions.

You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected] For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en

Reply via email to