Stackoverflow interesting tags

Posted by Tom on Stack Overflow See other posts from Stack Overflow or by Tom
Published on 2010-05-26T16:51:41Z Indexed on 2010/05/26 17:01 UTC
Read the original article Hit count: 176

Filed under:
|
|
|
|

So, that's how works Interesting Tags: I add into them my interested tags like php, mysql, jquery and so on. Then, if any of questions has the same tags as mine it makes background orange. I understand how to use jquery to do that (there were related questions to that), but without mysql it can't be done. Now, here is a question. How is it done? I imagine like that:

  • There is a row in mysql for every member, let's call it "interested_tags".
  • After I write and submit my tag through input, it is being written in a row "interested_tags".
  • Then, the main page has a query which shows all answers and it always checks answer's with mine tags with strpos like this


    if(strpos($question_tags, $my_tags) === true) {


           //and here will be made background orange


    }


    Am I thinking right or is there any way to do it?

  • © Stack Overflow or respective owner

    Related posts about php

    Related posts about jQuery