PDA

View Full Version : weird expansion in phrases...


Dionysis
12-25-2004, 07:48 AM
Here is my code, from the "navbar" template under breadcrumbs
I'm moving it into the header, well at least this part of it (which is the login boxes)

My problem is that where the phrases are, "Private messages : 0 new, 2 total" are in this code the table expands to maybe 150 pixels tall instead of it's normal 20-30something. It seems totally unexplainable as i will remove this code:

<if condition="$show['pmstats']"><br /><phrase 1="$vbphrase[unread_x_nav_compiled]" 2="$vbphrase[total_x_nav_compiled]" 3="$session[sessionurl]">$vbphrase[private_messages_nav]</phrase></if>

and it's back to 20-30 pixels tall.

the full code:

<script type="text/javascript">
<!--
function log_out()
{
ht = document.getElementsByTagName("html");
ht[0].style.filter = "progid:DXImageTransform.Microsoft.BasicImage(grays cale=1)";
if (confirm('$vbphrase[sure_you_want_to_log_out]'))
{
return true;
}
else
{
ht[0].style.filter = "";
return false;
}
}
//-->
</script>

<div style="position:absolute;top:3px;left:480px;">
<!-- breadcrumb, login, pm info -->
<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="240px">
<tr>
<if condition="$bbuserinfo['userid']">

<td class="alt2" valign="top" nowrap="nowrap" width="100%">
<div class="smallfont">
<!--<span style="float:$stylevar[right]">[<a href="login.php?$session[sessionurl]do=logout&amp;u=$bbuserinfo[userid]" onclick="return log_out()">$vbphrase[log_out]</a>]</span>-->
<strong><phrase 1="$bbuserinfo[username]">$vbphrase[welcome_x]</phrase></strong><br />
<phrase 1="$pmbox[lastvisitdate]" 2="$pmbox[lastvisittime]">$vbphrase[last_visited_x_at_y]</phrase>
<if condition="$show['pmstats']"><br /><phrase 1="$vbphrase[unread_x_nav_compiled]" 2="$vbphrase[total_x_nav_compiled]" 3="$session[sessionurl]">$vbphrase[private_messages_nav]</phrase></if>
</div>
</td>

<else />

<td class="alt2" nowrap="nowrap" style="padding:0px">

<!-- login form -->
<form action="login.php" method="post" onsubmit="md5hash(vb_login_password,vb_login_md5password,vb_ login_md5password_utf)">
<script type="text/javascript" src="clientscript/vbulletin_md5.js"></script>
<table cellpadding="0" cellspacing="$stylevar[formspacer]" border="0">
<tr>
<td class="smallfont">$vbphrase[username]</td>
<td><input type="text" class="button" name="vb_login_username" id="navbar_username" size="10" accesskey="u" tabindex="1" value="$vbphrase[username]" onfocus="if (this.value == '$vbphrase[username]') this.value = '';" /></td>
<td class="smallfont" colspan="2" nowrap="nowrap"><label for="cb_cookieuser_navbar"><input type="checkbox" name="cookieuser" value="1" tabindex="3" id="cb_cookieuser_navbar" accesskey="c" checked="checked" />$vbphrase[remember_me]</label></td>
</tr>
<tr>
<td class="smallfont">$vbphrase[password]</td>
<td><input type="password" class="button" name="vb_login_password" size="10" accesskey="p" tabindex="2" /></td>
<td><input type="submit" class="button" value="$vbphrase[log_in]" tabindex="4" title="$vbphrase[enter_username_to_login_or_register]" accesskey="s" /></td>
</tr>
</table>
<input type="hidden" name="s" value="$session[sessionhash]" />
<input type="hidden" name="do" value="login" />
<input type="hidden" name="forceredirect" value="1" />
<input type="hidden" name="vb_login_md5password" />
<input type="hidden" name="vb_login_md5password_utf" />
</form>
<!-- / login form -->

</td>

</if>

</tr>
</table>
<!-- / breadcrumb, login, pm info -->
</div>

Dionysis
12-26-2004, 06:24 AM
anyone? this is really crazy i can't find the "cure"

Dionysis
12-27-2004, 06:41 AM
here's a screenshot of my crazy expansion...

http://www.nrgdrink.com/random/wtf.jpg

you can see that i'm trying to move the login box to the top of the header, so, for the time being, there are 2 login boxes. the top one is the *exact same code* yet it's all out of wack.

Dionysis
12-28-2004, 09:34 PM
anyone? *bueler? bueler?*

rake
12-29-2004, 09:53 PM
<if condition="$show['pmstats']"><br /><phrase 1="$vbphrase[unread_x_nav_compiled]" 2="$vbphrase[total_x_nav_compiled]" 3="$session[sessionurl]">$vbphrase[private_messages_nav]</phrase></if>

check all of those phrases for weird spacing. also, it would help if you would post the resulting html code when you view the page.

Dionysis
12-29-2004, 10:07 PM
here's the HTML

" <div class="smallfont">
<!--<span style="float:right">[<a href="login.php?do=logout&amp;u=1" onclick="return log_out()">Log Out</a>]</span>-->
<strong>Welcome, admin.</strong><br />
You last visited: Today at <span class="time">12:02 AM</span>
<br /><a href="private.php?">Private Messages</a>: 0 Unread, Total 6.
</div>"

exact same as in the first place.

:ermm: