On homepage I would like to insert form that collects client details and saves it to wordpress backend.
I was thinking to use custom_post_type
register_post_type('invoices', array( 'labels' => array( 'name' => __('Invoices'), 'singular_name' => __('Invoice') ), 'public' => true, 'has_archive' => false, 'supports' => array('title') ) );
- How I remove ability to publish? and view post / slug forms? This invoices won't be published on homepage. So is there a way to make
post_typeprivate? I thought
'public' => falsewould do the trick, but this hides from dashboard.
- I would like to add fields, like name/email/type of service. Is the only way to do this by adding add_meta_box?
- How do I pass data from unauthenticated visitor on homepage to wordpress?