Topic RSS
3:21 pm
Hi,
Should I be able to register on this forum?
I have a default unchanged installation of cForms installed (4.1). By using the quick tag, I can call the default form with no problem.
How do I call the sample dyanmic form (or call a dynamic form full stop)? Am I supposed to put the code in a page post or do I need to edit a PHP file somewhere? So far all I keep ending up with is a contact page that has code printed on it. I'm following the help page as best I can.
Any help would be most appreciated.
Easton Royce
4:16 pm
March 6, 2005
OfflineEastonRoyce,
Yes, to dynamically create a form you'd have to write the necessary PHP code and include it as part of your page or post php template. If you just add the PHP code to your regular post content, then the PHP code as such is shown but not executed.
PS: Since I haven't received feedback from anyone using this feature of cform, I'm more than curious as to how you're implementing it :-)
5:00 am
Thanks for your reply!
ok, no problems. Can you give me an example of some working code, that I would need to place into my PHP files. assuming I still have the default cform, which I do.
Also, to use dynamic forms, do I still need to configure them in the cforms admin page, or is this all done with the code?
Lastly, while I am familiar with PHP, im a beginner when it comes to understanding the workings of Wordpress. How do I choose what page the dyanmic form displays on?
Any or all help would be greatly appreciated!
6:55 am
March 6, 2005
OfflineEastonRoyce, all your questions are actually answered on the Help! page as part of the plugin menu.
There you'll find two examples and the code to include it within your templates as well as a brief descriptions as to why you still need to setup a "proxy" form.
8:32 am
Hi and thanks again for your reply. I've been reading and re-reading the help section, but I just can't figure how I am supposed to do this. I'm obviously missing something, and thus haven't caught on yet.
Is it possible that you could give me the steps in order, to make a dynamic form work?
8:42 am
March 6, 2005
OfflineProvided that you're using your default form (1st form):
- Configure all form settings (except the form fields)
- open your page.php (or whatever template file)
- find a suitable spot for placing the below sample PHP code (see example below): it's got to be within "<?php" & "?>"
- check online
Here is a simple example:
$fields = array();
$fields['label'][0] ='Your Name|Your Name';
$fields['type'][0] ='textfield';
$fields['isreq'][0] ='1';
$fields['isemail'][0] ='0';
$fields['label'][1] ='Your Email';
$fields['type'][1] ='textfield';
$fields['isreq'][1] ='0';
$fields['isemail'][1] ='1';
insert_custom_cform($fields,''); //call default form
Supported field 'types' are explained in the HELP section, the expect format for the field 'label' (=field names in the admin form config!) are also described there.
I'll check if I overlooked something in the code, as I -admittedly- haven't tested dynamic forms in a while :-)
10:40 am
Awesome! Ok, I'm making some progress and things are clearer for me now. Thanks for the example! It was just what I needed to a kick a long.
How do I choose what page the form appears on? At the moment, following your instructions, it appears on every page. I'm using slug based permalinks.
2:13 pm
March 6, 2005
OfflineIf you just want the form to show up on one page you need to make a copy of the orig. page template (rename it per WP nomenclature, header!) and select it as the custom template for just that one page when writing your new page.
2:52 pm
Me again!
I realise this question is beyond the extent of your plugin, but I don't suppose you could provide me some assistance in regards to creating another template file? I tried copying my page.php file, and calling it page-test.php I then copied the cforms code to it, but it doesn't show up as a choosable template in wordpress. I'm not really sure what you mean by "WP nomenclature, header".
Sorry for the fuss. I know I should be spending some time getting to know the inner workings of Wordpress first, but I would really just like to get your dynamic forms function working. If this works the way I think it will, I believe I will have a wide scale use for it.
Easton Royce
3:49 pm
March 6, 2005
Offline12:24 pm
Hi Oliver,
Thanks for your tip. I guess I should have checked on Codex first! Been flat out the last week, so sorry for the lack of communication. Will give this a try now and see how it goes.
3:50 pm
Hi Oliver,
Thanks for your help! I got a template working and I got the 'Advanced' example to work. So far so good!
In the help section of your plugin it says "real-time manipulation"
Perhaps I am confused, but surly that means there is more to dynamic forms then the inclusion of data pulled from a text file.
Is it possible to have users select an option on a page that changes other options? for example,
A Select box for the users country. When they select their country, another select box underneath changes to contain the states of the country selected in the select box above.
Is this sort of thing possible?
6:56 pm
March 6, 2005
OfflineSorry for raising your hopes and the confusion, but with real-time I meant at run-time, but before user input.
So technically, what you're looking for could be done using Javascript, but cforms doesn't support interactively changing form fields/content based on user input yet.
8:30 am
Oh the humanity!!! Thought I had found the holy grail!!
Not to worry, Oliver. I have learned a lot from this experience and so far, your cforms is still far more powerful then the next best forms solution for WordPress (DagonDesign). I am going to see how best I can now use cforms, and will post some links to my solutions here shortly so you can see it in action.
Thanks again, I am glad to have learned something from all of this!
4:48 pm
Oliver said
Sorry for raising your hopes and the confusion, but with real-time I meant at run-time, but before user input.So technically, what you're looking for could be done using Javascript, but cforms doesn't support interactively changing form fields/content based on user input yet.
Hi, is there any update on this? Or any plans to develop this in the future? Just asking as it's one of the only missing features in your otherwise great plugin.
Thanks,
M.
Most Users Ever Online: 959
Currently Online:
113 Guest(s)
Currently Browsing this Page:
1 Guest(s)
Top Posters:
tracedef: 43
mores: 21
Gyrus: 20
frozenwaste: 18
asuffredini: 15
photoworks: 14
Member Stats:
Guest Posters: 3548
Members: 1464
Moderators: 3
Admins: 1
Forum Stats:
Groups: 1
Forums: 4
Topics: 5157
Posts: 18386
Newest Members: juredujmovic, dreamkeeper, rajattyagi, wrokaa, lukass
Moderators: Paul (421), cnymike (8), sonika (95)
Administrators: Oliver (6398)
FAQs
Home
Add Reply
Add Topic
Quote










