[wp-hackers] Best way to create a "page" with plugin?

Ian Barber ian.barber at gmail.com
Tue Nov 28 10:53:40 GMT 2006


I like the content replacing method as above, though it would be nice to
have a method for excluding pages from being displayed by wp_list_pages and
the like. I know wp_list_pages itself has a filter, but you get the HTML
version which makes me a little worried that the markup will change and
cause the removing to break.

On 11/27/06, Rob <r at robm.me.uk> wrote:
>
> On 27/11/06, Firas Durri <firasd at gmail.com> wrote:
> >
> > On 11/27/06, Rob <r at robm.me.uk> wrote:
> > > On 27/11/06, Matt Mullenweg <m at mullenweg.com> wrote:
> > > >
> > > > Rob wrote:
> > > > > Is there a better way to create what is in effect a page? I'm
> > thinking
> > > > no,
> > > > > since themes vary so much, but here's hoping! :k
> > > >
> > > > What I've seen done that is neat is simply asking people to put in a
> > > > static string, like %%CONTACTFORM%%, in any post/page they want your
> > > > stuff to appear. Then just strstr for that, and if it's there
> > > > str_replace in a filter on post_content.
> > > >
> > > > --
> > > > Matt Mullenweg
> > > >   http://photomatt.net | http://wordpress.org
> > > > http://automattic.com | http://akismet.com
> > > > _______________________________________________
> > > > wp-hackers mailing list
> > > > wp-hackers at lists.automattic.com
> > > > http://lists.automattic.com/mailman/listinfo/wp-hackers
> > > >
> > >
> > > This is actually what I ended up doing for the new plugin I'm working
> > on,
> > > since I prefer the customisation it offers. It's not practical for
> every
> > > plugin, though--certainly nothing massively complex or dynamic.
> > >
> > > --
> > > Rob Miller
> > > http://robm.me.uk/
> >
> > Can you describe said complexity or dynamism? If you really want to
> > 'create a page' you should probably use wp_insert_post() ?
> > _______________________________________________
> > wp-hackers mailing list
> > wp-hackers at lists.automattic.com
> > http://lists.automattic.com/mailman/listinfo/wp-hackers
> >
>
> Just display output like this: http://robm.me.uk/library/ (click any of
> the
> books, etc.)
>
> I don't want to create a page and wp_insert_post is not particularly
> relevant.
>
> --
> Rob Miller
> http://robm.me.uk/
> _______________________________________________
> wp-hackers mailing list
> wp-hackers at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/wp-hackers
>


More information about the wp-hackers mailing list