For e.g. a page like http://drupal.org/project/Modules/category/61 provides no indication to the user as to which category he/she is browsing.

-K

CommentFileSizeAuthor
#1 project_browse_category_title.patch.txt2.31 KBdww

Comments

dww’s picture

Assigned: Unassigned » dww
Status: Active » Needs review
StatusFileSize
new2.31 KB

since we reuse the $term variable in this function, i renamed the main one (module vs. theme, etc) to $type to match "project type", which is how we tend to refer to this particular taxonomy. this way, down in the function when we need it, we still have this object, instead of having clobbered it in the mean time.

Zen’s picture

Why does $type->name use filter_xss instead of check_plain?

Looks fine visually otherwise.

-K

dww’s picture

Status: Needs review » Reviewed & tested by the community

re: filter_xss() vs. check_plain():

at first, the answer was going to be "since that's what the code used to do and i'm just changing the variable name". however, it's a very good question, so i did a little CVS archeology and found this:

revision 1.225
date: 2006-01-25 06:16:45 +0000;  author: nedjo;  state: Exp;  lines: +3 -3;  commitid: 2bb743d717c84567;
check_plain -> filter_xss on $project->description, so some HTML can be used.

clearly this was intentional, and it's just as safe, so i'm not going to undo this...

thanks for keeping me honest, though! ;)

cheers,
-derek

dww’s picture

Status: Reviewed & tested by the community » Needs work

crap, this breaks the regular http://drupal.org/project/Modules/name page. :(

dww’s picture

Status: Needs work » Fixed

found, fixed, committed to DRUPAL-4-7--2 and DRUPAL-4-7, and installed on d.o.

Zen’s picture

I was asking about $type->name, not description.

-K

dww’s picture

ahh, sorry, i missed that (clearly stated) bit of info when i read this before. good point. ;) committed the change to DRUPAL-4-7--2 as revision 1.239.2.13.2.22.

thanks!
-derek

dww’s picture

Category: task » bug
Priority: Minor » Normal
Status: Fixed » Active

grr, i managed to break browsing by category now. :( it's currently displaying all modules, not just the ones from the category you select. i have a hunch, stay tuned for a patch.

dww’s picture

Category: bug » task
Status: Active » Fixed

bug fixed via http://drupal.org/cvs?commit=47875 and installed on d.o.

Anonymous’s picture

Status: Fixed » Closed (fixed)