 |
|
|
|

| Autor |
Nachricht |
Javier
phpBB2.de User

Anmeldungsdatum: 05.08.2002
Beiträge: 1
|
Verfasst am:
Mo 05 Aug, 2002 18:29 |
  |
Hi people i wrote this msg here because is phpbb related only. If not please move my msg to the right one.
time ago i modified my board adding information boxes,login,etc at the right side of my board.
Now i want add the private msg box,
Make the Your Inbox ,Your Outbox ,Your Sentbox and Your Savebox is easy because are only links/ulrs.
And i added the porcentage box too , (0% 50%, 100%) but the % bar not work, is always in 0%.
---------------------------------------------
steps i followed:
i copy from privmsgs_body.tpl the following:
the javascript code
| Zitat: |
<script language="Javascript" type="text/javascript">
//
// Should really check the browser to stop this whining ...
//
function select_switch(status)
{
for (i = 0; i < document.privmsg_list.length; i++)
{
document.privmsg_list.elements[i].checked = status;
}
}
</script>
|
and the box code
| Zitat: |
<!-- BEGIN switch_box_size_notice -->
<table width="175" cellspacing="1" cellpadding="2" border="0" class="bodyline">
<tr>
<td colspan="3" width="100%" class="row1" nowrap="nowrap"><span class="gensmall">{BOX_SIZE_STATUS}</span></td>
</tr>
<tr>
<td colspan="3" width="100%" class="row2">
<table cellspacing="0" cellpadding="1" border="0">
<tr>
<td bgcolor="{T_TD_COLOR2}"><img src="templates/jpracing/images/spacer.gif" width="{INBOX_LIMIT_IMG_WIDTH}" height="8" alt="{INBOX_LIMIT_PERCENT}" /></td>
</tr>
</table>
</td>
</tr>
<tr>
<td width="33%" class="row1"><span class="gensmall">0%</span></td>
<td width="34%" align="center" class="row1"><span class="gensmall">50%</span></td>
<td width="33%" align="right" class="row1"><span class="gensmall">100%</span></td>
</tr>
</table>
<!-- END switch_box_size_notice -->
|
and i put in the index_body.tpl of course.
I can see the porcentage box but not work.
what im doing wrong?
thanks in advance. |
|
|
   |
 |
Google
|
Verfasst am:
|
 |
|
|
 |
Fabro
phpBB2.de User


Anmeldungsdatum: 02.08.2002
Beiträge: 1172
Wohnort: Bayern
|
Verfasst am:
Mo 05 Aug, 2002 19:25 |
  |
Maybe you shoud copy some code from the privmsg.php to the index.php.
Fabro |
_________________ [img]http://cgi.gbgr.de/spruch.png?d=2[/img] |
|
   |
 |
kloeschen
phpBB2.de User


Anmeldungsdatum: 05.08.2002
Beiträge: 77
Wohnort: bochum
|
Verfasst am:
Mo 05 Aug, 2002 22:17 |
  |
