Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 Snitz Forums 2000 MOD-Group
 MOD Add-On Forum (W/Code)
 Justified Text

Note: You must be registered in order to post a reply.
To register, click here. Registration is FREE!
Before posting, make sure you have read this topic!

Screensize:
UserName:
Password:
Format Mode:
Format: BoldItalicizedUnderlineStrikethrough Align LeftCenteredAlign Right Horizontal Rule Insert HyperlinkInsert EmailInsert Image Insert CodeInsert QuoteInsert List
   
Message:

* HTML is OFF
* Forum Code is ON
Smilies
Smile [:)] Big Smile [:D] Cool [8D] Blush [:I]
Tongue [:P] Evil [):] Wink [;)] Clown [:o)]
Black Eye [B)] Eight Ball [8] Frown [:(] Shy [8)]
Shocked [:0] Angry [:(!] Dead [xx(] Sleepy [|)]
Kisses [:X] Approve [^] Disapprove [V] Question [?]

 
Check here to subscribe to this topic.
   

T O P I C    R E V I E W
Carefree Posted - 26 April 2013 : 13:12:15
This mod adds justified paragraph ability (and button) to the editor. It's available on SnitzBitz. Put this image into your images folder (save it as "icon_editor_justify.gif"), then make the following changes:

"inc_code.js"


Look for the following lines (appx 177-196):

function left() {
	var text = getText();
 	if (helpstat) {
		alert("Left tag aligns the enclosed text to the left.\n\nUSE: 
This text is aligned left
"); } else if (basic) { AddTxt="
" + text + "
"; AddText(AddTxt); } else { if (text) { txt=prompt("Text to be aligned left",text); } else { txt=prompt("Text to be aligned left","Text"); } if (txt!=null) { AddTxt="
"+txt+"
"; AddText(AddTxt); } } } Below those, insert these: function justify() { var text = getText(); if (helpstat) { alert("Justify tag justifies a paragraph (fills the line as much as possible with even right and left borders).\n\nUSE: [justify]This paragraph has justified margins.[/justify]"); } else if (basic) { AddTxt="[justify]" + text + "[/justify]"; AddText(AddTxt); } else { if (text) { txt=prompt("Text to be justified",text); } else { txt=prompt("Text to be justified","Text"); } if (txt!=null) { AddTxt="[justify]"+txt+"[/justify]"; AddText(AddTxt); } } }


"inc_func_common.asp"


Look for the following line (appx 479):

			fString = replace(fString, "
", "<br />", 1, -1, 1)

Above it, insert this:

			fString = doCode(fString, "[justify]", "[/justify]", "<p align=""justify"">", "</p>")


"inc_func_posting.asp"



Look for the following lines (appx 313-314):

		    	fString = replace(fString, "<div align=""right"">", "
", 1, -1, 1) fString = replace(fString, "</div id=""right"">", "
", 1, -1, 1) Below them, insert these: fString = replace(fString, "<p align=""justify"">","[justify]", 1, -1, 1) fString = replace(fString, "</p>","[/justify]", 1, -1, 1)


"inc_iconfiles.asp"



Look for the following line (appx 48):

Const strIconEditorHR = "icon_editor_hr.gif|23|22"

Below it, insert this:

Const strIconEditorJustify = "icon_editor_justify.gif|23|22"


"inc_post_buttons.asp"


Look for the following line (appx 58):

		"                <a href=""Javascript:hr();"" tabindex=""-1"">" & getCurrentIcon(strIconEditorHR,"Horizontal Rule","align=""top""") & "</a>" & _

Above it, insert this:

		"			<a href=""Javascript:justify();"" tabindex=""-1"">" & getCurrentIcon(strIconEditorJustify,"Justify","align=""top""") & "</a>" & _


"pop_forum_code.asp"


Look for the following lines (appx 65-68):

		"                <p><b>Striking Text:</b><br />" & vbNewLine & _
		"                Enclose your text with  and <br />" & vbNewLine & _
		"                <i>Example:</i> <b></b>mistake<b></b> = <s>mistake</s>" & vbNewLine & _
		"                </p>" & vbNewLine & _

Below those, insert these:

		"                <p><b>Aligning Text Justified:</b><br />" & vbNewLine & _
		"                Enclose your text with [justify] and [/justify]" & vbNewLine & _
		"                </p>" & vbNewLine & _

8   L A T E S T    R E P L I E S    (Newest First)
Davio Posted - 29 April 2013 : 14:20:16
quote:
Originally posted by ruirib

There are a few of us.

Yeah, you guys need to get out more.
Carefree Posted - 29 April 2013 : 12:27:42
Not sure I post mods frequently enough to make it worth the effort. Cannot seem to keep my mind on anything long enough to finish it. It's been several years since I was able to watch an entire movie without losing interest. Fortunately, I can still read a good book. I'll really be a sad case when I lose the rest of my vision.
ruirib Posted - 29 April 2013 : 11:05:34
quote:
Originally posted by HuwR

quote:
Originally posted by Carefree

LOL. Just as easy to periodically visit and read the new posts (IMHO).


I don't think everyone is as sad as we are Carefree


There are a few of us.
HuwR Posted - 29 April 2013 : 10:26:14
quote:
Originally posted by Carefree

LOL. Just as easy to periodically visit and read the new posts (IMHO).


I don't think everyone is as sad as we are Carefree
Carefree Posted - 29 April 2013 : 09:44:02
LOL. Just as easy to periodically visit and read the new posts (IMHO).
HuwR Posted - 29 April 2013 : 08:19:46
@MaGraham

I have enabled subscriptions (FORUM/Topic) for this forum so you can subscribe and not miss MODS when Carefree posts them
Carefree Posted - 29 April 2013 : 05:35:46
I've written hundreds of mods over the years, some on request, most in answer to suggestions. For a while, I kept a folder full of Snitz mods - but I guess I didn't always put the new ones there. I was looking for one I had done regarding embedding a Google Image link, but cannot seem to find it. Doesn't matter. I wrote another little mod on a similar idea (embedding a CNN news link). Now I'm considering a single link to retrieve both based on a topic's title if in a news forum.
MaGraham Posted - 29 April 2013 : 04:25:32
LOVE IT!

I wish you would consider starting an email list and, for those who are interested, send out an email notification when you've done a new mod, Carefree. And, place me at the top of that list.

Seriously, I would have hated to have missed this! I LOVE adding a little something extra for my members! And, for those of us who are perfectionists. . .this is COOL!

THANK YOU!



Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.1 seconds. Powered By: Snitz Forums 2000 Version 3.4.07