Uploaded image for project: 'phpBB3'
  1. phpBB3
  2. PHPBB3-14685

PHP event for altering announcements sql

    Details

    • Type: Improvement
    • Status: Unverified Fix (View Workflow)
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 3.1.9
    • Fix Version/s: 3.1.10-RC1
    • Component/s: None
    • Labels:

      Description

      We already have an event for normal topics in view forum (core.viewforum_get_topic_ids_data), however I've run into an issue where I need one for announcements.

      Unable to find source-code formatter for language: php. Available languages are: actionscript, html, java, javascript, none, sql, xhtml, xml
      	$sql_ary = array(
      		'SELECT'	=> $sql_anounce_array['SELECT'],
      		'FROM'		=> $sql_array['FROM'],
      		'LEFT_JOIN'	=> $sql_anounce_array['LEFT_JOIN'],
      
      		'WHERE'		=> '(t.forum_id = ' . $forum_id . '
      				AND t.topic_type = ' . POST_ANNOUNCE . ') OR
      			(' . $db->sql_in_set('t.forum_id', $g_forum_ary) . '
      				AND t.topic_type = ' . POST_GLOBAL . ')',
      
      		'ORDER_BY'	=> 't.topic_time DESC',
      	);
      

      I'll be writing a PR soon.

        Attachments

          Activity

            People

            • Assignee:
              Marc Marc
              Reporter:
              kinerity kinerity
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: