Follow Us:


Tricked Out Mods: Forums


 Forum FAQForum FAQ   SearchSearch   UsergroupsUsergroups   ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Advanced BBCode Box for RavenNuke v2.5
 
 
Post new topic   Reply to topic   print    Tricked Out News Forum Index -> RavenNuke
View previous topic :: View next topic  
Author Message
spasticdonkey
Super Dev Donkey
Super Dev Donkey


Joined: May 08, 2009
Posts: 77


PostPosted: Mon May 14, 2012 8:35 pm 
Post subject: Advanced BBCode Box for RavenNuke v2.5
Reply with quote

A demo, promo, and tech support thread all-in-one. While most users probably won't spend time formatting posts this nicely, it's good to know you can if you want to Smile Post back with any issues or comments as needed...




PHPBB2 Forum BBCode Modification for RavenNuke™ v2.5, which expands the standard BBCode features to allow: audio/video embeds, text formatting/styling options, image/video positioning, dynamic twitter signatures, customizable color swatches, inline ajax help, forum search "tags", modal search functions for wikipedia and duckduckgo, as well as various other features.

Improved UI and CSS layout which can be customized per theme. Four sprite powered editor themes included in sand, light blue, crimson, and black; or build your own with a little CSS know-how and the included photoshop files. Several optional addons are included to further enhance your RavenNuke™ powered site; which allows you to add code highlighting, link icons, easy youtube videos, and/or hashtags.

After an easy installation, courtesy of a comprehensive, kickstart powered install guide, you may find yourself asking, "Who needs phpbb3?"

New Features

Improved UI, CSS Layout, and CSS Sprites
Editor Toolbars are styled completely via CSS, allowing the editor to be styled to match individual themes and break-out of the MS-Word 2003 look. All images within the editor now use CSS sprites, with many buttons featuring mouseover and toggle effects. The majority of toolbars are hidden initially, and are toggled into view by one of the visible buttons; with a nice jQuery SlideToggle animation.

Text Size Selection
Font size selection now uses buttons instead of a select menu, and also utilizes CSS classes instead of inline styling. In most cases relative sizes are used, which offers greater flexibility regardless of the initial default font-size that a given theme/visitor is using. Another advantage of using buttons, is that previously the same text size could not be applied more than once in a row; as the bbcode was only inserted when the value of the select menu changed.

Font Type and Custom Classes
Font type selection also uses buttons instead of a select menu, utilizing CSS classes instead of inline styling. Basic font classes are defined to display the most similar font regardless of operating system or browser, as not all fonts are actually available on all operating systems. Font declarations can be overridden by theme, so if you prefer to replace a button with a custom font (like those from font squirrel) you can!

Size and Positioning Options for Multimedia Embeds
A variety of size and positioning options have been added for YouTube and (the newly added) Internet Archive video embeds. Both embed types utilize the iframe method, which allows for device specific videos to be delivered to the user. This means the user may get a html5 or flash video depending on the capabilities of the given device viewing the site. Size and positioning options are CSS based and can be customized by theme

Custom Color Swatches and Color Picker
The color select menu has been replaced by swatches that can be customized by theme. For example, there is no reason to offer black text if your theme uses black backgrounds. Also offers the advantage of matching the color palette to an individual theme, as dark colors work better for light backgrounds, and pastel colors work better for dark backgrounds. Custom hex colors can be applied via the newly added jscolor color picker.

Various New Features
While not a complete overview, just a few of the new features available in ABBC2.5

DuckDuckGo Web Search in Modal RavenNuke
Wikipedia Search in Modal RavenNuke
International Wikipedia Search in Modal suerte
Forums Search/Keyword Tag forum mod advanced bbcode box
Dynamic Twitter Signature nuken1

Internet Archive (audio)
Internet Archive (video)
Video Size
Video Position
<- Video Size & Position
Non-BBCode Features

Inline Ajax Help
Several of the toolbars feature inline help which is loaded directly into the editor via ajax, giving users basic tips without having to open another browser window.