yes, you need the code, which produces the
| Code: |
<!-- BEGIN switch_box_size_notice -->
<table width="175" cellspacing="1" cellpadding="2" border="0" class="bodyline">
<tr>
<td colspan="3" width="100%" class="row1" nowrap="nowrap"><span class="gensmall">{BOX_SIZE_STATUS}</span></td>
</tr>
<tr>
<td colspan="3" width="100%" class="row2">
<table cellspacing="0" cellpadding="1" border="0">
<tr>
<td bgcolor="{T_TD_COLOR2}"><img src="templates/jpracing/images/spacer.gif" width="{INBOX_LIMIT_IMG_WIDTH}" height="8" alt="{INBOX_LIMIT_PERCENT}" /></td>
</tr>
</table>
</td>
</tr>
<tr>
<td width="33%" class="row1"><span class="gensmall">0%</span></td>
<td width="34%" align="center" class="row1"><span class="gensmall">50%</span></td>
<td width="33%" align="right" class="row1"><span class="gensmall">100%</span></td>
</tr>
</table>
<!-- END switch_box_size_notice -->
|
stuff. there is something like
| Code: |
//
// Output data for inbox status
//
if ( $folder != 'outbox' )
{
$inbox_limit_pct = ( $board_config['max_' . $folder . '_privmsgs'] > 0 ) ? round(( $pm_all_total / $board_config['max_' . $folder . '_privmsgs'] ) * 100) : 100;
$inbox_limit_img_length = ( $board_config['max_' . $folder . '_privmsgs'] > 0 ) ? round(( $pm_all_total / $board_config['max_' . $folder . '_privmsgs'] ) * $board_config['privmsg_graphic_length']) : $board_config['privmsg_graphic_length'];
$inbox_limit_remain = ( $board_config['max_' . $folder . '_privmsgs'] > 0 ) ? $board_config['max_' . $folder . '_privmsgs'] - $pm_all_total : 0;
$template->assign_block_vars('switch_box_size_notice', array());
switch( $folder )
{
case 'inbox':
$l_box_size_status = sprintf($lang['Inbox_size'], $inbox_limit_pct);
break;
case 'sentbox':
$l_box_size_status = sprintf($lang['Sentbox_size'], $inbox_limit_pct);
break;
case 'savebox':
$l_box_size_status = sprintf($lang['Savebox_size'], $inbox_limit_pct);
break;
default:
$l_box_size_status = '';
break;
}
}
//
// Dump vars to template
//
$template->assign_vars(array(
'BOX_NAME' => $l_box_name,
'INBOX_IMG' => $inbox_img,
'SENTBOX_IMG' => $sentbox_img,
'OUTBOX_IMG' => $outbox_img,
'SAVEBOX_IMG' => $savebox_img,
'INBOX' => $inbox_url,
'SENTBOX' => $sentbox_url,
'OUTBOX' => $outbox_url,
'SAVEBOX' => $savebox_url,
'POST_PM_IMG' => $post_pm_img,
'POST_PM' => $post_pm,
'INBOX_LIMIT_IMG_WIDTH' => $inbox_limit_img_length,
'INBOX_LIMIT_PERCENT' => $inbox_limit_pct,
'BOX_SIZE_STATUS' => $l_box_size_status,
'L_INBOX' => $lang['Inbox'],
'L_OUTBOX' => $lang['Outbox'],
'L_SENTBOX' => $lang['Sent'],
'L_SAVEBOX' => $lang['Saved'],
'L_MARK' => $lang['Mark'],
'L_FLAG' => $lang['Flag'],
'L_SUBJECT' => $lang['Subject'],
'L_DATE' => $lang['Date'],
'L_DISPLAY_MESSAGES' => $lang['Display_messages'],
'L_FROM_OR_TO' => ( $folder == 'inbox' || $folder == 'savebox' ) ? $lang['From'] : $lang['To'],
'L_MARK_ALL' => $lang['Mark_all'],
'L_UNMARK_ALL' => $lang['Unmark_all'],
'L_DELETE_MARKED' => $lang['Delete_marked'],
'L_DELETE_ALL' => $lang['Delete_all'],
'L_SAVE_MARKED' => $lang['Save_marked'],
'S_PRIVMSGS_ACTION' => append_sid("privmsg.$phpEx?folder=$folder"),
'S_HIDDEN_FIELDS' => '',
'S_POST_NEW_MSG' => $post_new_mesg_url,
'S_SELECT_MSG_DAYS' => $select_msg_days,
'U_POST_NEW_TOPIC' => $post_new_topic_url)
);
|
you need this and maybe some more functions. but try it using this code (from your version of privmsg.php)
Grtx,
Markus |
_________________
 |
|
    |
 |
|
|
|
|
|
Nächstes Thema anzeigen
Vorheriges Thema anzeigen
Du kannst keine Beiträge in dieses Forum schreiben. Du kannst auf Beiträge in diesem Forum nicht antworten. Du kannst deine Beiträge in diesem Forum nicht bearbeiten. Du kannst deine Beiträge in diesem Forum nicht löschen. Du kannst an Umfragen in diesem Forum nicht mitmachen. Du kannst Dateien in diesem Forum posten Du kannst Dateien in diesem Forum herunterladen
|
|
| |