~azzar1/unity/add-show-desktop-key

« back to all changes in this revision

Viewing changes to www/php/phpBB3/faq.php

  • Committer: David Coles
  • Date: 2010-07-28 10:52:48 UTC
  • mfrom: (1791.2.10 mediahandlers)
  • Revision ID: coles.david@gmail.com-20100728105248-zvbn9g72v1nsskvd
A series of HTML5 based media handlers using the <audio> and <video> tags.  
This replaces the previous page that just showed a download link (which is 
already available on the menu).

Also solves issue where media files were downloaded by the client twice (once 
in an AJAX request intended only for text).

Known issues:
    * Bug #588285: External BHO will not be able to play media due to not
      having IVLE cookie.
    * Bug #610745: Does not correctly preview revisions
    * Bug #610780: Ogg media does not work in Chromium

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
<?php
2
 
/**
3
 
*
4
 
* @package phpBB3
5
 
* @version $Id: faq.php,v 1.37 2007/10/05 14:30:06 acydburn Exp $
6
 
* @copyright (c) 2005 phpBB Group
7
 
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
8
 
*
9
 
*/
10
 
 
11
 
/**
12
 
* @ignore
13
 
*/
14
 
define('IN_PHPBB', true);
15
 
$phpbb_root_path = (defined('PHPBB_ROOT_PATH')) ? PHPBB_ROOT_PATH : './';
16
 
$phpEx = substr(strrchr(__FILE__, '.'), 1);
17
 
include($phpbb_root_path . 'common.' . $phpEx);
18
 
 
19
 
// Start session management
20
 
$user->session_begin();
21
 
$auth->acl($user->data);
22
 
$user->setup();
23
 
 
24
 
$mode = request_var('mode', '');
25
 
 
26
 
// Load the appropriate faq file
27
 
switch ($mode)
28
 
{
29
 
        case 'bbcode':
30
 
                $l_title = $user->lang['BBCODE_GUIDE'];
31
 
                $user->add_lang('bbcode', false, true);
32
 
        break;
33
 
 
34
 
        default:
35
 
                $l_title = $user->lang['FAQ_EXPLAIN'];
36
 
                $user->add_lang('faq', false, true);
37
 
        break;
38
 
}
39
 
 
40
 
// Pull the array data from the lang pack
41
 
$help_blocks = array();
42
 
foreach ($user->help as $help_ary)
43
 
{
44
 
        if ($help_ary[0] == '--')
45
 
        {
46
 
                $template->assign_block_vars('faq_block', array(
47
 
                        'BLOCK_TITLE'           => $help_ary[1])
48
 
                );
49
 
 
50
 
                continue;
51
 
        }
52
 
 
53
 
        $template->assign_block_vars('faq_block.faq_row', array(
54
 
                'FAQ_QUESTION'          => $help_ary[0],
55
 
                'FAQ_ANSWER'            => $help_ary[1])
56
 
        );
57
 
}
58
 
 
59
 
// Lets build a page ...
60
 
$template->assign_vars(array(
61
 
        'L_FAQ_TITLE'   => $l_title,
62
 
        'L_BACK_TO_TOP' => $user->lang['BACK_TO_TOP'])
63
 
);
64
 
 
65
 
page_header($l_title);
66
 
 
67
 
$template->set_filenames(array(
68
 
        'body' => 'faq_body.html')
69
 
);
70
 
make_jumpbox(append_sid("{$phpbb_root_path}viewforum.$phpEx"));
71
 
 
72
 
page_footer();
73
 
 
74
 
?>
 
 
b'\\ No newline at end of file'