Personalized BBC

Started by Chen Zhen, June 03, 2014, 07:19:08 PM

Previous topic - Next topic

Chen Zhen

Link to Mod

Personalized BBC

Purpose and/or usage of this software package:

The purpose of this application is to allow an administrator the option to add custom BBCs to a SMF forum installation. 
These BBC additions have individual permission settings to allow or restrict their usage and visibility.
The added BBCodes can be of general use if permission settings regarding viewing and usage are enabled for all membergroups.

Important Notation:
  This modification will only hide Personalized BBC content to specified membergroups when it is installed.
  Prior to using the SMF Large Upgrade Package it is advised to put your forum in maintenance mode
  until you are able to reinstall this modification.
  Failing to follow that procedure will allow all membergroups with appropriate board permissions
  to view all those BBC's that were normally hidden.
  The same applies when uninstalling this modification.




Recommended minimal requirements:

Server: PHP 5.3+
Database: MYSQL 5.0+ using MyISAM or InnoDB engine
Browser: HTML5 capability
SMF Version: 2.0.X - 2.1.X




Developed for SMF forums c/o Chen Zhen @ web-develop.ca
Copyright 2014 - 2018 
Distributed under the CC BY-ND 4.0 License

If you commend this software package and/or any other contributions that [email protected] develops for the SMF community, please feel free to make a donation to paypal using the image/link provided below.
Thank you for opting to use this software package.






Features:


  • Create custom BB Codes for your forum
  • Add any HTML/Javascript/Text for every BB Code
  • Allow up to three options for each tag
  • Assign each one their own membergroup permissions for viewing or usage




Changelog:

[version 1.94.1]
! fixed/updated 3rd party Google jQuery link to https
! added return value to onload event anonymous function to thwart javascript warning/error in some browsers

[version 1.94]
! fixed/changed primary key for personalized_bbc table (now int auto increment)

[version 1.93]
! fixed javascript/DOM regarding addEventListener/attachEvent
! fixed improper filename for SMF 2.1 uninstall
! fixed variable variable ambiguity issue for saving BBCodes
! fixed display icons for admin list
? adjusted support website & copyright

[version 1.92]
! fixed IE compatibilty for DOM style elements
! changed window.onload to addEventListener/attachEvent

[version 1.91]
+ added javascript for optional BBCode parameters

[Version 1.9]
+ added option to enable external jQuery support (SMF 2.0.X only)

[Version 1.8]
+ added option to test bbcode within revision template
+ added onmouseover/onmouseout display events for icons in the bbcode list
+ js and css files added for use with the above additions
+ added option to enable/disable autolink
! added index.php files for the SMF 2.1 directories
! newly created bbcodes default to all allowed permissions
! disabled override for this version
! adjusted css within admin templates

[Version 1.7]
+ added option to upload images within tag settings
+ uploaded images resized to 20px x 20px dimensions
+ ../images/bbc/personalizedBBC folder not removed during uninstall to preserve uploaded images
! adjusted installer for minor issues/discrepancies
! fixed SMF 2.1 installation discrepancies

[Version 1.6]
+ mod now filters restricted bbcodes outside of posts/pm's
+ added option to allow filtering of Url entered within code input (option to conform to RFC 3986 standards)
+ added IMDb and TMDb icons
! clean_cache() function implemented for permission changes to immediately take affect
! use of un_htmlspecialchars() function for adding BBCode HTML (HTML within bbc will not function properly without this method being implemented)

[Version 1.5]
+ added SMF 2.1 support
+ includes png bbc icons for SMF 2.1 support
+ added override option for existing SMF default BBC tags
! fixed BBC button hook routine
! fixed BBC type setting for newly created tag
! various language and file changes for SMF 2.1 compatibility
! changed regex for closed tags regarding HTML5 compatibility

