vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 Programming Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=15)
-   -   Alignment problem!! (https://vborg.vbsupport.ru/showthread.php?t=171821)

chrisdaman77 03-01-2008 04:55 PM

Alignment problem!!
 
1 Attachment(s)
I am having a hard time getting the alignment right for this. Is there a code I need to use? Just a not this is the code from the navbar. I have tried <br/> but that only moves it down and will not align it to the left. Anyone have an idea?

Boofo 03-01-2008 05:14 PM

Do a float-left. ;)

chrisdaman77 03-01-2008 05:23 PM

Ok I am new to this how would I go about a float left?

Boofo 03-01-2008 05:38 PM

<span style="float:$stylevar[left]"></span>

or you can use div tags also.

chrisdaman77 03-01-2008 05:44 PM

Ok got ya. I kept trying the div tag but wasn't getting anywhere. I will give this a shot. If it won't work I will post the code I have and maybe I am putting it in the wrong spot.

--------------- Added 01 Mar 2008 at 14:52 ---------------

I marked where I put it in green. Do I even have it in the right place?

Boofo 03-01-2008 06:06 PM

Just post me the section of code for it, not the whole thing. The green didn't take affect in there.

chrisdaman77 03-01-2008 06:17 PM

Here is the section I believe it is. If i type anything next to this it shows up next to it on the page. This is for the "Quick Links" section from the navbar but it is not in the vavbar anymore.:erm:


<if condition="$show['member']">
<span style="float:$stylevar[left]"></span><td id="usercptools"><a href="$show[nojs_link]#usercptools" accesskey="3">$vbphrase[quick_links]</a> <script type="text/javascript"> vbmenu_register("usercptools"); </script></td>
</if>
<else />
<if condition="$show['searchbuttons']">
<a href="search.php$session[sessionurl_q]" accesskey="4">$vbphrase[search]</a></td>
<if condition="$show['member']">
<a href="search.php?$session[sessionurl]do=getnew" accesskey="2">$vbphrase[new_posts_nav]</a></td>
<else />
<a href="search.php?$session[sessionurl]do=getdaily" accesskey="2">$vbphrase[todays_posts]</a></td>
</if>
</if>

Boofo 03-01-2008 06:22 PM

You are close but the span tags have to wrap it.

Change this:

HTML Code:

<span style="float:$stylevar[left]"></span><td id="usercptools"><a href="$show[nojs_link]#usercptools" accesskey="3">$vbphrase[quick_links]</a> <script type="text/javascript"> vbmenu_register("usercptools"); </script></td>
to this:

HTML Code:

<td id="usercptools"><span style="float:$stylevar[left]"><a href="$show[nojs_link]#usercptools" accesskey="3">$vbphrase[quick_links]</a></span> <script type="text/javascript"> vbmenu_register("usercptools"); </script></td>
and let me know if that fixes it.

chrisdaman77 03-01-2008 06:30 PM

Quote:

Originally Posted by Boofo (Post 1454567)
You are close but the span tags have to wrap it.

Change this:

HTML Code:

<span style="float:$stylevar[left]"></span><td id="usercptools"><a href="$show[nojs_link]#usercptools" accesskey="3">$vbphrase[quick_links]</a> <script type="text/javascript"> vbmenu_register("usercptools"); </script></td>
to this:

HTML Code:

<td id="usercptools"><span style="float:$stylevar[left]"><a href="$show[nojs_link]#usercptools" accesskey="3">$vbphrase[quick_links]</a></span> <script type="text/javascript"> vbmenu_register("usercptools"); </script></td>
and let me know if that fixes it.

That didn't do the trick:(. I am hoping I have it in the right spot for the adjustment.

Boofo 03-01-2008 06:33 PM

Ok try this:

Replace that code with this:

HTML Code:

<td id="usercptools"><a href="$show[nojs_link]#usercptools" accesskey="3"><span style="float:$stylevar[left]">$vbphrase[quick_links]</span></a> <script type="text/javascript"> vbmenu_register("usercptools"); </script></td>
Sometimes you just have to play with it until you get it right. ;)

chrisdaman77 03-01-2008 06:40 PM

Nope that didn't do it. That's ok I give you a big thanks for the help. If I can't figure it out I have another idea that I might use. Was just trying to get the navbar vertical instead of horizontal.

Boofo 03-01-2008 06:45 PM

If there is already something on the left of that, you may not be able to do a float left.

chrisdaman77 03-01-2008 06:48 PM

It was next to the "Search" part but I put in some <br/> to drop it down to where it is now in the picture I posted in the first post. Is it possible those are causing the problem?

Boofo 03-01-2008 06:51 PM

A break wont help you on the float left. It needs to be on it's own table row.

chrisdaman77 03-01-2008 06:55 PM

Maybe that is where my problem is. Now I need to go and figure that part out. God I love this.:D I guess this is the only way i am going to learn. If i can ever get this style that I am working on out you are getting some major credit for this for all of your help.

Boofo 03-01-2008 06:57 PM

No problem. I didn't do anything. ;)

If you get close and can't quite get it, let me know and we will see what we can figure out.

chrisdaman77 03-01-2008 07:02 PM

Yeah once I figure how to get it down to the next line without the breaks then it may work. Not sure if if W3S has anything on it. Gonna check them out.

Boofo 03-01-2008 07:07 PM

Like I said, it needs to have it's own <tr>. That would put it on the next row which should be where you want it. ;)

chrisdaman77 03-01-2008 07:20 PM

Finally my stupidity was pointed out to me . Got it now. Don't know why I kept using the <br> tags. Much appreciated sir.

Boofo 03-01-2008 08:34 PM

What fixed it?

chrisdaman77 03-01-2008 10:19 PM

Instead of trying to separate them with <br/> I used <tr/> along with the code you gave in an earlier post.

Boofo 03-01-2008 10:21 PM

You mean <tr> at the beginning and </tr> at the end, right? ;)


All times are GMT. The time now is 07:20 PM.

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.01601 seconds
  • Memory Usage 1,762KB
  • 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
  • (5)bbcode_html_printable
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (22)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
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete