Extension talk:Page Forms/Developers' documentation

Instruction causes error
This instruction just leads to  --DaSch (talk) 13:24, 23 July 2012 (UTC)


 * That's strange - what version of SF are you using? And are you calling this code after including SF? You can always look at the Semantic Forms Inputs extension to see how to do it - it essentially uses this same approach. Yaron Koren (talk) 13:52, 23 July 2012 (UTC)


 * I use latest from git. I also tried to build it like it is done in Semantic Forms Inputs with  that didn't work. Is there maybe a possibility to check somewhere which input-types are registred? --DaSch (talk) 13:56, 23 July 2012 (UTC)


 * Hi - there are ways to check, but it doesn't seem relevant here, because the issue here is just that the code doesn't know what $sfgFormPrinter is. This is a silly question, but are you definitely calling "global $sfgFormPrinter" beforehand? Yaron Koren (talk) 14:01, 23 July 2012 (UTC)

--DaSch (talk) 14:09, 23 July 2012 (UTC)


 * Okay, I figured it out. I was not aware, that the form is checked against the template and kills non matching or not existing fields. --DaSch (talk) 14:18, 23 July 2012 (UTC)


 * Okay - I don't see how that would lead to the first error you described, but I'm glad you figured it out. Yaron Koren (talk) 14:26, 23 July 2012 (UTC)

Documentation
Your example is nearly useless. I cant find out where to put the code and what the connection between the input definition in the form (input type) and the function hook is. Can you wirte down a basic ready to use example? This would help mutch more then anything else. The map extension is to complicated.


 * Hi - maybe it would help to look at the code for the Semantic Forms Inputs extension? That one does seem more straightforward than the Semantic Maps code. Yaron Koren (talk) 15:17, 21 February 2013 (UTC)

Is the documentation out of date?
I tried to follow the documentation and got the following error: Error from line 1626 of C:\xampp\htdocs\testnew\extensions\PageForms\includes\PF_FormPrinter.php: Class 'myclassname::myfunction' not found. I think the argument should be a subclass of PFFormInput and not a function name as mentioned in the examnple.Nischayn22 (talk) 19:41, 10 March 2018 (UTC)


 * Oops, sorry about that - this has been out of date for a long time. I just updated this explanation; hopefully it's correct (and useful) now. Yaron Koren (talk) 14:04, 11 March 2018 (UTC)