select widget

A place for users and developers of the Xataface to discuss and receive support.

select widget

Postby pie » Thu Oct 27, 2011 12:14 pm

Hello

two little questions:

1. Is it possible to remove the "please select" from a select widget so that it just gives the options?

2. is it possible to put a select widget in the navigation pane?

kind regards
P
pie
 
Posts: 11
Joined: Fri Sep 30, 2011 5:27 am

Re: select widget

Postby ADobkin » Thu Oct 27, 2011 8:21 pm

pie wrote:1. Is it possible to remove the "please select" from a select widget so that it just gives the options?


You would have to modify the source to Xataface to do this. Refer to the file ./Dataface/FormTool/select.php, lines 17-18. I am not sure what all the repercussions would be without testing it. If you modify this file directly, it will affect all select widgets in your installation. You could try duplicating this file to roll your own separate select widget and then referencing which one you need. Or, if you have PHP coding skills, you could make it an optional parameter that could be configured on a per-field basis in fields.ini. If you do this, please consider sharing your results here.

pie wrote:2. is it possible to put a select widget in the navigation pane?


This would probably also require some customization and creative coding skills.
ADobkin
 
Posts: 195
Joined: Mon Oct 22, 2007 7:31 pm
Location: Atlanta, GA, USA

Re: select widget

Postby shannah » Fri Oct 28, 2011 9:22 am

You could also just set a default value for that field. The "please select..." option would then still be there, but it wouldn't be selected by default so most people wouldn't notice it.
shannah
 
Posts: 4457
Joined: Wed Dec 31, 1969 5:00 pm

Re: select widget

Postby shannah » Fri Oct 28, 2011 9:22 am

Alternatively you could use javascript to remove this option on page load.
shannah
 
Posts: 4457
Joined: Wed Dec 31, 1969 5:00 pm

Re: select widget

Postby pie » Wed Nov 02, 2011 1:35 am

Shannah, how do I set a default value for that field?
pie
 
Posts: 11
Joined: Fri Sep 30, 2011 5:27 am

Re: select widget

Postby ADobkin » Wed Nov 02, 2011 4:16 am

pie wrote:how do I set a default value for that field?


It is specified in MySQL, along with the data type for that column.
ADobkin
 
Posts: 195
Joined: Mon Oct 22, 2007 7:31 pm
Location: Atlanta, GA, USA


Return to Xataface Users

Who is online

Users browsing this forum: No registered users and 18 guests

cron
Powered by Dataface
© 2005-2007 Steve Hannah All rights reserved