Re: Best Idea Needed

2010-10-29 Thread dtemes
Off topic - I am not really fond of selects, as you can only see the
selected option and you have to open it to see other possible
values.If the number of options per select is just 5 have you
considered using groups of radio buttons? If I understood you
correctly your form could be solved with 9 rows of 5 radio buttons
each.



On 29 oct, 05:14, Dave Maharaj m...@davemaharaj.com wrote:
 No the options are randomly numbered (not in equal sets of any denomination)
 so that idea as good as it would work will not in this case.

 Thanks for the input anyways.

 Dave

Check out the new CakePHP Questions site http://cakeqs.org and help others with 
their CakePHP related questions.

You received this message because you are subscribed to the Google Groups 
CakePHP group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en


RE: Best Idea Needed

2010-10-29 Thread Dave Maharaj
Another good idea with the rows, but in total I think there are close to 60
selects and more to be added so that's why I used selects. 60 Rows would be
rather larger where currently I have 3 selects in a row so it cuts down on
the height.
Dave

-Original Message-
From: dtemes [mailto:dte...@gmail.com] 
Sent: October-29-10 5:43 AM
To: CakePHP
Subject: Re: Best Idea Needed

Off topic - I am not really fond of selects, as you can only see the
selected option and you have to open it to see other possible
values.If the number of options per select is just 5 have you
considered using groups of radio buttons? If I understood you
correctly your form could be solved with 9 rows of 5 radio buttons
each.



On 29 oct, 05:14, Dave Maharaj m...@davemaharaj.com wrote:
 No the options are randomly numbered (not in equal sets of any
denomination)
 so that idea as good as it would work will not in this case.

 Thanks for the input anyways.

 Dave

Check out the new CakePHP Questions site http://cakeqs.org and help others
with their CakePHP related questions.

You received this message because you are subscribed to the Google Groups
CakePHP group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at
http://groups.google.com/group/cake-php?hl=en

Check out the new CakePHP Questions site http://cakeqs.org and help others with 
their CakePHP related questions.

You received this message because you are subscribed to the Google Groups 
CakePHP group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en


Re: Best Idea Needed

2010-10-28 Thread Dr. Tarique Sani
If the number of options in each select are 5 then you can take the
value and divide by 5 and examine the results

But I suspect it would be a dynamic range - again if the total range
is exactly distributed in 3 selects you can do the validation
mathematically

HTH
Tarique


On Fri, Oct 29, 2010 at 2:25 AM, Dave Maharaj m...@davemaharaj.com wrote:
 Ok this might be hard to explain.

 Picture a single form that has multiple selects.

 Each select belongs to a section_id so it can range between 1 -5 in its id
 value. A Section has many Options and Options belong To Section

 Each section_id has many options so to make it clear to understand



 Section 1 you can select values of 0-5

 Section 2 selects can select options 6 – 10

 Section 3 can select say options 11 – 15



 So the form has



 Select1  | Select1 | Select1



 Select2  | Select2 | Select2



 Select3  | Select3 | Select3



 Now comes validation I need to ensure that the values were not changed buy
 firebug so someone tries to save a Select3 option as a value in Select2…make
 sense?



 So when validating select1 its only valid if it contains values 0-5. I am
 currently doing a foreach thru the submitted array and checking with



 foreach ( $data['UsersOption'] as $key = $value) {



 //cached data sets of $section_id for each section

 //so this gets all options available to choose from for the
 section

 $valid_options = $this-Option-__getOptionList( $value['section_id'] );



 if ( !in_array( $key, $valid_options ) ) {

 //if not in list specific to the section remove key

 unset( $data['UsersOption'][$key] );

     }

 }



 I know its rather hard to understand but maybe someone would know if there
 is a better way?



 Thanks,



 Dave



 Check out the new CakePHP Questions site http://cakeqs.org and help others
 with their CakePHP related questions.

 You received this message because you are subscribed to the Google Groups
 CakePHP group.
 To post to this group, send email to cake-php@googlegroups.com
 To unsubscribe from this group, send email to
 cake-php+unsubscr...@googlegroups.com For more options, visit this group at
 http://groups.google.com/group/cake-php?hl=en




-- 
=
Cheesecake-Photoblog: http://cheesecake-photoblog.org
PHP for E-Biz: http://sanisoft.com
=

Check out the new CakePHP Questions site http://cakeqs.org and help others with 
their CakePHP related questions.

You received this message because you are subscribed to the Google Groups 
CakePHP group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en


RE: Best Idea Needed

2010-10-28 Thread Dave Maharaj
No the options are randomly numbered (not in equal sets of any denomination)
so that idea as good as it would work will not in this case.

Thanks for the input anyways.

Dave


Check out the new CakePHP Questions site http://cakeqs.org and help others with 
their CakePHP related questions.

You received this message because you are subscribed to the Google Groups 
CakePHP group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en