Previous Thread
Next Thread
Print Thread
Rate Thread
Page 1 of 3 1 2 3
Joined: Mar 2000
Posts: 21,079
Likes: 3
I type Like navaho
I type Like navaho
Joined: Mar 2000
Posts: 21,079
Likes: 3
Name: Smarter Looking Quotes and Codes

Author: Maze , adapted for ubb.classic by me smile

Description: Hides hr's in quotes and encloses them in colored boxes smile

Requirements: Valid license, Works in any UBB, tested in 6.3.1

Code: Place this in your headerinsert:
Code
<style type="text/css"> 
blockquote {
font-size: 9pt;
border: 1px solid #c3c3c3;
background: #f6f6f6;
color: black;
margin: 0px 20px;
padding: 0px 10px
}
blockquote .small {
background:#e5e5e5;
color: black;
margin-left:-10px;
padding:1px 2px
}
blockquote hr {
visibility:hidden;
height:1px
}
blockquote br {
font-size:1px
}
</style>
Demo: Here, check with the "frost" theme.


- Allen wavey
- What Drives You?
Sponsored Links
Joined: Feb 2000
Posts: 4,625
Member
Member
Offline
Joined: Feb 2000
Posts: 4,625
Really sweet! smile Nice work.

Joined: Oct 2001
Posts: 572
Member
Member
Offline
Joined: Oct 2001
Posts: 572
Nice and Simple. smile

Joined: Sep 2001
Posts: 71
Member
Member
Offline
Joined: Sep 2001
Posts: 71
Simple, but very good smile

Joined: Jun 2001
Posts: 2,849
Spotlight Winner
Spotlight Winner
Offline
Joined: Jun 2001
Posts: 2,849
Quote
quote:
Originally posted by alone:
Simple, but very good smile
hmmm

Sponsored Links
Joined: May 2001
Posts: 6,708
Member
Member
Offline
Joined: May 2001
Posts: 6,708
Nice work AA.

Joined: Apr 2001
Posts: 214
Member
Member
Offline
Joined: Apr 2001
Posts: 214
Nothing like a 2 sec Addon =) thanks AA, works GREAT!!

Joined: Dec 2000
Posts: 151
Member
Member
Offline
Joined: Dec 2000
Posts: 151
By far the easiest hack I have done and very nice and useful.

Now being that CSS can be used in this way, are the other possibilities for quote blocks in this way?

Joined: Mar 2000
Posts: 21,079
Likes: 3
I type Like navaho
I type Like navaho
Joined: Mar 2000
Posts: 21,079
Likes: 3
Sure, you can experiment with it, it shouldn't harm anything smile


- Allen wavey
- What Drives You?
Joined: Nov 2001
Posts: 745
Admin Emeritus
Admin Emeritus
Offline
Joined: Nov 2001
Posts: 745
for those using JCTemplates:

Remove the first and last line of the hack
Insert into CSS section of template

Sponsored Links
Joined: Apr 2001
Posts: 31
Junior Member
Junior Member
Offline
Joined: Apr 2001
Posts: 31
very cool, much better looking!

Did you use wordlets to change the background color of the small 'quote:'?

Thanks,
Adam

Joined: Dec 2000
Posts: 151
Member
Member
Offline
Joined: Dec 2000
Posts: 151
I guess I am just an idiot -

The line that is quoteblock .small which I assume sets up the parameters for the section that says quote:

does not work for me

Code
<style type="text/css">
blockquote {
font-size: 9pt;
border: 3px solid #34669a;
background: #FDF5E6;
color: black;
margin: 12px 20px;
padding: 0px 10px
}
blockquote .small {
background: #34669A;
color: white;
margin-left:-10px;
padding: 1px 2px
}
blockquote hr {
visibility: hidden;
height: 1px
}
blockquote br {
font-size: 1px
}
</style>
what am I doing wrong?

Joined: Mar 2001
Posts: 7,394
LK Offline
Admin / Code Breaker
Admin / Code Breaker
Offline
Joined: Mar 2001
Posts: 7,394
In ubb_lib_posting.cgi and ubb_lib.cgi, before the part of "quote:" and "code:", add '
', and afterwards, add '
'.

Joined: Dec 2000
Posts: 151
Member
Member
Offline
Joined: Dec 2000
Posts: 151
I can only guess you are referring to sections that look like this:

*** deleted cause it was obviously not the right area ***

there are no areas that match what you refer to since wordlets are used

then there are something like 3 or 4 areas in each file that might match taking wordlets into consideration

oh well.... as I said....

Joined: Dec 2000
Posts: 151
Member
Member
Offline
Joined: Dec 2000
Posts: 151
I guess nothing is ever as simple as it appears.

This "mod" appeared to be simple, yet as published it does not do what is displayed here.

It takes further modifications and unfortunately what you have said LK does not affect anything - assuming (big word) I have place the div tags in the right place which considering wordlets I have.

I did not put it the sections that undoes the code for editing - only in the section where it converts the ubb code to what is displayed.

Suggestions???

Joined: Dec 2000
Posts: 151
Member
Member
Offline
Joined: Dec 2000
Posts: 151
Suggestions beyond going out and getting a brain, thank you. wink

Joined: Dec 2000
Posts: 151
Member
Member
Offline
Joined: Dec 2000
Posts: 151
i tried this:

Code
<style type="text/css">
blockquote {
font-size: 9pt;
border: 1px solid #c3c3c3;
background: #f6f6f6;
color: black;
margin: 0px 20px;
padding: 0px 10px
}
div.small {
background:#e5e5e5;
color: black;
margin-left:-10px;
padding:1px 2px
}
blockquote hr {
visibility:hidden;
height:1px
}
blockquote br {
font-size:1px
}
</style>
and it was the closest I could get to this actually working as shown on this board

(changed the second blockquote to div)

but it would then do the whole line in the different color

Joined: Dec 2000
Posts: 151
Member
Member
Offline
Joined: Dec 2000
Posts: 151
but adding anything to only the two lines that create the code causes for all the created code to appear if the post is edited

so obviously there must be much more to make that dang little box a different color

perhaps too much to even freaking bother with

i have lost two hours of sleep messing with this eek

i'm such an idiot

Joined: Mar 2000
Posts: 21,079
Likes: 3
I type Like navaho
I type Like navaho
Joined: Mar 2000
Posts: 21,079
Likes: 3
heheh smile

What version ubb are you running? There's some slight differences between versions when we went xhtml-compliant smile


- Allen wavey
- What Drives You?
Joined: Dec 2000
Posts: 151
Member
Member
Offline
Joined: Dec 2000
Posts: 151
the latest!

v6.3.1

Joined: May 2002
Posts: 14
Junior Member
Junior Member
Offline
Joined: May 2002
Posts: 14
i have a problem, when i enter the text so long, it keep on going and going and expand the forum width and it look nasty, is there a way to fix it so when we enter a text this long it will automatic cut and to next line according to the forum width

Joined: Mar 2000
Posts: 21,079
Likes: 3
I type Like navaho
I type Like navaho
Joined: Mar 2000
Posts: 21,079
Likes: 3
before I edit your post wink , that's the designed behaviour of the code tags, not this modification. It is set to keep your line breaks the same, because if you are posting actual code, that's a very important feature. use the quote tag if you need line breaks, that's what it is for smile

CaCoffin, if you haven't edited the quote tags in ubb_lib_posting.cgi, then yours should work the same as those here. Please give me a link to a post at your site that isn't looking right using the code as specified here smile


- Allen wavey
- What Drives You?
Joined: Dec 2000
Posts: 151
Member
Member
Offline
Joined: Dec 2000
Posts: 151
I have absolutely ZERO mods to the board -
I have erased my previous attempt to enter this mod -
I have rentered the MOD EXACTLY has shown - (copy / paste to be exact)

It does not left align the word "code" or "quote" and it does not have the extra coloring around the word.

Here is what code I do have in that same section:

X X X deleted by me X X X

Joined: Dec 2000
Posts: 151
Member
Member
Offline
Joined: Dec 2000
Posts: 151
oh and here is a page to see it

http://iambornagainru.org/bab/ultimatebb.php?ubb=get_topic;f=12;t=000071

Joined: Dec 2000
Posts: 151
Member
Member
Offline
Joined: Dec 2000
Posts: 151
#1 I am truly a doofus!
#2 I failed to read Header INSERT
#3 I had other code in there too that was not working well with the rest
#4 I erased that other coding
#5 Put just the style coding for the quote in there
#6 Still does not work
#7 I know why but I don't know why

blockquote .small

on your pages you have this code:

Quote
code:
Code
<blockquote><font class="small">code:</font>

but on mine (again no mods) it is:

code:
[qb]
Code
<blockquote><font size="1" face="Verdana, Helvetica, sans-serif">code:</font>
[/qb]
I have no font class small!

So where is this being used instead of what I have???? (That is where in the control panel do I have something that can be changed to "small"?)

Joined: Dec 2000
Posts: 151
Member
Member
Offline
Joined: Dec 2000
Posts: 151
Does no one know why I using the latest version of UBB has different code than you guys do here?

Joined: Mar 2001
Posts: 7,394
LK Offline
Admin / Code Breaker
Admin / Code Breaker
Offline
Joined: Mar 2001
Posts: 7,394
ubb_lib.cgi and ubb_lib_posting.cgi, where you see the code/quote things, you can just put class="small" after .

Joined: Mar 2000
Posts: 21,079
Likes: 3
I type Like navaho
I type Like navaho
Joined: Mar 2000
Posts: 21,079
Likes: 3
Quote
quote:
Originally posted by CaCoffin:
Does no one know why I using the latest version of UBB has different code than you guys do here?
smile We have completely different templates based on our css work we did a few months back, so yeah, they're different. wink

Do as LK said and it should work for you. You'll most likely need to experiment to make sure editing/quoting those posts with quotes/codes work out right - you'll probably need to put it in where it changes ubb code to html, and also where it changes html back to ubbcode.


- Allen wavey
- What Drives You?
Joined: Dec 2000
Posts: 151
Member
Member
Offline
Joined: Dec 2000
Posts: 151
Thank you

It now works for the average schmendrick (me) that has no MODS installed (other than this one now).

I have been trying to make zero MODS to the coding. I can get them installed just fine but then when a new version of the UBB comes out I managed to mess everything up and have lost everything several times over the last two years.

Which of course has caused us to lose many members.

So I don't do any hacking of the actual files anymore.

If a "mod" is going to be done by me it has to be something that can be done in such a way that it does not alter the member files (main cause of problems for me) and can easily be redone with an upgrade (thus does not mess with the posts either).

One of these days I'll get into the templates thing and figure some stuff out but for now, so as not to chase members away I have to leave things alone.

Thanks for the help on this one!

Joined: Aug 2002
Posts: 3
Junior Member
Junior Member
Offline
Joined: Aug 2002
Posts: 3
Quote
quote:
Originally posted by CaCoffin:
I guess nothing is ever as simple as it appears.

This "mod" appeared to be simple, yet as published it does not do what is displayed here.

It takes further modifications and unfortunately what you have said LK does not affect anything - assuming (big word) I have place the div tags in the right place which considering wordlets I have.

I did not put it the sections that undoes the code for editing - only in the section where it converts the ubb code to what is displayed.

Suggestions???
Very Nice =)

Joined: Mar 2000
Posts: 21,079
Likes: 3
I type Like navaho
I type Like navaho
Joined: Mar 2000
Posts: 21,079
Likes: 3
Hey CaCoffin, set up a test forum to practice on... until you get the hang of it you really don't wanna modify your live site without making sure it works ahead of time. What works for me may not work for you based on what other things we both have installed.


- Allen wavey
- What Drives You?
Joined: Aug 2002
Posts: 97
Member
Member
Offline
Joined: Aug 2002
Posts: 97
Worked great for me thanks smile

Joined: Feb 2001
Posts: 54
Member
Member
Offline
Joined: Feb 2001
Posts: 54
Quote
quote:
Originally posted by AllenAyres:
Code: Place this in your headerinsert:
Mod looks great, sounds super easy to install, only one catch... where the heck do I find the "headerinsert"?? confused
UBB 6.3.1

Joined: Mar 2000
Posts: 21,079
Likes: 3
I type Like navaho
I type Like navaho
Joined: Mar 2000
Posts: 21,079
Likes: 3
that's in your style templates, under the header and footer boxes. smile


- Allen wavey
- What Drives You?
Joined: Sep 2002
Posts: 16
Junior Member
Junior Member
Offline
Joined: Sep 2002
Posts: 16
I like it... smile
Thanks a lot for this nice hack

bobbel

Joined: Mar 2001
Posts: 56
Member
Member
Offline
Joined: Mar 2001
Posts: 56
It adds a nice box around the quote and code, but the .small reference is useless.

Joined: Feb 2001
Posts: 169
Member
Member
Offline
Joined: Feb 2001
Posts: 169
Things so simpe are also so sweeeeet !
Thank you, works perfectly !

Joined: May 2002
Posts: 28
Junior Member
Junior Member
Offline
Joined: May 2002
Posts: 28
Nice and easy, even I done that one wink

Joined: Oct 2002
Posts: 394
Enthusiast
Enthusiast
Offline
Joined: Oct 2002
Posts: 394
anybody explain please where this header insert is?
is there a instruction for dummies? confused

Joined: Dec 2000
Posts: 151
Member
Member
Offline
Joined: Dec 2000
Posts: 151
Quote
quote:
Originally posted by AllenAyres:
that's in your style templates, under the header and footer boxes. smile
Answered before you asked!

Page 1 of 3 1 2 3

Link Copied to Clipboard
Donate Today!
Donate via PayPal

Donate to UBBDev today to help aid in Operational, Server and Script Maintenance, and Development costs.

Please also see our parent organization VNC Web Services if you're in the need of a new UBB.threads Install or Upgrade, Site/Server Migrations, or Security and Coding Services.
Recommended Hosts
We have personally worked with and recommend the following Web Hosts:
Stable Host
bluehost
InterServer
Visit us on Facebook
Member Spotlight
isaac
isaac
California
Posts: 1,157
Joined: July 2001
Forum Statistics
Forums63
Topics37,573
Posts293,925
Members13,849
Most Online5,166
Sep 15th, 2019
Today's Statistics
Currently Online
Topics Created
Posts Made
Users Online
Birthdays
Top Posters
AllenAyres 21,079
JoshPet 10,369
LK 7,394
Lord Dexter 6,708
Gizmo 5,833
Greg Hard 4,625
Top Posters(30 Days)
Top Likes Received
isaac 82
Gizmo 20
Brett 7
WebGuy 2
Top Likes Received (30 Days)
None yet
The UBB.Developers Network (UBB.Dev/Threads.Dev) is ©2000-2024 VNC Web Services

 
Powered by UBB.threads™ PHP Forum Software 8.0.0
(Preview build 20221218)