vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 Programming Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=15)
-   -   Break if there is quote first help (https://vborg.vbsupport.ru/showthread.php?t=65295)

Boofo 05-19-2004 10:11 PM

Break if there is quote first help
 
I want to add a break at the top of a post only if someone has started their message and then adds a quote later in the post. But if they list the quote first or don't do a quote anywhere in the message, I don't want a break at the beginning of the message. How can this be done?

sabret00the 05-19-2004 10:25 PM

could you select the data via a query checking it for "[quote]" and use that for a conditional?

Natch 05-19-2004 11:46 PM

Quote:

Originally Posted by Boofo
I want to add a break at the top of a post only if someone has started their message and then adds a quote later in the post. But if they list the quote first or don't do a quote anywhere in the message, I don't want a break at the beginning of the message. How can this be done?

What you wanna have is a space one line high preceding a Quote ? (not necessarily a <br /> break ?

How about a CSS solution ... a little hard-code goes a long way ...

A couple of options include assigning a class="breakabove" to the Quote element (whatever that is) or if it has a class already, then you will need to hack the BBCODE for Quote to add the CSS you need ...

In either case, the CSS is:
for the class solution
Code:

.breakabove { margin-top: 1em; }
and for the inline solution
Code:

style="margin-top: 1em;"
needs to be added to the HTML rendering of the QUOTE element ...

Any questions, just ask :)

AN-net 05-20-2004 12:37 AM

you can check if the first six characters is [quote


All times are GMT. The time now is 07:33 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.01007 seconds
  • Memory Usage 1,714KB
  • 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
  • (2)bbcode_code_printable
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (4)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