We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 5811
    • 1,717 Posts
    Simply by changing the templates/anythingRating.tpl file:
    [+atr.tpl:is=`rating`:then=`<div id="[+atr.scoreId+]" class="score">
    [+atr.scoreSection+]
    </div>
    <ul id="[+atr.raterId+]" class="[+atr.raterClass+]">
    [+atr.raterLiSection+]
    </ul>
    <div class="msgClass" id="[+atr.msgId+]">[+atr.msgSection+]</div>`+]
    [+atr.tpl:is=`score`:then=`[+atr.intro+]
    <span class="outnbsClass">[+atr.rating+]/[+atr.nbstars+] [+atr.lbstars+]</span>
    <span class="votesClass">([+atr.nbvotes+] [+atr.lbvotes+])</span>`+]
    Replace [+atr.rating+]/[+atr.nbstars+] [+atr.lbstars+] and ([+atr.nbvotes+] [+atr.lbvotes+]) by what you want. But keep safe the placeholders.
    You could change also the lang/language file.
      • 16702 ☆ A M B ☆
      • 536 Posts
      Hello guys,

      i have question...
      currently working on a project (non-profit) - "Catalogue for Schools and Universities" and one of services is:
      "WRITE YOUR VERY OWN REVIEW" where we have some opportunities to vote:

      Overall
      On a scale of 1 to 5 with 5 being exceptional and 1 being poor, how would you rate the overall experience you had with this university / school?
      1 2 3 4 5

      Satisfy education goals
      What impact do you think this university/school had on your final goals?
      1 2 3 4 5

      etc.
      my question:
      1. "how we can implement this task"
      and second "how we Get top Rated (total score) Universities items"

      can you give some examples

      thanks in advance
        palma non sine pulvere
        • 15113
        • 5 Posts
        Nice snippet. How can the voting be started from scratch? Which table in the database to delete? thx!
          • 32519
          • 94 Posts
          Can’t seem to figure out how to make the rating display in percentage format instead of decimal. Can somebody tell me how?
            <a href="http://www.themovietimeline.net">The Movie Timeline</a> | <a href="http://www.antstuff.net">The Antfarm Site</a>
            • 32519
            • 94 Posts
            Quote from: jonnybravo at May 20, 2010, 03:44 AM

            Can’t seem to figure out how to make the rating display in percentage format instead of decimal. Can somebody tell me how?

            If anyone wants to know. I had to change the default tpl file, from [+atr.rating+] to [+atr.percent+]
              <a href="http://www.themovietimeline.net">The Movie Timeline</a> | <a href="http://www.antstuff.net">The Antfarm Site</a>
              • 21524
              • 90 Posts
              Hi everyone, I have a problem with AnythingRating on my website. Everything seems to work alright except one thing - after voting AnythingRating won’t return the value (so it’s just stuck with loading bar forever) but the vote itself is counted. I can see that by manually refreshing the page.

              How to fix this? Thanks
                • 23714
                • 13 Posts
                Database error for hyphenated friendly url’s:

                Running evolution 1.02, and fairly recent version of everything else (php, mysql, etc...). Using the most basic example you provided to create ratings pages.

                When it occurs: If, for example, I have a page with a friendly URL alias of bluewidget.htm, then everything seems to work fine. If instead, I simply add a hyphen, like blue-widget.htm, then it breaks, throwing this error:


                « MODx Parse Error »
                
                MODx encountered the following error while attempting to parse the requested resource:
                « Execution of a query to the database failed - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '-family ( `id` int(11) NOT NULL auto_increment, `rating_id` ' at line 1 »
                      SQL: CREATE TABLE modx_atRating_blue-widget ( `id` int(11) NOT NULL auto_increment, `rating_id` VARCHAR(80) NOT NULL, `rating` int(11) NOT NULL, `lastIP` varchar(255) NOT NULL, `nbIP` int(11) NOT NULL, `voteDate` TIMESTAMP(12), PRIMARY KEY (`id`) ) ENGINE=MyISAM; 


                  • 20413
                  • 2,877 Posts
                  @pooperscooper Never had a problem with URLs like that. What if you change your
                  &atrGrp=`blue-widget` (I assume!)
                  to
                  &atrGrp=`blueWidget` (fooBar safe!)
                    @hawproductions | http://mrhaw.com/

                    Infograph: MODX Advanced Install in 7 steps:
                    http://forums.modx.com/thread/96954/infograph-modx-advanced-install-in-7-steps

                    Recap: Portland, OR (PDX) MODX CMS Meetup, Oct 6, 2015. US Bancorp Tower
                    http://mrhaw.com/modx_portland_oregon_pdx_modx_cms_meetup_oct_2015_us_bancorp_tower
                    • 23714
                    • 13 Posts
                    I ended up having to do that, but since there are lots other related factors (mostly unrelated to modx) that arise when I change URL’s of existing pages, it really kills me to do it.
                      • 20413
                      • 2,877 Posts
                      See it like this: &atrGrp=`dbTable`
                      The database table in which to group rated resources. I use `blog` for my blog posts.
                      if you have special characters in your db table name it can cause havoc in the
                      database.

                      But a dash shouldn’t break it so check your snippet call! Are your `backticks` correct?

                      What is "-family" relating to?
                        @hawproductions | http://mrhaw.com/

                        Infograph: MODX Advanced Install in 7 steps:
                        http://forums.modx.com/thread/96954/infograph-modx-advanced-install-in-7-steps

                        Recap: Portland, OR (PDX) MODX CMS Meetup, Oct 6, 2015. US Bancorp Tower
                        http://mrhaw.com/modx_portland_oregon_pdx_modx_cms_meetup_oct_2015_us_bancorp_tower