Full Width Padded Textarea
A somewhat experimental 100% width cross-browser padded auto-expanding textarea (that's a mouthful), which is not an easy task due to the differences with how textareas are rendered by various browsers. A minimum and maximum height can be configured so that the textarea doesn't grow more than desired (default max 600px) as at some point the user would need to scroll anyway... (running out of visible space in the browser window)

Insert at Caret Position
In order to perform more like an actual editor, all codes are now inserted at the caret position; as well as updating the caret position code for smilies which did not work reliably in some browsers. Tested in browsers below.

Browser Compatibility
Tested on Firefox (Win7,WinXP,Linux Mint), Internet Explorer 8-9 (WinXP,Win7), Google Chrome (WinXP,Win7), Safari (Win7), and Opera (Win7)

Optional Features

Code Highlighting featuring Highlight
Highlight.js highlights syntax in code examples on blogs, forums and in fact on any web pages. It's very easy to use because it works automatically: finds blocks of code, detects a language, highlights it. Growing assortment of CSS based themes allows highlighting to be customized on a theme-by-theme basis. 16 languages are supported by default, although over 40 languages can be used if required by an individual site. The basic 16 valid classes are: apache, bash, cpp, cs, css, diff, html, ini, java, javascript, perl, php, python, ruby, sql, xml

Iconize Links to Desired Sites
A purely CSS based addon which automatically adds icons to links, allowing for specific icons to be used for specific sites. Use the included Vector Social Media Icons to "Iconize" as many popular social sites as desired; or create/find your own icons to "Iconize" your favorites sites from around the web. Easy to add sites and customize to your needs. Intended for use in the forums, but can be used sitewide if desired.

Easy YouTube Video Embeds
Let's face it, users are lazy or don't necessarily always understand how to use bbcode. So why not allow for easy embedding of youtube videos by simply including the URL to the video, with no extra markup required? Enter the EasyTube Mod to add auto-embed support for over a dozen popular youtube URL's. Special thanks to eldorado for the idea and getting the ball rolling on implementation, and to ridgerunner for writing and maintaining an excellent regular expression suited for the job.

Tricked Out News #hashtag Mod
Adds a Twitter like hashtag mod for your RavenNuke™ forum. If you are not familiar with hashtags, they are any SINGLE word that you place the # sign in front of, to link to a keyword search in the forum. Although it functions in a similar manner to that of the newly added term it makes a nice shorthand compliment for quickly tagging desired posts. Not to mention, installation only requires one additional line of code! Thanks nuken!

Find it at Tricked Out News and get previews or become a fan of the mod on Facebook: www.facebook.com/AdvancedBBCodeBoxForRavenNuke
  
Back to top
View user's profile Send private message Visit poster's website
spasticdonkey
Super Dev Donkey
Super Dev Donkey


Joined: May 08, 2009
Posts: 77


PostPosted: Mon May 14, 2012 11:24 pm 
Post subject:
Reply with quote

Preview of language specific highlighting
note these code snippets are only samples of language specific highlighting and have nothing to do with the mod

apache Code:
# -------------------------------------------

# Only process if mod_expires is installed
# For faster load times cache certain types of files for specific amount of time
# You should adjust these settings based upon your caching requirements
# -------------------------------------------
<IfModule mod_expires.c>
ExpiresActive On
# ExpiresDefault A86400
ExpiresByType image/x-icon "access plus 1 month"
ExpiresByType text/css "access plus 5 minutes"
ExpiresByType image/gif "access plus 1 month"
ExpiresByType image/png "access plus 1 month"
ExpiresByType image/jpeg "access plus 1 month"
ExpiresByType text/plain "access plus 15 minutes"
ExpiresByType application/x-shockwave-flash "access plus 1 month"
ExpiresByType video/x-flv "access plus 1 month"
ExpiresByType application/pdf "access plus 1 month"
# ExpiresByType text/html "access plus 5 minutes"
ExpiresByType text/javascript "access plus 5 minutes"
ExpiresByType application/x-javascript "access plus 5 minutes"
# Force no caching for dynamic files
<FilesMatch "\.(php|cgi|pl|html)$">
#no cache for php files, cgi files, pl files, html files.
ExpiresActive Off
Header set Cache-Control "private, no-cache, no-store, proxy-revalidate, no-transform"
Header set Pragma "no-cache"
</FilesMatch>
</IfModule>


css Code:
/* background to match textarea message box to simulate cross-browser padding */

#posttable td.messageback,.abbchelpbars{color:#707274;padding:6px;
background-color: transparent;
background-image: url(images/bg-tall.gif); /* other browsers */
background-image: -ms-linear-gradient(top, #EFEFEF 0%, #e1e5ee 100%);/* IE10 */
background-image: -moz-linear-gradient(top, #EFEFEF 0%, #e1e5ee 100%);/* Mozilla Firefox */
background-image: -o-linear-gradient(top, #EFEFEF 0%, #e1e5ee 100%);/* Opera */
background-image: -webkit-gradient(linear, left top, left bottom, color-stop(0, #EFEFEF), color-stop(1, #e1e5ee ));/* Webkit (Safari/Chrome 10) */
background-image: -webkit-linear-gradient(top, #EFEFEF 0%, #e1e5ee 100%);/* Webkit (Chrome 11+) */
background-image: linear-gradient(top, #EFEFEF 0%, #e1e5ee 100%)}


html Code:
		<div id="preamble">

<h3><span>The Road to Enlightenment</span></h3>
<p class="p1"><span>Littering a dark and dreary road lay the past relics of browser-specific tags, incompatible <acronym title="Document Object Model">DOM</acronym>s, and broken <acronym title="Cascading Style Sheets">CSS</acronym> support.</span></p>
<p class="p2"><span>Today, we must clear the mind of past practices. Web enlightenment has been achieved thanks to the tireless efforts of folk like the <acronym title="World Wide Web Consortium">W3C</acronym>, <acronym title="Web Standards Project">WaSP</acronym> and the major browser creators.</span></p>
<p class="p3"><span>The css Zen Garden invites you to relax and meditate on the important lessons of the masters. Begin to see with clarity. Learn to use the (yet to be) time-honored techniques in new and invigorating fashion. Become one with the web.</span></p>
</div>
<!-- some html comment -->


php Code:
setcookie('lang', $language, time() + 31536000);

include_once 'language/lang-' . $language . '.php';
$currentlang = $language;


sql Code:
DROP TABLE IF EXISTS $prefix.`_banned_ip`;

CREATE TABLE IF NOT EXISTS $prefix.`_banned_ip` ( `id` int(11) NOT NULL auto_increment, `ip_address` varchar(15) NOT NULL default '', `reason` varchar(255) NOT NULL default '', `date` date NOT NULL default '0000-00-00', PRIMARY KEY (`id`) ) ENGINE=MyISAM;
  
Back to top
View user's profile Send private message Visit poster's website
Palbin
Regular
Regular


Joined: May 23, 2009
Posts: 15


PostPosted: Tue May 15, 2012 11:45 am 
Post subject:
Reply with quote

Really nice job!!!
  
Back to top
View user's profile Send private message
spasticdonkey
Super Dev Donkey
Super Dev Donkey


Joined: May 08, 2009
Posts: 77


PostPosted: Thu May 17, 2012 6:41 pm 
Post subject:
Reply with quote

thanks Smile On a bbcode side note, I found that I needed to load bbcode_addons.css in the Feeds module for feed previews as well... Not a huge issue that I will update the mod for at this time, but thought end-users should be aware of it.... You'll have to tweak head-abbcbox.php to load bbcode_addons.css in other modules.... you may also have issues with large videos within feed and forum news previews and I used this to override the large size without affecting the other embeds. Add at bottom of bbcode_addons.css and adjust to desired size.

css Code:
/*feed and forum news previews*/

.modules_html_item_description div.video-large iframe,.modules_html_item_description div.video-large-left iframe,.modules_html_item_description div.video-large-right iframe,.modules_html_item_description div.video-large-center iframe,.posttext div.video-large iframe,.posttext div.video-large-left iframe,.posttext div.video-large-right iframe,.posttext div.video-large-center iframe{width:480px;height:360px}


forum news advanced bbcode box
  
Back to top
View user's profile Send private message Visit poster's website
Guardian
Blingaholic
Blingaholic


Joined: Nov 03, 2009
Posts: 25


PostPosted: Thu May 17, 2012 11:52 pm 
Post subject:
Reply with quote

I'm hoping to finally get around to trying this at the weekend. My use case is slightly different as I have already stripped out a large portion of the forum .tpl files on my site but hopefully, it shouldn't take to long to merge this.
  
Back to top
View user's profile Send private message
spasticdonkey
Super Dev Donkey
Super Dev Donkey


Joined: May 08, 2009
Posts: 77


PostPosted: Fri May 18, 2012 9:40 am 
Post subject:
Reply with quote

cool stuff! I imagine for someone of your experience it should be fairly easy, but I don't know exactly how you have customized things. Most edits are relatively minor with the exception of posting_body.tpl and bbcode.tpl. Note that there were updates to the files I gave you via PM, so you should grab a fresh copy here....

Did notice a couple small issues, the hashtag mod creates links in code samples (see my css example above, (#posttable)). I suppose we could encode # within code samples to prevent this, although the code samples are already overly-encoded to prevent smilies and other bbcode tags. At times, over encoding may cause some anomalies within the highlighting.. nothing major but you may occasionally see some colors that end before/after a colored term/keyword. In normal use there is no reason to encode : ( ) { } [ ] within pre and you will notice the highlighter performing more reliably when you don't.... not that it performed badly, just striving for perfection Smile Most of the highlighting scripts I tried did NOT handle code highlighting in the forums very well, which is why I chose the lesser known highlight.js. Geshi probably could have done the job, but was overkill and harder to configure, imo.

make_clickable will also add links of the type www within code samples, but it did that prior to the mod.. as long as it is preceded by a space.

Code:
// www.code-authors.com/


Not a huge issue as it's still valid to have links within code samples, but may cause some display irregularities with highlighting and possibly applying some undesired link styling as well. That's it for today's update Smile
  
Back to top
View user's profile Send private message Visit poster's website
spasticdonkey
Super Dev Donkey
Super Dev Donkey


Joined: May 08, 2009
Posts: 77


PostPosted: Mon May 21, 2012 8:00 pm 
Post subject:
Reply with quote

Another update:
Twitter Signatures
Did some experimenting trying to get "rate limited" by twitter prior to releasing the mod, to no avail... Yet managed to accomplish it by accident last night. Was doing cross-browser testing of a forum theme and was refreshing in 5 browsers numerous times.. Not thinking about the fact the test page I was viewing had multiple twitter sigs on it. Just a warning more than anything, not to go too overboard with twitter sigs and don't use a page with twitter sigs when refreshing multiple times Smile

i believe it would still be difficult for a user in standard use of a given site to reach the 150 per hour limit. Each twitter username = 1 request per page load, regardless of how many times it appears on the page. So if you have 2-3 different username sigs per page, the user would have to visit 50-75 pages in the course of an hour to become "rate limited".

What happens when you get "rate limited" you ask? Most importantly, since this is a user-side request it does not effect the given site, or the ability of other users to view signatures. Even if you are "rate limited" you can still use twitter directly as you normal would (pc/mobile) - you just wont get valid responses to anonymous json requests to the twitter api; until your block expires... Which is temporary and based on IP. Mine seemed to last a couple hours.

For the time being keep your eyes on it, and if you notice signatures failing to load in normal operation of a site, let me know. I will probably be looking at a more complex method capable of caching twitter responses down the road, but it will be awhile. Curious if html5 local storage could be used, but that's for another day.

Highlight JS
Pleased to announce that RavenNuke and the ABBC Mod are now listed on the official addons for Highlight JS
http://softwaremaniacs.org/soft/highlight/en/addons/

Was also able to contribute a new southwest-inspired highlighting style which will be included in a future release of Highlight JS... But you can get it ahead of time right here for use with ABBC Box Smile

EDIT: Not sure the download below is working, if so try direct link
  
Back to top
View user's profile Send private message Visit poster's website
Guardian
Blingaholic
Blingaholic


Joined: Nov 03, 2009
Posts: 25


PostPosted: Tue May 22, 2012 10:57 am 
Post subject:
Reply with quote

All great stuff. Will re-read these updates as soon as I have time but just wanted to post so you know the work is appreciated!
  
Back to top
View user's profile Send private message
spasticdonkey
Super Dev Donkey
Super Dev Donkey


Joined: May 08, 2009
Posts: 77


PostPosted: Wed May 23, 2012 9:55 pm 
Post subject:
Reply with quote

Hey no prob, always glad to share. Hope you project goes well and on time Smile

Think I made some progress toward a solution for twitter rate limiting... short of a complex caching system cookies are the next best thing. The twitter response for each twitter username will now be stored in a cookie, which expires at the end of the browsing session. While this will fail if JS is enabled and cookies are blocked, but it would still be difficult to reach the limit in normal use, as mentioned previously. For the majority of users it will mean 1 request per twitter username, per browsing session. Mucho better!

I may do some type of patch/fix release but not for awhile, so if you want to deploy the solution now:

All copies of bbcode.tpl and don't forget modules/Forums/templates/subSilver (especially if you are using the Forum News module)
FIND
html Code:
<!-- BEGIN twitter_last -->

<a class="postlink ftweet ficon" href="http://twitter.com/{USERNAME}">{USERNAME}</a>
<div class="tweets tw{USERID}"><img src="mods/bbcode_box/images/76.png" alt=""/></div>
<script type="text/javascript">
$(document).ready(function(){
if ( typeof y{USERID} == "undefined" ) {
y{USERID} = 0;
n{USERID} = $("div.tweets.tw{USERID}").length;
}
if (n{USERID}<2) {
$.getJSON("http://twitter.com/statuses/user_timeline/{USERNAME}.json?callback=?", function(data) {
$(".tweets.tw{USERID}").html(ify.clean(data[0].text));
});
}
else if (y{USERID}==0){
$.getJSON("http://twitter.com/statuses/user_timeline/{USERNAME}.json?callback=?", function(data) {
$(".tweets.tw{USERID}").html(ify.clean(data[0].text));
});
++y{USERID};
}
});
</script>
<!-- END twitter_last -->

REPLACE WITH
html Code:
<!-- BEGIN twitter_last -->

<a class="postlink ftweet ficon" href="http://twitter.com/{USERNAME}">{USERNAME}</a>
<div class="tweets tw{USERID}"><img src="mods/bbcode_box/images/76.png" alt=""/></div>
<script type="text/javascript">
$(document).ready(function(){
var chk{USERID} = $.cookie("tw{USERID}");
if ( chk{USERID} > "" ) {
$(".tweets.tw{USERID}").html(ify.clean(chk{USERID}));
} else {
if ( typeof y{USERID} == "undefined" ) {
y{USERID} = 0;
n{USERID} = $("div.tweets.tw{USERID}").length;
}
if (n{USERID}<2) {
$.getJSON("http://twitter.com/statuses/user_timeline/{USERNAME}.json?callback=?", function(data) {
$.cookie("tw{USERID}", data[0].text);
$(".tweets.tw{USERID}").html(ify.clean(data[0].text));
});
}
else if (y{USERID}==0){
$.getJSON("http://twitter.com/statuses/user_timeline/{USERNAME}.json?callback=?", function(data) {
$.cookie("tw{USERID}", data[0].text);
$(".tweets.tw{USERID}").html(ify.clean(data[0].text));
});
++y{USERID};
}
}
});
</script>
<!-- END twitter_last -->


This code requires jQuery cookie, so modifications to head-abbcbox.php are needed to load it. I've tweaked my copy so there are more options for loading specific things within certain modules... either take care of loading jquery.cookie on your own or modify your copy of head-abbcbox.php. This version is compatible either with or without Forum News

php Code:
<?php

/************************************************************************/
/* CSS and JS requirements for ABBC MOD */
/* Using RavenNuke(tm) v2.5+ (required!) */
/************************************************************************/

if (realpath(__FILE__) == realpath($_SERVER['SCRIPT_FILENAME'])) {
header('Location: ../../index.php');
exit('Access Denied');
}
/************************************************************************/
// SETTINGS - Note that making changes to these settings may require
// edits or other changes. Please refer to the included documentation
// $LoadABBCcss: only set to false if you are handling your own CSS loads or appending required CSS to your style.css
// $bbcodestyles: array of modules to load bbcode_addons.css in, only if $LoadABBCcss = true;
// $bbcodeeditor: array of modules to load bbcode_box.css in, required for editor, only if $LoadABBCcss = true;
// $bbcodeextras: array of modules to load bbcode_extras.js in; required for display of twitter signatures and spoiler button
// $UseCodeHighligher: enables code highlighting
// $use_highlighter: array of modules to use the code highlighter in
// $IE8HighlightFix: true enables loading of conditional ie<9 stylesheet, otherwise ie8 will display code double spaced, comes at cost of code no longer being indented
// $HighlightFixMods: array of modules to use ie8 fix: only needed if BR is used within code samples
/************************************************************************/
$LoadABBCcss = true;
$bbcodestyles = array('Forums','Private_Messages','Feeds','Forum_News','Your_Account');
$bbcodeeditor = array('Forums','Private_Messages');
$bbcodeextras = array('Forums','Private_Messages','Feeds','Forum_News','Your_Account');
$UseCodeHighligher = true;
$use_highlighter = array('Forums','Private_Messages','Feeds','Forum_News');
$IE8HighlightFix = true;
$HighlightFixMods = array('Forums','Private_Messages');
// END SETTINGS
/************************************************************************/
// Only modify below if you know what you are doing :)
/************************************************************************/
// this decides which javascript function will occur when the code button is clicked
if ($UseCodeHighligher){
define('ABBC_HIGHLIGHT', 'BBCcodetype');
} else {
define('ABBC_HIGHLIGHT', 'BBCbasiccode');
}
global $user, $name;
if (!isset($name)) $name = '';
$ThemeSel = get_theme();
if (in_array($name, $bbcodeextras)){
addJSToHead('includes/jquery/jquery.js', 'file');
addJSToHead('includes/jquery/jquery.cookie.min.js', 'file');
addJSToBody('mods/bbcode_box/js/bbcode_extras.js', 'file');
}
if ($LoadABBCcss){
// only load BBCode Box CSS for Users and when needed - only load BBCode Box Editor CSS for Users
if (in_array($name, $bbcodeeditor) and is_user($user)){
// include a copy of bbcode_box.css in the the style directory of any desired theme
$BBCodeCssFile = 'themes/' . $ThemeSel . '/style/bbcode_box.css';
if (file_exists($BBCodeCssFile)) {
// theme specific style
addCSSToHead($BBCodeCssFile, 'file');
} else {
// default style
addCSSToHead('mods/bbcode_box/bbcode_box.css', 'file');
}
}
if (in_array($name, $bbcodestyles)){
// include a copy of bbcode_addons.css in the the style directory of any desired theme
$BBUserCssFile = 'themes/' . $ThemeSel . '/style/bbcode_addons.css';
if (file_exists($BBUserCssFile)) {
// theme specific style
addCSSToHead($BBUserCssFile, 'file');
} else {
// default style
addCSSToHead('mods/bbcode_box/bbcode_addons.css', 'file');
}
}
}
if ($UseCodeHighligher){
if (in_array($name, $use_highlighter)) {
// this is the default code highlighting style (if no theme specific style, change as desired)
$DefaultStyle = 'includes/jquery/styles/vs.css';
// to style by theme, rename to your preferred style to highlight.css, upload to themes/YOUR_THEME/style/
$CoderCssFile = 'themes/' . $ThemeSel . '/style/highlight.css';
if (file_exists($CoderCssFile)) {
addCSSToHead($CoderCssFile, 'file');
} else {
addCSSToHead($DefaultStyle, 'file');
}
if($IE8HighlightFix AND (in_array($name, $HighlightFixMods))){
$IE8fix = '<!--[if lt IE 9]><link rel="StyleSheet" href="mods/bbcode_box/ie8_highlight.css" type="text/css" /><![endif]-->';
addJSToHead($IE8fix, 'inline');
}
addJSToBody('includes/jquery/highlight.pack.js', 'file');
// this file launches code highlighting for forums, but will work for other modules as long as code is wrapped in <pre><code></code></pre>
addJSToBody('includes/jquery/start-highlight-forums.js', 'file');
}
}
?>


You will also need to remove the reference to mods/bbcode_box/js/bbcode_extras.js within all copies of overall_header.tpl
html Code:
<script type="text/javascript" src="mods/bbcode_box/js/bbcode_extras.js"></script>


If you want to add some limited advanced bbcode support to Your Account profiles, open modules/Your_Account/includes/phpbb_bbstuff.php

FIND
php Code:
		$bbcode_tpl['list_item'] = '<li>';

AFTER ADD
php Code:
		// abbc box

$bbcode_tpl['twitter'] = '<a class="postlink ftweet ficon" href="http://twitter.com/$1">$1</a><div class="tweets tw$1"><img src="mods/bbcode_box/images/76.png" alt=""/></div><script type="text/javascript">$(document).ready(function(){var chk$1 = $.cookie("tw$1");if ( chk$1 > "" ) {$(".tweets.tw$1").html(ify.clean(chk$1));} else {if ( typeof y$1 == "undefined" ) {y$1 = 0;n$1 = $("div.tweets.tw$1").length;}if (n$1<2) {$.getJSON("http://twitter.com/statuses/user_timeline/$1.json?callback=?", function(data) {$.cookie("tw$1", data[0].text);$(".tweets.tw$1").html(ify.clean(data[0].text));});}else if (y$1==0){$.getJSON("http://twitter.com/statuses/user_timeline/$1.json?callback=?", function(data) {$.cookie("tw$1", data[0].text);$(".tweets.tw$1").html(ify.clean(data[0].text));});++y$1;}}});</script>';
$bbcode_tpl['left'] = '<img src="$1" class="float-left forum-img-left" alt="" />';
$bbcode_tpl['right'] = '<img src="$1" class="float-right forum-img-right" alt="" />';
// end abbc box


FIND
php Code:
		$replacements[] = $bbcode_tpl['email'];

AFTER ADD
php Code:
		// abbc box

$patterns[] = "#\[twitter:$bbcode_uid\](.*?)\[/twitter:$bbcode_uid\]#si";
$replacements[] = $bbcode_tpl['twitter'];
$patterns[] = "#\[imgleft:$bbcode_uid\](.*?)\[/imgleft:$bbcode_uid\]#si";
$replacements[] = $bbcode_tpl['left'];
$patterns[] = "#\[imgright:$bbcode_uid\](.*?)\[/imgright:$bbcode_uid\]#si";
$replacements[] = $bbcode_tpl['right'];
// end abbc box


This adds limited support for twitter sigs (using new cookie method) and left/right aligned images. You are certainly welcome to try and port any other features; but in terms of Your Account, it was enough for me Smile
  
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:       
Post new topic   Reply to topic   print    Tricked Out News Forum Index -> RavenNuke All times are GMT - 5 Hours
 
 Page 1 of 1
 
 

Jump to:   
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum

Powered by phpBB © 2001-2008 phpBB Group
Forums ©