vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   Image alignment (https://vborg.vbsupport.ru/showthread.php?t=70484)

welo 10-12-2004 03:58 PM

Image alignment
 
I did some digging and found This posted waaaaay back around here. Obviously this won't work in VB3 because the file structure and coding has changed (BB code is now handled in includes/functions_bbcodeparse.php and the preg_replace is different; img code parsing happens around line 997).

Adding a new [imgalign] BB code like suggested on that thread still works, although I'd really like to use [img=left/right/center] instead. Has anyone already figured this out?

peterska2 10-12-2004 04:09 PM


peterska2 10-12-2004 04:11 PM

For the above I just put

Code:

[right ][/right ]
Code:

[center ][/center ]
Code:

[left ][/left ]
around the [img ] tags for the image

welo 10-12-2004 04:19 PM

Yes, but that only shifts the image left/center/right and fails to grant the advantage of <img src="blah.gif" align="left" /> (allowing text to wrap around and float next to images).

zetetic 04-17-2005 12:09 AM

Quote:

Originally Posted by welo
Yes, but that only shifts the image left/center/right and fails to grant the advantage of <img src="blah.gif" align="left" /> (allowing text to wrap around and float next to images).

Better late than never? I swear I found this custom bbcode around here somewhere, but can't find it again:

Code:

Title: Float
Tag: float
Replacement: <span style="float:{option}">{param}</span>
Example: [float=right][img]Image[/img][/float]Float Text
Description: Float an image to the left or right of a block of text.
Use {option}: Yes


paulyy 04-17-2005 12:19 AM

Off topic ....
Quote:

<img src="blah.gif" align="left" />
Get with it, it's 2005. Align in an image tag is now deprecated :)

RichieBoy67 04-17-2005 12:25 AM

PHP Code:

[center ][/center 

I thought these tags were depreciate too???

I thought we were now supposed to use < div align = "center"> </div> -- something like that anyways...


no???

Princeton 04-17-2005 01:16 PM

use CSS to align

this way you can use the class throughout the site
HTML Code:

<span style="float:{option}">{param}</span>
should be
HTML Code:

<span class="{option}">{param}</span>
add to CSS manager
HTML Code:

/*right float*/
.rfloat {
float:right
}
/*left float*/
.lfloat {
float:left
}



All times are GMT. The time now is 12:01 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.01213 seconds
  • Memory Usage 1,732KB
  • 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
  • (4)bbcode_code_printable
  • (3)bbcode_html_printable
  • (1)bbcode_php_printable
  • (2)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (8)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