Thread: vB Pager 2.0.4
View Single Post
  #184  
Old 05-09-2005, 11:49 PM
Fusion.nl's Avatar
Fusion.nl Fusion.nl is offline
 
Join Date: Apr 2005
Location: Netherlands
Posts: 37
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Nice hack. We've been using it for the admins to quickly communicate with each other when no messanger program is available. Just one thing bothers me from a webdesigner's point of view.

It looks fugly in Mozilla Firefox (no round corners, no scroll bar from the get go) compared to Internet Explorer (normally its the other way around aranoid: ). Is there a proper stylesheet for this or a fix that it looks the same in Firefox (or a bit more decent), cause its very annoying.



If it is not possible to get it to be the same, could someone please hardcode the source so that at least the borders of the input field are white, in stead of just the bottom left corner? I can do it in CSS, but that would change all tables that make use of this style.

Many thanks on beforehand. :up:

Code:
<style type="text/css">
	#PLAYER { position:absolute; height:1; width:1px; top:0; left:0; }
	</style>
<script type="text/javascript">
chanceAd=1; // The chance in X times that this signup reminder will be shown

var ns=(document.layers);
var ie=(document.all);
var w3=(document.getElementById && !ie);
var calunit=ns? "" : "px"

function initAd(){
	if(!ns && !ie && !w3) return;
	if(ie)		adDiv=eval('document.all.PLAYER.style');
	else if(ns)	adDiv=eval('document.layers["PLAYER"]');
	else if(w3)	adDiv=eval('document.getElementById("PLAYER").style');
	randAd=Math.ceil(Math.random()*chanceAd);
        if (ie||w3)
        adDiv.visibility="visible";
        else
        adDiv.visibility ="show";
	if(randAd==1) showAd();
}
function showAd(){
	if (ie)
	{
		documentWidth  =truebody().offsetWidth/2+truebody().scrollLeft-20;
		documentHeight =truebody().offsetHeight/2+truebody().scrollTop-20;
	}	
	else if (ns)
	{
		documentWidth=window.innerWidth/2+window.pageXOffset-20;
		documentHeight=window.innerHeight/2+window.pageYOffset-20;
	} 
	else if (w3)
	{
		documentWidth=self.innerWidth/2+window.pageXOffset-20;
		documentHeight=self.innerHeight/2+window.pageYOffset-20;
	} 
	
	adDiv.left=documentWidth-200+calunit;
	adDiv.top =documentHeight-100+calunit;
	setTimeout("showAd()",100);
}



function truebody(){
return (document.compatMode && document.compatMode!="BackCompat")? document.documentElement : document.body
}

onload=initAd;
</script>

<DIV ID="PLAYER" style="visibility:hidden">
<div class="normalfont">
<iframe name="ipager" width="0" height="0"></iframe>
<table class="tborder" align="$stylevar[center]" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" width="400">
<tr>
	<td class="tcat" align="$stylevar[left]" height="13">$vbphrase[vbpager_message_from] <i>$pagerinfo[username]</i><font class="smallfont">
@ $pagerinfo[timesent]</font>
</td>
</tr>
<tr>
	<td class="panelsurround" align="center" valign="top">
			<fieldset class="fieldset">
				<legend>$vbphrase[vbpager]</legend>
				<table cellpadding="0" cellspacing="$stylevar[formspacer]" border="0" align="center">
  <tr><td>
		<table border="0" cellpadding="2" cellspacing="0" width="100%" align="center">
			<tr><td>
<table id="frm" border="0" cellpadding="0" cellspacing="0" width="400">
<tr><td width="100%">
<table cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%">
<tr>
	<td class="panelsurround" align="$stylevar[left]">
	<div class="panel"><div align="$stylevar[left]">
		$pagerinfo[message]
</div></div>
	</td>
</tr>
</table>
  </td></tr>
<form method="POST" action="$vboptions[bburl]/pager.php" name="frmpager" target="ipager" onsubmit="return SubmitForm();">
  <tr><td align="$stylevar[left]" width="100%">
<if condition="$pagerinfo[canreply]">
<input type="hidden" name="action" value="pager">
<input type="hidden" name="do" value="pagerreply">
<input type="hidden" name="do1" value="pagerreply">
<input type="hidden" name="pid" value="$pagerinfo[pagerid]">
<input type="hidden" name="pid1" value="$pagerinfo[pagerid]">
<input type="hidden" name="touid" value="$pagerinfo[fromuserid]">
<input type="hidden" name="touid1" value="$pagerinfo[fromuserid]">
<textarea class="button" rows="3" name="message" cols="40" onKeyDown="textCounter(this);" onKeyUp="textCounter(this);"></textarea><br>
<input type="text" class="button" readonly name="charNum" size=2 value="$vboptions[vbpager_message_maxchar]">
<input type="submit" name="submit" class="button" value="$vbphrase[vbpager_reply_to] $pagerinfo[username]">
</if>

<input type="button" class="button" onClick="javascript:window.parent.ipager.location.href='$vboptions[bburl]/pager.php?action=pager&do=pagerreply&pid=$pagerinfo[pagerid]&touid=$pagerinfo[fromuserid]';closepager('PLAYER');" value="$vbphrase[vbpager_close]"> &nbsp;
  </td></tr>
  </form>
</table>
			</td></tr>
		  </table>
  </td></tr>
  </table>
            </fieldset>
            </td></tr>
</table>
</div>
</DIV>

<script type="text/javascript">

function closepager(id){
if (ie||w3)
adDiv.display="none";
else
adDiv.visibility ="hide";
}

function SubmitForm()
 {
minchar = 3;
  if (document.frmpager.message.value.length < minchar)
   {
    alert("$vbphrase[vbpager_max_per_message] " + minchar + "");
    return false;
   }
  else
     closepager('PLAYER');
    return true;
 }

function textCounter(field) {
maxlimit=$vboptions[vbpager_message_maxchar] ;
  if (field.value.length > maxlimit)
      {field.value = field.value.substring(0, maxlimit);}
      else
      {document.frmpager.charNum.value = maxlimit - field.value.length;}
  }
</script>
Reply With Quote
 
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01067 seconds
  • Memory Usage 1,797KB
  • Queries Executed 11 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD_SHOWPOST
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_code
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_box
  • (1)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (1)post_thanks_postbit_info
  • (1)postbit
  • (1)postbit_onlinestatus
  • (1)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • reputationlevel
  • showthread
Included Files:
  • ./showpost.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showpost_start
  • bbcode_fetch_tags
  • bbcode_create
  • postbit_factory
  • showpost_post
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • showpost_complete