Opened 10 years ago

Closed 5 years ago

#97 closed improve feature (fixed)

Add getByCategory to the new words module.

Reported by: jaliste Owned by:
Priority: major Milestone: Legacy Resolved
Component: FrameWork Keywords: words
Cc: felix

Description

There is a FIXME in the new words module to add a some sort of getByCategory method to it. I create this ticket about possible implementations and use cases. In searchmember page John solved it by using some code similar to the following one

for($a in $some_list)
{
    echo $words->getFormatted('FindPeople_'.$a)
}
     

So actually this code does the work, but you need to know the list of all words in the category to do the trick(in this case
you can think that 'FindPeople?' is the category and somelist is the list of words we need from this category, is this important?

Also, there are words that belong to several pages and so they belong to no category... so theses words simply wont have a category?

So, if we rely on doing category gets by the trick presented above, then the only reason I see to still implement category get from word module is because of performance. I know, the results are cached, but at SQL level, so you still have to do several querys just to get the i18n words of your page, so we could minimize the querys to get the i18n words having a category added to the DB(we can't have only one because of words with no category). Other option, would be to do the cache of words at PHP level.


Change History (3)

comment:1 Changed 10 years ago by jaliste

  • Cc felix added

comment:2 Changed 10 years ago by guaka

  • follow_up set to none
  • freq_reported set to 1
  • Keywords words added
  • show_on_bw set to 0
  • Summary changed from Add getByGategory to the new words module. to Add getByCategory to the new words module.

comment:3 Changed 5 years ago by TimLoal

  • Milestone set to Legacy Resolved
  • Resolution set to fixed
  • Status changed from new to closed
Note: See TracTickets for help on using tickets.