[Version 1.4]
+ added [Important Notation] to this readme
! changed routine for gathering SMF default BBC's
! changed routine for adjusting permissions
! max allowed BBC tag name length now 25 characters (due to display template)
! removed unnecessary filter_var() usage (regex sanitizes this variable)
! installer now includes admin icon for all custom themes
! fixed source filenames withing uninstall xml
! fixed editing of same BBC tag name from last update

[Version 1.3]
+ relays error message for characters not allowed in BBC names
! fixed existing bbc check to include BBC's not contained within $context['bbc_tags']

[Version 1.2]
! fixed images list within template and added natsort
! fixed issues regarding some inputs within templates
! fixed regex regarding permission disabled closed tags
! ensure bbc name variable(s) are lowercase
! max bbc name of 35 characters in length
! installer adjusts permission column within permissions table to 60 character max (mod-var_bbc-name_ilk)

[Version 1.1]
+ separate view & usage permission settings
! removed smcFunc escape/unescape
! natural sorting of Personalized BBC's for admin list and permissions
! checks against existing SMF default BBC's
! fixed deletion of first entry issue
! fixed check-all in admin template

[Version 1.0]
+ Initial release

Legend:
--------------------------------------------------------------------------------
! Minor change or bugfix. (don't bother to log typos except between releases.)
? Version and/or copyright changes including file comments
& Change that affects a language file. (make two if it affects templates too.)
+ Feature addition or improvement.
- Feature or option removal.

Disclaimers:
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

My SMF Mods & Plug-Ins

WebDev

"Either you repeat the same conventional doctrines everybody is saying, or else you say something true, and it will sound like it's from Neptune." - Noam Chomsky

Chen Zhen


Mod has been updated to Version 1.4, it is advised to update the modification.
Please read the changelog for details.

Regards.

My SMF Mods & Plug-Ins

WebDev

"Either you repeat the same conventional doctrines everybody is saying, or else you say something true, and it will sound like it's from Neptune." - Noam Chomsky

Chen Zhen

This mod has been updated to Version 1.6, it is advised to update the modification to implement an important fix.
Please read the changelog for details.

TMDb BBCode has been developed as an example.
If you wish to use the TMDb BBCode, you will need to register on the  TMDb website and apply for an API key.
The BBCodes use their TV and Movie ID's to gather the data which also references an IMDb link.
Their policy requires you to leave the TMDb logo (very small) in order to use their API service.
(IMDb link is the movie/show text and the TMDb logo is the TMDb link ~ both will forward to the respected show/movie being referenced)

Click Here for the TMDb BBCode

Regards.

My SMF Mods & Plug-Ins

WebDev

"Either you repeat the same conventional doctrines everybody is saying, or else you say something true, and it will sound like it's from Neptune." - Noam Chomsky

Chen Zhen

Mod has been updated to version 1.7.
This version will now allow an admin to upload image icons.
Personalized BBC is compatible with SMF 2.0.X and SMF 2.1 installations.

Please see the change log for details.

My SMF Mods & Plug-Ins

WebDev

"Either you repeat the same conventional doctrines everybody is saying, or else you say something true, and it will sound like it's from Neptune." - Noam Chomsky

Apllicmz

Nice work
when update dont forget portuguese files
Attach




Chen Zhen

Joomlamz,

  Thanks for your interest in this modification.
I appreciate your translation of the language files however the most recent update included many additional changes/additions to those files.
You are more than welcome to post additional updated translated language files to this board: Click Here

Regards.

My SMF Mods & Plug-Ins

WebDev

"Either you repeat the same conventional doctrines everybody is saying, or else you say something true, and it will sound like it's from Neptune." - Noam Chomsky

Ninja ZX-10RR

The last update throws 2 modification parse error in the xml files that I wasn't able to spot. Version 1.7 installs with no issues. (damn I was still running 1.5! xD)
Quote from: BeastMode topic=525177.msg3720020#msg3720020
It's so powerful that on this post and even in the two PMs you sent me,you still answered my question very quickly and you're apologizing for the delay. You're the #1 support I've probably ever encountered man, so much respect for that. Thank you, and get better soon.

I'll keep this in my siggy for a while just to remind me that someone appreciated what I did while others didn't.

♥ Jess ♥

STOP EDITING MY PROFILE

Chen Zhen

#7
♦ Ninja ZX-10RR ♦ ,

  After your report I have tested v1.8 on a default installation of SMF 2.0.9 and receive no such issues.

Imo this may be caused by another mod that was previously installed and has edited SMF code in like areas. There is one additional edit added for the SMF 2.0.X branch within Subs.php for the purpose of adding BBCodes to the no link array. however this should not cause 2 errors as compared to v1.7 since it is only one additional edit.  Actually there is another difference in the installation part that executes actual SMF edits whereas 2 xml install files are executed, perhaps this is causing the issue (not for me while testing it though)?

What are the specific errors being flagged during the v1.8 installation?

My SMF Mods & Plug-Ins

WebDev

"Either you repeat the same conventional doctrines everybody is saying, or else you say something true, and it will sound like it's from Neptune." - Noam Chomsky

Ninja ZX-10RR

Just "modification parse error" for the 2 latest xml files... No errors in the error log (since I am not going on with it) and nothing else, no clues, that's why I posted like that otherwise I would have provided more detail :(
Quote from: BeastMode topic=525177.msg3720020#msg3720020
It's so powerful that on this post and even in the two PMs you sent me,you still answered my question very quickly and you're apologizing for the delay. You're the #1 support I've probably ever encountered man, so much respect for that. Thank you, and get better soon.

I'll keep this in my siggy for a while just to remind me that someone appreciated what I did while others didn't.

♥ Jess ♥

STOP EDITING MY PROFILE

Chen Zhen

 ♦ Ninja ZX-10RR ♦,

  Under closer inpection I noticed that I made a small error regarding the folder names within the installation whereas some should have been uppercase. In addition I also gave both SMF versions their own single install.xml file. If you are willing to help me out by testing the new installation I added to the download page (personalizedBBC_v1.8x) I would be very appreciative. If not and you are happy with v1.7 then that is fine.

Regards.

My SMF Mods & Plug-Ins

WebDev

"Either you repeat the same conventional doctrines everybody is saying, or else you say something true, and it will sound like it's from Neptune." - Noam Chomsky

Ninja ZX-10RR

You got it :D works! Btw I am always available to test things as long as they are not *terribly* time consuming ;) and this was definitely easy to test and report, works :) thank you for the fix!
Quote from: BeastMode topic=525177.msg3720020#msg3720020
It's so powerful that on this post and even in the two PMs you sent me,you still answered my question very quickly and you're apologizing for the delay. You're the #1 support I've probably ever encountered man, so much respect for that. Thank you, and get better soon.

I'll keep this in my siggy for a while just to remind me that someone appreciated what I did while others didn't.

♥ Jess ♥

STOP EDITING MY PROFILE

Chen Zhen


♦ Ninja ZX-10RR ♦,

  Strangely, at the moment  the download count for that version still says 0 even though you say it was downloaded.  ???
Thank you for taking the time to test the modification and for the report.

Regards.

My SMF Mods & Plug-Ins

WebDev

"Either you repeat the same conventional doctrines everybody is saying, or else you say something true, and it will sound like it's from Neptune." - Noam Chomsky

Ninja ZX-10RR

Lol, I don't know about that but you can rest assured that I did download it and works :) a screenshot would be useless since my timezone is WAY different than the one of this forum :P
Quote from: BeastMode topic=525177.msg3720020#msg3720020
It's so powerful that on this post and even in the two PMs you sent me,you still answered my question very quickly and you're apologizing for the delay. You're the #1 support I've probably ever encountered man, so much respect for that. Thank you, and get better soon.

I'll keep this in my siggy for a while just to remind me that someone appreciated what I did while others didn't.

♥ Jess ♥

STOP EDITING MY PROFILE

Chen Zhen

#13
♦ Ninja ZX-10RR ♦,

  I will show you an example of its usage with the type of content you convey.

