NorrCompetition | NorrNext Documentation
DocumentationNorrCompetition
  • šŸš€Getting started
    • Technical Requirements
    • Installation and Updates
  • šŸ› ļøConfiguration
    • Component Options
    • General
    • Contests
    • Contest
    • Entries
    • Entry
    • Categories
    • Category
    • Images
    • Comments
    • Contest Form
    • Permissions
  • šŸ–¼ļøContests
    • Managing Contests
    • Creating Contest
    • Contest Layout Options
    • Closing Contest
  • šŸ†Entries
    • Managing Entries
    • Adding Entry
    • Approving Entry
    • Entry Data Comparison
    • Entry Layout Options
    • Submitting Entry Form
    • Contestant's Profile
    • Votes Log
  • šŸ“‚Categories
    • General Information
    • Managing Categories
    • Creating Category
    • Category Layout Options
  • 🧩Fields
    • General Information
    • Managing Fields
    • Field Types
    • Creating Field
  • šŸ”‹Modules
    • NorrCompetition Entries
    • NorrCompetition Contests
    • NorrCompetition Grid
  • šŸ”ŒPlugins
    • NorrCompetition Notifications
    • NorrCompetition Smart Search
    • NorrCompetition Search
    • NorrCompetition Sitemap
    • NorrCompetition Profile Link
    • Application for EasySocial
    • NorrCompetition Application for JomSocial
    • AUP plugin for NorrCompetition
    • NorrCompetition Image Moderation
      • Sightengine Setup
      • Plugin Configuration
  • šŸ’¬Comments
    • Integration with Facebook
    • Integration with JComments
    • Integration with Komento
    • Integration with Disqus
    • Integration with VK.com
  • ā˜ļøRemote Storage
    • General Information
    • AWS S3
  • šŸ–„ļøCustomisation
    • Template Overriding
    • Using content plugins on entry page
    • Link to contestant
    • Events
      • Content
      • Contest
      • Entry
      • Entry Form
      • Field
      • Vote
      • Other
  • āœļøLocalisation
    • Language pack installation
    • How to take a part in NorrCompetition localisation
  • šŸ“œBest Practices
    • Recommendations on image sizes
    • Use on multilingual sites
    • Tutorial: How to Create Photo/Video Voting Contest on Joomla
    • Tutorial: Monetize Voting Contests via Membership
    • Tutorial: Monetize Voting Contests via Points
    • Embedding HTML snippets on example of music contest
  • šŸ’”FAQ
    • How the protection from unfair voting is implemented?
    • What notifications does the component send?
    • Create and edit contests on front-end
    • Submitting Entries by Unregistered Users
    • How to install sample data
    • How to change the order of tabs with comments
    • Using navigation module (breadcrumbs)
    • NorrCompetition and YOOtheme Pro
  • šŸ”Troubleshooting
    • I do not get notifications from NorrCompetition
    • I get an error or white screen on photo upload
    • No images appear after submitting entries
    • Submit button is not working
  • User is not able to vote. Errors in the console
Powered by GitBook
On this page
  • onCompetitionDisplay
  • onCompetitionBeforeDelete
  • onCompetitionAfterDelete
  • onCompetitionBeforeSave
  • onCompetitionAfterSave
  • onCompetitionChangeState
  1. Customisation
  2. Events

Contest

onCompetitionDisplay

Description This event is triggered in CompetitionViewCompetition::display (site).

public function onCompetitionDisplay($context, $item)
{
    // Do something
}

Arguments $context - the context of the event, ā€˜com_competition.competition’. $item - the contest object.

onCompetitionBeforeDelete

onCompetitionAfterDelete

Description These plugins are triggered in CompetitionModelCompetition::delete (admin). If the plugin returns false for onCompetitionBeforeDelete event then the contest is not being deleted.

public function onCompetitionAfterDelete($context, $table)
{
    // Do something
    return;
}

Arguments $context - the context of the event, ā€˜com_competition.competition’. $table - a reference to CompetitionTableCompetition object.

onCompetitionBeforeSave

onCompetitionAfterSave

Description These events are triggered in CompetitionModelCompetition::save (admin). If the plugin returns false for onCompetitionBeforeSave event then the contest is not being saved to the database.

public function onCompetitionBeforeSave($context, $table, $isNew)
{
    // Do something
    return true;
}

Arguments $context - the context of the event, ā€˜com_competition.competition’. $table - a reference to CompetitionTableCompetition object. $isNew - true for new contest, false otherwise./

onCompetitionChangeState

Description Is triggered in CompetitionModelCompetition::publish (admin) after field has its state changed.

public function onCompetitionChangeState($context, $pks, $value)
{
    // Do something
    return;
}

Arguments $context - the context of the event, ā€˜com_competition.competition’. $pks - a list of the primary keys to change. $value - the value of the state: -2 - deleted; 0 - unpublished; 1 - published.

PreviousContentNextEntry

Last updated 2 years ago

šŸ–„ļø