Please upgrade here. These earlier versions are no longer being updated and have security issues.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
Options

how to get topic view number?

wzttest1wzttest1 New
edited October 2012 in Vanilla 2.0 - 2.8

hi,
who can tell me how to get the topic view number?which db field has this value?
I tried to get the view number from the gdn_discussion table's CountViews field,but its value is always 1.I do not know why this happen.
My vanilla version is 2.0.18.4 with no plugins!
thanks!

Comments

  • Options
    peregrineperegrine MVP
    edited October 2012

    I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.

  • Options

    hi,
    thanks!
    but I need the official solution!

  • Options
    peregrineperegrine MVP
    edited October 2012

    First off - you should have stated you wanted the "Official solution". As you may note this forum is primarily "unofficial". Official comes from the developers, so you need to address them specifically and state you don't want unofficial solutions next time, even though they provide the solution to your question. geez.

    I believe you need the analytics plugin enabled. Also testing from the same ip address on local host will not increment your views. I'll do my best not to provide any more unofficial solutions for you, since I am not an "official". Which begs the question - how many solutions, themes, and addons on this site are "official".

    I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.

  • Options
    wzttest1wzttest1 New
    edited October 2012

    @peregrine said:
    First off - you should have stated you wanted the "Official solution". As you may note this forum is primarily "unofficial". Official comes from the developers, so you need to address them specifically and state you don't want unofficial solutions next time, even though they provide the solution to your question. geez.

    I believe you need the analytics plugin enabled. Also testing from the same ip address on local host will not increment your views. I'll do my best not to provide any more unofficial solutions for you, since I am not an "official". Which begs the question - how many solutions, themes, and addons on this site are "official".

    Hello,peregrine:
    I'm novice of this forum.
    I am very thank you for your help!!!
    What your said means the same ip will not increase the topic view number?
    What is the analytics plugin functions?
    Thank you!

  • Options
    peregrineperegrine MVP
    edited October 2012

    @wzttest1

    Hello,peregrine: I'm novice of this forum. I am very thank you for your help!!! >What your said means the same ip will not increase the topic view number?

    Yes, I believe so, unless you make the unofficial change.

    What is the analytics plugin functions? Thank you!

    I don't recall exactly, it could be vanilla statistics has to be enabled.

    I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.

  • Options

    @peregrine 's change here works perfectly fine for me. Only need to uncomment two lines of code.

Sign In or Register to comment.