vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 Programming Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=15)
-   -   Who's REALLY good with HTML? (https://vborg.vbsupport.ru/showthread.php?t=99728)

Zachery 10-31-2005 03:15 AM

background is not a valid xhtml tag, assuming you are working inside of vBulletin, it tells the browser its xhtml code.

use
style="background-image:$stylevar[imgdir_misc]/pic3.gif"
Instead of
background="$stylevar[imgdir_misc]/pic3.gif"

Bubble #5 10-31-2005 03:00 PM

Quote:

Originally Posted by Zachery
assuming you are working inside of vBulletin

Thank you for helping out Zachery :) Yes we are working from within the templates (forumhome, forum display, navbar, etc.).

Quote:

use
style="background-image:$stylevar[imgdir_misc]/pic3.gif"
Instead of
background="$stylevar[imgdir_misc]/pic3.gif"
When we switched it as shown above the image disappeared causing the entire center section to now be missing :( I've included our new code for the top section so you could see exactly what we changed. Image (pic3.gif) is in the correct folder and was appearing just before the change. Any idea on what would cause the image to disappear like that when the code is correct?


HTML Code:

<!-- top section -->
<table cellpadding="0" cellspacing="0" border="0" width="100%" align="center">
<tr>
<td width="10" height="32"><img src="$stylevar[imgdir_misc]/pic1.png" /></td>
<td width="10" height="32"><img src="$stylevar[imgdir_misc]/pic2.png" /></td>


<td width="100%" height="32" style="background-image:$stylevar[imgdir_misc]/pic3.gif" class="pic2"><center>vbphrase</center></td>


<td width="10" height="32" align="right"><img src="$stylevar[imgdir_misc]/pic4.png" /></td>
<td width="10" height="32" align="right"><img src="$stylevar[imgdir_misc]/pic5.png" /></td>
</tr>
<!-- / End top section -->


Zachery 10-31-2005 03:09 PM

Quote:

Originally Posted by Bubble #5
Thank you for helping out Zachery :) Yes we are working from within the templates (forumhome, forum display, navbar, etc.).


When we switched it as shown above the image disappeared causing the entire center section to now be missing :( I've included our new code for the top section so you could see exactly what we changed. Image (pic3.gif) is in the correct folder and was appearing just before the change. Any idea on what would cause the image to disappear like that when the code is correct?


HTML Code:

<!-- top section -->
<table cellpadding="0" cellspacing="0" border="0" width="100%" align="center">
<tr>
<td width="10" height="32"><img src="$stylevar[imgdir_misc]/pic1.png" /></td>
<td width="10" height="32"><img src="$stylevar[imgdir_misc]/pic2.png" /></td>


<td width="100%" height="32" style="background-image:$stylevar[imgdir_misc]/pic3.gif" class="pic2"><center>vbphrase</center></td>


<td width="10" height="32" align="right"><img src="$stylevar[imgdir_misc]/pic4.png" /></td>
<td width="10" height="32" align="right"><img src="$stylevar[imgdir_misc]/pic5.png" /></td>
</tr>
<!-- / End top section -->


oh silly me, thats what I get for not having my caffiene in me.

should be

background-image: url($stylevar[imgdir_misc]/pic3.gif);

Bubble #5 10-31-2005 03:42 PM

Quote:

Originally Posted by Zachery
oh silly me, thats what I get for not having my caffiene in me.

LOL :)

Quote:

should be
background-image: url($stylevar[imgdir_misc]/pic3.gif);
I'm hoping you don't mean it should look like this:

HTML Code:

<td width="100%" height="32" background-image: url($stylevar[imgdir_misc]/pic3.gif); class="pic2"><div align="center">$vbphrase[whats_going_on]</div></td>
...because that's still not working :ermm: :)

Zachery 10-31-2005 04:19 PM

Quote:

Originally Posted by Bubble #5
LOL :)


I'm hoping you don't mean it should look like this:

HTML Code:

<td width="100%" height="32" background-image: url($stylevar[imgdir_misc]/pic3.gif); class="pic2"><div align="center">$vbphrase[whats_going_on]</div></td>
...because that's still not working :ermm: :)

No

<td width="100%" height="32" style="background-image: url($stylevar[imgdir_misc]/pic3.gif);" class="pic2"><div align="center">$vbphrase[whats_going_on]</div></td>

Bubble #5 10-31-2005 06:11 PM

OK thanks Zachery :) I put the new code in and now the image is appearing correctly, BUT the center section of the top still has gaps on each side of it like in the first post :( I also used the new code that you provided for the guest table and it is now working correctly in all browsers, but the 'What's going on' table and the navbar table (where you enter in username/password) still has those gaps. I'm just thinking out loud here but is it possible that something else could be effecting those two tables to act that way? If so then what should I be looking for? (if you need me to post anything from the templates just let me know) :)

akanevsky 10-31-2005 07:48 PM

Quote:

use http://validator.w3.org to check your code. As long as it passes the xhtml test, it's safari's fault, and not your code.
That's not entirely true. Different browsers have slightly different box models, which could be causing the problem - even when the code is valid according to the validator. In which case, the problem could be eliminated by adding some CSS hacks...

Bubble #5 10-31-2005 08:04 PM

Quote:

Originally Posted by Dark Visor
the problem could be eliminated by adding some CSS hacks...

Anthony do you have any examples that I could look at, or possibly point me in the right direction? I'm really pulling my hair out trying to fix this problem :(

calorie 10-31-2005 08:33 PM

Try posting a screenie after you replace your top section with the following:
Code:

<!-- top section -->
<table cellpadding="0" cellspacing="0" border="0" width="100%" align="center">
<tr>
<td width="10" height="32">A <img src="$stylevar[imgdir_misc]/pic1.png" /></td>
<td width="10" height="32">B <img src="$stylevar[imgdir_misc]/pic2.png" /></td>

<td width="100%" height="32" style="background-image: url($stylevar[imgdir_misc]/pic3.gif);" class="pic2"><div align="center">C $vbphrase[whats_going_on]</div></td>

<td width="10" height="32" align="right">D <img src="$stylevar[imgdir_misc]/pic4.png" /></td>
<td width="10" height="32" align="right">E <img src="$stylevar[imgdir_misc]/pic5.png" /></td>
</tr>
<!-- / End top section -->


Bubble #5 10-31-2005 09:54 PM

1 Attachment(s)
Quote:

Originally Posted by calorie
Try posting a screenie after you replace your top section with the following

It's almost an exact opposite of the way it was before. Now the center is the correct size but the ends don't appear.


All times are GMT. The time now is 05:04 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01195 seconds
  • Memory Usage 1,759KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_code_printable
  • (4)bbcode_html_printable
  • (9)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.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/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete