Radios Select module is the helper utility which provides new custom look of the ordinary radios form element (when you create this element from your own module). The main feature of Radios Select is ability to format output of radios field like "select" form element or dropdown menu. Once Radios Select module enabled you can create Radios Select form element by just adding new property "#radios_select" to any standard radios element and customize it by "#rs_attributes" property.
Compatible with Firefox, Opera, Safari, Chrome and IE6, 7, 8 (IE have some minor limitations).
Please look at the attached screenshots.
More help, description and examples available on the module's help page (admin/help/radios_select).
Module version: only for Drupal 7.x
Link to sandbox project page: http://drupal.org/sandbox/OldWarrior/1399438
Link to sandbox repository: git clone --branch 7.x-1.x git@git.drupal.org:sandbox/OldWarrior/1399438.git radios_select
Comment | File | Size | Author |
---|---|---|---|
rs_all.png | 589.85 KB | OldWarrior |
Comments
Comment #1
andrewyager CreditAttribution: andrewyager commentedSo this looks really cool. :) I've run the automated test bot on your module, and it's picked up some minor issues, but I like the look of what it can create :)
There are still files other than README.txt in the master branch, make sure to remove them. See also step 5 in http://drupal.org/node/1127732
Review of the 7.x-1.x branch:
This automated report was generated with PAReview.sh, your friendly project application review script. You can also use the online version to check your project. Go and review some other project applications, so we can get back to yours sooner.
Source: http://ventral.org/pareview - PAReview.sh online service
Comment #2
andrewyager CreditAttribution: andrewyager commentedComment #3
OldWarrior CreditAttribution: OldWarrior commentedThanks for the review, andrewyager.
I've fixed all issues but except this:
Can i ignore this warning?
Just this means i should change quotes style to double quotes in a whole module...
Comment #4
andrewyager CreditAttribution: andrewyager commentedI think this is one of the times when this should be OK. Whatever you do, you would end up escaping single quotes or double quotes - so I would argue that this is an exception case.
One thing I noticed when I enabled the module is that when I enable the module I receive the following warning from the PHP compiler:
You should set the form from drupal_get_form to a variable first and then pass it through to drupal_render();
If you can fix this issue, then I'll mark this as RTBC.
Comment #5
andrewyager CreditAttribution: andrewyager commentedComment #6
OldWarrior CreditAttribution: OldWarrior commentedThank you for your attentiveness.
I probably have a slightly different configuration of PHP, so I've not seen any notices from PHP regarding of passing function's returned value directly to drupal_render().
So, I fixed it.
Comment #7
OldWarrior CreditAttribution: OldWarrior commentedComment #8
andrewyager CreditAttribution: andrewyager commentedThanks for updating and almost there! The changes you have made are still not quite right. PHP does not require you to pass a variable by reference to a function, this is handled in the function declaration. You should modify your code to read:
It's a good idea during module development to set your PHP error_reporting level to E_ALL and display_errors to On so that you can see what your module does in every case. Obviously you shouldn't do this in production :)
Comment #9
OldWarrior CreditAttribution: OldWarrior commentedYes, and of course I will doing that in the future. :-)
So, i fixed it again. Sorry for some repeated mistakes.
Comment #10
andrewyager CreditAttribution: andrewyager commentedGood work. Don't stress over the repeated mistakes - it's all a learning experience, and a good one.
Comment #11
andrewyager CreditAttribution: andrewyager commentedrtbc by the way
Comment #12
klausimanual review:
t('<h2>Radios Select attributes and examples</h2>'),
": the markup should be outside of t() where possible.But that are just minor issues, so ...
Thanks for your contribution, OldWarrior! Welcome to the community of project contributors on drupal.org.
I've granted you the git vetted user role which will let you promote this to a full project and also create new projects as either sandbox or "full" projects depending on which you feel is best.
Thanks, also, for your patience with the review process. Anyone is welcome to participate in the review process. Please consider reviewing other projects that are pending review. I encourage you to learn more about that process and join the group of reviewers.
As you continue to work on your module, keep in mind: Commit messages - providing history and credit and Release naming conventions.
Comment #13
OldWarrior CreditAttribution: OldWarrior commentedThanks for the review, confidence and comments about my code.
Regarding your comments:
Yes, and I'm already thought about this. But I've embarrassed that it will be a different style of quotes than in the whole module (I've used single quotes in t() anywere in module).
I'll fix it in next commit.
It's just to remove any white spaces and line ends between HTML tags in outputting of radios labels.
Becouse labels there used with "display: inline" (not "block" or "inline-block") CSS property and so any white spaces between them displays as "abnormal" space and disturb internal element layout.
Also I cannot use known CSS hacks for parent container like "font-size: 0" becouse they also produces negative results in other cases.
So, it's needed for properly formatting of outputting until I did not found another solution for this.
Comment #14.0
(not verified) CreditAttribution: commentedCORRECTION OF GIT LINK ACCORDING TO BRANCH