ie.
BBCode:

name: weapon
description: weapon display
type: [tag=option]content[/tag]
no parsing

code:
<img style="width: 600px; height: 200px;" src="http://oi57.tinypic.com/{option}.jpg" alt="" /><hr /><hr /><hr /><span style="font-size: 14pt;font-weight: bold;">{content} (more up to come)</span>

icon: .. upload & use a weapon icon

permissions: ... up to you. ie. viewing for all but possibly only admin/mod usage?

example bbcode usage for above:

[center][weapon=35ltbmf]1st Assault rifle[/weapon][/center]





Regards.

My SMF Mods & Plug-Ins

WebDev

"Either you repeat the same conventional doctrines everybody is saying, or else you say something true, and it will sound like it's from Neptune." - Noam Chomsky

margarett

The modsite has some way of filtering downloads counter to prevent abuse. That's why you can download a mod multiple times and it won't get counted.
Unfortunately it seems not to differentiate versions...
Se forem conduzir, não bebam. Se forem beber... CHAMEM-ME!!!! :D

QuoteOver 90% of all computer problems can be traced back to the interface between the keyboard and the chair

Ninja ZX-10RR

Wew nice Chen Zhen that's complicated but I think I can do it with a bit of studying :) thank you very much for that anyway! I really appreciate some guidelines :D

@margarett tell the devs maybe? I'd call it a bug, or at least a misfunction that can lead to misunderstandings such as the one before since I had downloaded the mod and I looked like an idiot since the mod counter was still at 0 xD
P.s. Downloaded by proxy just to raise the counter and be fair :)
Quote from: BeastMode topic=525177.msg3720020#msg3720020
It's so powerful that on this post and even in the two PMs you sent me,you still answered my question very quickly and you're apologizing for the delay. You're the #1 support I've probably ever encountered man, so much respect for that. Thank you, and get better soon.

I'll keep this in my siggy for a while just to remind me that someone appreciated what I did while others didn't.

♥ Jess ♥

STOP EDITING MY PROFILE

margarett

To be fixed only in the new Cust site. The current one will probably not have further development ;)
Se forem conduzir, não bebam. Se forem beber... CHAMEM-ME!!!! :D

QuoteOver 90% of all computer problems can be traced back to the interface between the keyboard and the chair

Ninja ZX-10RR

Quote from: margarett on October 24, 2014, 02:16:31 PM
new Cust site
Wooooooooooooooooot that's some spoiler XD Or well I guess you will update to 2.1 sooner or later and also the cust site will change... So yeah I should have known it. Too bad that I will just stop with 2.0.x instead, and not even posting anymore :/ but whatever thanks for telling me I will be looking forward to see it :) thank you as always your help and info is much appreciated.
Quote from: BeastMode topic=525177.msg3720020#msg3720020
It's so powerful that on this post and even in the two PMs you sent me,you still answered my question very quickly and you're apologizing for the delay. You're the #1 support I've probably ever encountered man, so much respect for that. Thank you, and get better soon.

I'll keep this in my siggy for a while just to remind me that someone appreciated what I did while others didn't.

♥ Jess ♥

STOP EDITING MY PROFILE

NekoJonez

When I click on test, everything gets reset and the test results display. :/
Retro video game blogger, writer, actor, podcaster and general amazing dude.

Twitter
My Blog

Chen Zhen

NekoJonez,

  I do not seem to be able to duplicate your issue. When you use the test button the routine saves the tag's current settings, reverts back to the tag's settings template and displays the result at the bottom of the page.  Are you saying that you are experiencing it reverting all a tag's settings to default instead of what you enter for it?

My SMF Mods & Plug-Ins

WebDev

"Either you repeat the same conventional doctrines everybody is saying, or else you say something true, and it will sound like it's from Neptune." - Noam Chomsky

Advertisement: