4

Using Config files, part 2

Thumbnail for Using Config files, part 2

Few months ago I have published the first part of the using config articles, and some things were changed in these latest version, with one more change coming in the 1.7.3 release. So, before reading this post, you need to read part one.

Part one:  Using Config files, part 1

Once again, I would like to point that all config files changes go into gdsr-config.php file. But, this file must be moved outside of the plugins folder into main wp-content/plugins folder. If the file is found there, it will be loaded and used, if not plugin will fall back to defaults in config.php. Moving gdsr-config.php will ensure that this file and settings in it will not be overwritten during plugin upgrade. This file contains several global constants.

Each global constant has a comment describing the constant. Some of them were described in previous article, and I will describe new constant now.r

  • STARRATING_DEBUG: By default is set to true, and plugin will load and use debug class and debug function. This is useful if you want to disable built in debugging, and you need to set this constant to false.
  • STARRATING_LEGACY_FUNCTIONS: at this moment I recommend leaving this set to true. Most of the integration functions will be rewritten on the road to 1.8 for more flexibility, and all old (or legacy) functions will not be needed. Setting this to false will skip loading these functions and will save some memory used by the plugin.
  • STARRATING_ACCESS_LEVEL_FRONT: similar to other level constants, this one is for plugins front panel.

GD Star Rating 1.7.3 adds two more constants. Since many users requested that they can hide plugins front and all other panels from subscribers (level 0) and in the same time to enable them to see My Ratings panel. So there are two more constants.

  • STARRATING_ACCESS_MY_RATINGS: if this is set to true, My ratings panel will be moved under the Dashboard panel. With this you can disable all plugins panels for subscribers, and still allow them to see My Ratings panel.
  • STARRATING_ACCESS_MY_RATINGS_LEVEL: and this controls user level able to see My Ratings panel, but only if you use previous constant set to true.

If you don’t use (move) this gdsr-config.php file, plugin uses defaults (values currently set in the file).

GD Star Rating
loading...
Using Config files, part 27.51016

Share this:

del.icio.us DiGG Google StumbleUpon Google Buzz Microsoft Live MiXX RSS PDF

4 Responses to “Using Config files, part 2”

  1. Easefree Fashion Accessories, Inc.

    October 24, 2009
    at 3:48 AM

    Really great to find the rating plugin, thanks a lot!
    PollDaddy seems better, but I’ll download some more to have a test in my blog at http://gudaoxiyang.blog2.cnool.net

    GD Star Rating
    loading...
  2. Cross

    November 20, 2009
    at 1:59 AM

    I can find nothing about switching languages.

    Maybe I’m missing something?

    GD Star Rating
    loading...
  3. Jussi

    November 20, 2009
    at 6:58 PM

    Is there a way to set article rating accuracy to more than one decimal? like 3.5 to 3.526? Thanks!

    Love the GDSR!

    GD Star Rating
    loading...
    • MillaN

      November 20, 2009
      at 8:53 PM

      No, only one decimal.

      GD Star Rating
      loading...

Comments are closed.

Social Networks

Subscribe via Feedburner Flickr Images

Feedburner updatesFeedburner

Sign up to receive all latest news about GD Star Rating directly to your email.