Long term ideas
stacita wrote on 07 Mar 2010 01:01
This is phenomenally cool. Nice job! A long term goal might be to integrate forms with regular wiki pages (as opposed to just some wiki text). It would be nice to have forms on a regular wiki page for data collection that could then be used for other purposes.
Comments: 15
page revision: 0, last edited: 07 Mar 2010 01:01
The "wiki" field type is working now, meaning that you can use wikidot syntax. Is that what you mean?
~ Leiger - Wikidot Community Admin - Volunteer
Wikidot: Official Documentation | Wikidot Discord server | NEW: Wikiroo, backup tool (in development)
Not exactly, I don't think. It seems that Forms provide an alternative way of building a wiki site, which is very cool and something I haven't quite wrapped my mind around. But I'd like to use them more as a way to supplement a regular wiki site. It's hard to explain without a concrete example, so take for instance my recipe wiki. It would be nice to build a form into a regular recipe page that could keep track just of ingredients. And then, I don't think this is possible now, and I certainly don't have the skills necessary to see how to do it, to be able to create "shopping lists" of the ingredients of selected recipes (pages).
I could convert all wiki pages to Forms and use the wiki field for the recipe and commentary (which would encompass the bulk of the form) and then a small field for the ingredients, but this seems like it would open up a lot of confusion for the people already using the site, make trouble with existing recipes, complicate the CSS, and open up problems with formatting.
Another option I tried out was to build a NewPage module into a regular page template that creates new pages in a "form" category. Then a person making a regular default category page could quickly go to a separate form page to compliment the original page. But those 2 pages would be separate and unlinked, so I'm not sure how ideal this would be.
And it might just be a moot point for me until there is a way to hand pick (without each time creating a ListPages module with categories and tags) a few pages and combine the data. I guess that's why I labeled this thread "long-term."
Anyway, as an alternative means to construct a wiki, and for its potential to lead to as yet unforeseen possibilities, this is a very cool initiative!
I've been thinking along these lines as well. It would be slick if data forms worked a bit like live templates.
With something like this, we could get complete information (the page would look the same while editing by displaying the form as designed), but then control which fields to display on the pages holding the form data. In the simple example above, we're collecting information that we may not want to have publicly visible, but we still want to collect for administrative reasons, mailing lists, etc.
I know some of this could be accomplished with private categories, but this would allow another layer of privacy without using private categories. Plus, it would give a lot more control over the layout of the data once it's collected regardless of whether we want to hide any of it or not.
-Ed
Community Admin
Ed: What you want to do is already possible :)
This will work (Sandbox.wikidot.com — cat:test & cat:_template):
Update:
Okay, slight problem. If someone views the source code they can still see everything. This is because I've used a div to hide the form… so while it doesn't appear on the page, it is still there.
Email address etc can be seen by anyone that has access to the page (private categories can be used to restrict that a bit)
~ Leiger - Wikidot Community Admin - Volunteer
Wikidot: Official Documentation | Wikidot Discord server | NEW: Wikiroo, backup tool (in development)
Very clever, Shane! I didn't realize the form would still display if it was buried inside a hidden block. It makes sense though, since all other page content is "ignored" when creating/editing a page with data form template attached to it. You should document this — it's a nifty trick.
-Ed
Community Admin
Guys guys, there's a much more effective way (yay, I discovered it!!!):
Because I have placed the [[form]] beneath the last set of ====, it is interpreted as a static template (data that is pre-filled automatically when you create a page within that category). But because it is a form, static templates are overridden and don't apply.
Basically, THIS is what should be documented, because the form isn't rendered on the resulting page at all. The simple display : none; technique still renders the form on the resulting page, but it's just "hidden" with CSS (can be overridden).
Edit: In other words, this keeps your data hidden from the Google Search Engine.
So simple and obvious, yet I never even thought of doing that. Kudos to you James. Thanks!
~ Leiger - Wikidot Community Admin - Volunteer
Wikidot: Official Documentation | Wikidot Discord server | NEW: Wikiroo, backup tool (in development)
Nice! Even better. If I would have had the good sense to flip-flop my form template layout, I would have probably stumbled upon this myself. I wonder if this was planned or just turned out to be a happy side effect. ;)
-Ed
Community Admin
Not planned, just happy luck. Kudos to James for discovering it!
Portfolio
where I had to fight to unlink form from view… I see you applauding it now. Well… this can go even further I discover…
put [[include "formdeclaration"]] in the content block of the page and you can "skin" you form-views… form separated from form-view (report).
I was fighting for this moths ago… thanks James for the serendipity… Well I remember you asking for this weeks ago.. so it is not "happy luck" was it.
A - S I M P L E - P L A N by ARTiZEN a startingpoint for simple wikidot solutions.
I just proposed this as an add-on to the official docs. Can you guys take a look to make sure I explained it clearly and edit my post as you see fit?
Thanks!
-Ed
Community Admin
This sounds interesting, but not sure how you're suggesting to use includes. Can you make an example on the sandbox?
~ Leiger - Wikidot Community Admin - Volunteer
Wikidot: Official Documentation | Wikidot Discord server | NEW: Wikiroo, backup tool (in development)
Have a look at http://projects.wikidot.com/sandbox-126:_template
it uses the include http://projects.wikidot.com/sandbox-126:_form, so this _form page can be included in whatever _template (SKIN)
A - S I M P L E - P L A N by ARTiZEN a startingpoint for simple wikidot solutions.
Ahh, I see what you mean. You're using the same form for each category, but a different layout for the variables like %%form_label{static-field}%%.
You should be able to do the same thing using only one Live Template page, and no includes. Just use [[iftags]] to separate the multiple "themes" or "skins", and then you'd be able to add a tag like skin:default or skin:hide-password or something and have it appear differently! ;-)
~ Leiger - Wikidot Community Admin - Volunteer
Wikidot: Official Documentation | Wikidot Discord server | NEW: Wikiroo, backup tool (in development)
Maybe a new property such as "view" could be added. So that only Wikidot or Site Members get the field value displayed for sensitive or personal data.
view: site
or
view: wikidot
or
view: anyone (default)
An Innovator at heart.