1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Custom page with submit form

Discussion in 'XenForo Development Discussions' started by grantus, Aug 7, 2015.

  1. grantus

    grantus Active Member

    I have a custom page setup in Xenforo which contains an iframe. Inside the iframe page is my custom PHP upload script. It works fine but I hate the idea of having an iframe because it's never consistent across browsers and mobile.

    So my question is - how can I have my custom upload script inside the Xenforo page? I know how to create a page with my own PHP code in it, but with my upload form I get an error when I try to submit.

    I have my form action as REQUEST_URI which works fine on its own, but of course Xenforo doesn't like it. Is there a workaround?

  2. Lawrence

    Lawrence Well-Known Member

    I use a page callback to generate the data that I want a visitor to see on a custom Page node.

    I use a controllerPublic class to process any form data that a user may have submitted from the Page. :)

Share This Page