Jump to content

Font Change


DeathDream

Recommended Posts

Well i have this script, and it displays the data, well not really data, just shows the phpbb3 post in the announcements forum.

 

The Link that is also the title and the body are what i want to change.

Heres what it looks like: http://l2enigma.freehostia.com/

 

I want to make the Title 16 point Tahoma

 

I want to make the body 14 point Tahoma.

 

Here is the script:

<?php
/**
*
* @package phpBB3
* @version $Id$
* @copyright (c) 2008 Erik Frèrejean ( N/A ) http://www.erikfrerejean.nl
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*/

/**
*/

/**
* @ignore
*/
define('IN_PHPBB', true);
$phpbb_root_path    = (defined('PHPBB_ROOT_PATH')) ? PHPBB_ROOT_PATH : './forum/';    // Replace with your own root path
$phpEx = substr(strrchr(__FILE__, '.'), 1);
include($phpbb_root_path . 'common.' . $phpEx);
include($phpbb_root_path . 'includes/functions_display.' . $phpEx);

// Start session management
$user->session_begin();
$auth->acl($user->data);
$user->setup('');

// Set some variables
$forum_ids = array(3);
$max_resul = 5;

// Select all the required data
$sql_ary = array(
    'SELECT'    => 'p.post_id, p.post_time, p.post_text, p.bbcode_bitfield, p.bbcode_uid, p.enable_bbcode, p.enable_smilies, p.enable_magic_url, t.topic_id, t.forum_id, t.topic_title, t.topic_replies_real, u.user_id, u.username, u.user_colour, u.user_avatar, u.user_avatar_type, u.user_avatar_width, u.user_avatar_height',
    'FROM'        => array(
        POSTS_TABLE        => 'p',
        TOPICS_TABLE    => 't',
    ),
    'LEFT_JOIN'    => array(
        array(
            'FROM'    => array(USERS_TABLE => 'u'),
            'ON'    => 'u.user_id = p.poster_id',
        ),
    ),
    'WHERE'        => '(' . $db->sql_in_set('t.forum_id', $forum_ids) . ' AND p.post_id = t.topic_first_post_id)',
    'ORDER_BY'    => 'p.post_id DESC',
);
$sql    = $db->sql_build_query('SELECT', $sql_ary);
$result    = $db->sql_query_limit($sql, $max_resul);

// Loop through the results and print the news
$output = '';
while ($row = $db->sql_fetchrow($result))
{
    // First set all the data in vars
    $bbcode_options    = (($row['enable_bbcode']) ? OPTION_FLAG_BBCODE : 0) + (($row['enable_smilies']) ? OPTION_FLAG_SMILIES : 0) + (($row['enable_magic_url']) ? OPTION_FLAG_LINKS : 0);

    $poster_avatar    = get_user_avatar($row['user_avatar'], $row['user_avatar_type'], $row['user_avatar_width'], $row['user_avatar_height']);
    $poster_link    = append_sid($phpbb_root_path . 'memberlist.' . $phpEx, array('mode' => 'viewprofile', 'u' => $row['user_id']));
    $poster_name    = get_username_string('full', $row['user_id'], $row['username'], $row['user_colour']);
    $post_link        = append_sid($phpbb_root_path . 'viewtopic.' . $phpEx, array('f' => $row['forum_id'], 't' => $row['topic_id'])) . '#p' . $row['post_id'];
    $post_text        = generate_text_for_display($row['post_text'], $row['bbcode_uid'], $row['bbcode_bitfield'], $bbcode_options);
    $post_text        = bbcode_nl2br($post_text);
    $post_text        = smiley_text($post_text);
    $post_subject    = censor_text($row['topic_title']);
    
    // Set the output vars
    $output    .= '<h2><a href="' . $post_link . '" title="' . $post_subject . '">' . $post_subject . '</a></h2>';
    $output .= '<p>' . $post_text . '</p>';
    $output .= $poster_name . '<br />' . $poster_avatar . '<hr/>';
}
$db->sql_freeresult($result);

// Output the page
?>

 

Id appreciate the help.

Link to comment
https://forums.phpfreaks.com/topic/132853-font-change/
Share on other sites

I liked this on the front page:

 

[phpBB Debug] PHP Notice: in file /includes/session.php on line 942: Cannot modify header information - headers already sent by (output started at /home/www/l2enigma.freehostia.com/index.php:6)

[phpBB Debug] PHP Notice: in file /includes/session.php on line 942: Cannot modify header information - headers already sent by (output started at /home/www/l2enigma.freehostia.com/index.php:6)

[phpBB Debug] PHP Notice: in file /includes/session.php on line 942: Cannot modify header information - headers already sent by (output started at /home/www/l2enigma.freehostia.com/index.php:6)

Link to comment
https://forums.phpfreaks.com/topic/132853-font-change/#findComment-691016
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.