Advertisement:

Author Topic: Custom BBCodes Manager  (Read 67515 times)

Offline seremoni

  • Newbie
  • *
  • Posts: 3
Re: Custom BBCodes Manager
« Reply #200 on: July 31, 2017, 01:48:56 PM »
UPDATE:  I'm sorry I've put off dealing with this mod for so long.  I've been trying to deal with life issues recently and haven't felt like trying to tackle this problematic mod....

I'm starting a top-to-bottom rewrite of this mod.  I will be taking a completely different approach to defining the custom bbcode tags, mandating a completely new table format for version 3.0.  It will be completely incompatible with version 1.x and 2.x tables, and you probably will have to redefine all of your custom bbcode tags. The database table for version 3.0 will be more flexible, so that further additions can be made without messing with the database table format.

Please update.

Offline dougiefresh

  • SMF Hero
  • ******
  • Posts: 2,691
  • Mod King
    • XPtsp.com Community
Re: Custom BBCodes Manager
« Reply #201 on: July 31, 2017, 11:45:37 PM »
Gee, let me just whip out my magic wand and BAM, omg, it's fixed.....  NOT!  :o
News: Missing GitHub repository...

My Free Simple Machines mods on XPtsp.com, Simple Machines Customization Site, and at GitHub!
Problem uninstalling mods?  Try Arantor's Sortable Packages (and Installed Time) mod!  It's super helpful!

Offline seremoni

  • Newbie
  • *
  • Posts: 3
Re: Custom BBCodes Manager
« Reply #202 on: August 02, 2017, 03:01:51 PM »
Relax, my friend, we wait.

Offline dougiefresh

  • SMF Hero
  • ******
  • Posts: 2,691
  • Mod King
    • XPtsp.com Community
Re: Custom BBCodes Manager
« Reply #203 on: August 06, 2017, 11:46:09 PM »
UPDATE: I apologize for the unacceptably long wait.....  I've finally gotten through my massive list of mods, fixing everything possible as quickly as possible.  I'm going to start looking at this mod in the next few days (today is Sunday for me at 10:50pm - probably Tuesday, not Monday).  Please note that this won't be a simple fix, as I don't understand why the database isn't being created (or a hundred other different complaints --- sarcasm....  gotta love it!)

@seremoni:  I'm sorry for taking your comment the wrong way.  Was in a bad mood that day....   O:)
News: Missing GitHub repository...

My Free Simple Machines mods on XPtsp.com, Simple Machines Customization Site, and at GitHub!
Problem uninstalling mods?  Try Arantor's Sortable Packages (and Installed Time) mod!  It's super helpful!

Offline dougiefresh

  • SMF Hero
  • ******
  • Posts: 2,691
  • Mod King
    • XPtsp.com Community
Re: Custom BBCodes Manager
« Reply #204 on: August 07, 2017, 10:38:59 AM »
Uploaded v2.4 - August 7th, 2017
o Fixed edit_db.php so that database creation can occur.



@Everybody:  This update SHOULD fix the blank screen and/or error that people are seeing after installing this mod.  By removing the error (redeclaration of a function), the database will be created and the mod will function without breaking the forum.

Future updates will address other issues as I can find them, but I felt it was important to release an update that didn't break forums as soon as possible.....
News: Missing GitHub repository...

My Free Simple Machines mods on XPtsp.com, Simple Machines Customization Site, and at GitHub!
Problem uninstalling mods?  Try Arantor's Sortable Packages (and Installed Time) mod!  It's super helpful!

Offline Bugo

  • SMF Friend
  • SMF Hero
  • *
  • Posts: 1,462
  • Gender: Male
    • dragomano on GitHub
    • @dragomano on Twitter
    • Russian translations for SMF mods
Re: Custom BBCodes Manager
« Reply #205 on: August 08, 2017, 04:09:30 AM »
It seems you forgot to add some columns:

Code: [Select]
Unknown column 'last_update' in 'field list'
File: Subs-CustomBBCodesAdmin.php
Line: 225

Unknown column 'accept_urls' in 'field list'
File: Subs-CustomBBCodesAdmin.php
Line: 225

These errors occur on creating new bbcode tags.

Offline dougiefresh

  • SMF Hero
  • ******
  • Posts: 2,691
  • Mod King
    • XPtsp.com Community
Re: Custom BBCodes Manager
« Reply #206 on: August 09, 2017, 10:25:12 AM »
Uploaded v2.5 - August 9th, 2017
o Readded missing database fields removed by version 2.4 update.



@Bugo:  Thanks for the report!  It's been fixed....
News: Missing GitHub repository...

My Free Simple Machines mods on XPtsp.com, Simple Machines Customization Site, and at GitHub!
Problem uninstalling mods?  Try Arantor's Sortable Packages (and Installed Time) mod!  It's super helpful!

Offline drewactual

  • Jr. Member
  • **
  • Posts: 240
    • College Football Fan Site CFB51
Re: Custom BBCodes Manager
« Reply #207 on: August 31, 2017, 11:38:48 AM »
i don't know how you guys do what you do, but i can certainly tell you it's appreciated.  hugely appreciated.  thank you, @dougiefresh ...

this mod has my undivided attention.  i haven't implemented it but may attempt to do so tonight.  my site is college football centric and it is wide open right now with the season just underway.  i usually have between 500 and 700 people on it at any time.. i inherited a massive interwebz presence in July that went bankrupt last Feb.. i don't have the luxury right now of 'slapping this in there' and 'seeing if it sticks'. 

i do have confidence that it will work, though... just can't do it until the little hours. 

i seek this for one express purpose: to fix the copy&paste formatting issue my users are lighting me up about.  they copy from various sources across the web and share them on our site for discussion.  it happens all day every day.  the 'remove formatting' only works on the less sophisticated items they 'paste'. 

so... why I'm here and asking the community (and author) before i am knee deep and past the point of return is:

is it possible to use this mod to create a BBC that:
- uses a (beginning code) div:clear-both... div:border....div:background color... (open)table {may as well put whatever they paste in a table, and to assist in containing}
- uses a (ending code) div: clear both... table(close) {in case they opened a table} div(close)

and which basically encapsulates whatever users have pasted and w/o threat of 'breaking the forum's appearance'? 
https://www.cfb51.com is a College Football Fan Site, Store, and Publisher, launched in July of 2017

Offline NekoSensei

  • Semi-Newbie
  • *
  • Posts: 60
  • Gender: Male
  • SMF User
    • Le Pays Du Manga et des Cartoons oubliés
Re: Custom BBCodes Manager
« Reply #208 on: September 30, 2017, 08:46:18 PM »
It seems you forgot to add some columns:

Code: [Select]
Unknown column 'last_update' in 'field list'
File: Subs-CustomBBCodesAdmin.php
Line: 225

Unknown column 'accept_urls' in 'field list'
File: Subs-CustomBBCodesAdmin.php
Line: 225

These errors occur on creating new bbcode tags.

i got same with Css ...  ::)
I added

209. 'css' => 'text',
225. isset($data['css']) ? addslashes($data['css']) : '',

i don't know if it's good , but no more error now :)


other problem, the preview button show me a broken picture... :)

 

Offline dougiefresh

  • SMF Hero
  • ******
  • Posts: 2,691
  • Mod King
    • XPtsp.com Community
Re: Custom BBCodes Manager
« Reply #209 on: October 09, 2017, 09:32:28 AM »
Uploaded v2.6 - October 9th, 2017
o Added missing fields in database call in Subs-CustomBBCodeAdmin.php, as mentioned by NekoSensei.



@NekoSensei:  The database fields you mentioned have been added to the code.  Thank you for the bug report!

other problem, the preview button show me a broken picture... :)
I'm looking into this bug report.  Seems some code may have gone missing (or never got implemented).....
News: Missing GitHub repository...

My Free Simple Machines mods on XPtsp.com, Simple Machines Customization Site, and at GitHub!
Problem uninstalling mods?  Try Arantor's Sortable Packages (and Installed Time) mod!  It's super helpful!

Offline mlemke

  • Newbie
  • *
  • Posts: 2
Re: Custom BBCodes Manager
« Reply #210 on: October 15, 2017, 06:36:43 AM »
I am newbie to this Mod: I' sorry, but I can't read the whole thread searching an answere.

Are there some examples, how to code javascript in a custom BBCode? In the package were no examples included (Custom_BBCodes_Manager_v2.6.zip). (I know, Javascript is included since V 2.1), but my javacript solution generates no output :-((

My bbcode should create a link, because the manager can not parse {content} twice:

Code: [Select]
<script type="text/javascript"><!--
function spec() {
var a="{content}"
document.write("<a href='https://wiki.arages.de/index.php?title="+a+"'><i>"+a+"</i></a>");}
spec()
-->
</script>

or simple:
Code: [Select]
<script type="text/javascript"><!--
var a="{content}"
document.write("<a href='https://wiki.arages.de/index.php?title="+a+"'><i>"+a+"</i></a>");
-->
</script>

My custom bbcode is named spec, but the output is empty.

Example: [spec]Linyphia triangularis[/spec]

I hope anyone can help me.

Thanks!

Martin

Offline dougiefresh

  • SMF Hero
  • ******
  • Posts: 2,691
  • Mod King
    • XPtsp.com Community
Re: Custom BBCodes Manager
« Reply #211 on: October 17, 2017, 12:53:31 PM »
@mlemke:  You forgot a semicolon on the first line after the function declaration.  Instead of this:
Code: (Find) [Select]
var a="{content}"You need this:
Code: (Replace) [Select]
var a="{content}";Yeah, it's a small change, but you just found out how small changes can make a HUGE impact on code.....

You probably also need to change the actual link-building code to read:
Code: [Select]
document.write("<a href=" + encodeURI("https://wiki.arages.de/index.php?title="+a+"'>") + "<i>"+a+"</i></a>");}
News: Missing GitHub repository...

My Free Simple Machines mods on XPtsp.com, Simple Machines Customization Site, and at GitHub!
Problem uninstalling mods?  Try Arantor's Sortable Packages (and Installed Time) mod!  It's super helpful!

Offline hidaka

  • Newbie
  • *
  • Posts: 2
Re: Custom BBCodes Manager
« Reply #212 on: January 16, 2018, 03:06:24 PM »
Hi,

I just started using SMF and would want to use the custom BBcodes manager but I'm quite confused as there is no exact installation manual for this. I'm not sure which file should I run first in able to install this (which of these: add_remove_hooks.php , settings_install.php , edit_db.php). Also I'm not sure if I should be moving the custom files to their respective folders before or after running an install.

The only thing that is clear to me is the instructions under the Files to Edit, the exact installation is like a black hole. :-\ :'(
Help, please?

And attached is what I always get after probably running the wrong file.

Many thanks in advance! :)

Offline dougiefresh

  • SMF Hero
  • ******
  • Posts: 2,691
  • Mod King
    • XPtsp.com Community
Re: Custom BBCodes Manager
« Reply #213 on: January 16, 2018, 04:27:15 PM »
You really should use Packager Manager to install the mod.  You can install manually, but it's a lot easier to use Packager Manager.
News: Missing GitHub repository...

My Free Simple Machines mods on XPtsp.com, Simple Machines Customization Site, and at GitHub!
Problem uninstalling mods?  Try Arantor's Sortable Packages (and Installed Time) mod!  It's super helpful!

Offline hidaka

  • Newbie
  • *
  • Posts: 2
Re: Custom BBCodes Manager
« Reply #214 on: January 16, 2018, 10:25:36 PM »
You really should use Packager Manager to install the mod.  You can install manually, but it's a lot easier to use Packager Manager.

Oh great, thanks! It's fine now.
Sorry, I'm really new to SMF so I didn't know it has this kind of feature. ;)

Offline Rock Lee

  • SMF Hero
  • ******
  • Posts: 1,574
  • Gender: Male
  • Digitalizando un nuevo mundo :D
    • BomberCode.Oficial on Facebook
    • RockLee-BC on GitHub
    • @Bomber_Code on Twitter
    • Bomber Code ~ La nueva era del conocimiento
Re: Custom BBCodes Manager
« Reply #215 on: February 12, 2018, 08:00:23 PM »
I have to be attentive and go reviewing each mod to not skip any translation for confident is already done ... here I leave you with the latest translated line and some improvements!


Regards!

PD: Anything you tell me I've
¡Regresando como cual Fenix! ~ Bomber Code © 2018
Ayudas - Aportes - Tutoriales - Y mucho mas!!!

Offline dougiefresh

  • SMF Hero
  • ******
  • Posts: 2,691
  • Mod King
    • XPtsp.com Community
Re: Custom BBCodes Manager
« Reply #216 on: February 13, 2018, 09:57:30 PM »
Uploaded v2.7 - February 13th, 2018
o Updated Spanish Latin translation, courtsey of Rock Lee.
o Added translators section to README.txt.
o Added LICENSE.txt to satisfy licensing concerns.



@Rock Lee:  Thank you for updating the Spanish Latin translations.  They have been included in this version!
News: Missing GitHub repository...

My Free Simple Machines mods on XPtsp.com, Simple Machines Customization Site, and at GitHub!
Problem uninstalling mods?  Try Arantor's Sortable Packages (and Installed Time) mod!  It's super helpful!

Offline aegersz

  • Sophist Member
  • *****
  • Posts: 1,340
  • Gender: Male
  • "mods" junkie
    • dopetalk
Re: Custom BBCodes Manager
« Reply #217 on: March 05, 2018, 09:13:36 PM »
here's trouble (me, always bloody breaking the software)

i felt the need to make the following clumsy first shot of a BBCode for mixcloud:

Code: [Select]
<iframe width="100%" height="400" src="{option1}/widget/iframe/?feed=%2F{option2}%2F{option3}%2f" frameborder="0" ></iframe>{content}
note the superfluous {content}

[mixcloud=https://www.mixcloud.com, djjamestobin, dj-james-tobin-house-music-22022018][/mixcloud]

I picked up 2 minor bugs (i know that you have a love<>hate relationship with bugs ):
 
1. the keyword {content} is a constant, should not be there for unparsed_commas

2. i had to comment out the following following 2 lines that were causing the "missing column in DB error message" that is triggered when you try to save the BBCode.

3. NekoSensei added the 2 lines below a few posts back and it makes no sense to me yet it worked.

Code: [Select]
'css' => 'text',
isset($data['css']) ? addslashes($data['css']) : '',

apart from that she runs like a paid one  :laugh:
« Last Edit: March 05, 2018, 10:10:58 PM by aegersz »
Linux CentOS VPS running SMF 2.0 with 140+ mods installed (the full h/w and s/w can be seen at http://forum.drugs-and-users.org/index.php/topic,3301)

Offline zushiba

  • Jr. Member
  • **
  • Posts: 114
Re: Custom BBCodes Manager
« Reply #218 on: April 10, 2018, 09:49:35 PM »
I'm having difficulties with this mod.

Selecting a Tag Type in the Tag Type Combo box doesn't properly update the BBCode Format area. Changing the type doesn't update on the front end upon refresh meaning you have to delete the tag and start over from scratch if you want to change the type.

The Help Text for the HTML area is the same as the Tag Name area, which isn't helpful. I can't seem to get the actual BBCode to work. It's clickable on the post screen and does enter something into the box but it seems random if the options work or not.

Offline aegersz

  • Sophist Member
  • *****
  • Posts: 1,340
  • Gender: Male
  • "mods" junkie
    • dopetalk
hover BBCode
« Reply #219 on: May 12, 2018, 05:53:49 AM »
Introducing the (mouse) "hover" BBCode for non-touch screens

How to configure dougie's Custom BBCodes Manager for "hover"

@dougie THANKS !

re: https://www.simplemachines.org/community/index.php?action=post;msg=3972209;topic=560278.0

How to configure dougie's Custom BBCodes Manager for "hover"

Choose the Create New Tag button >

Tag name = hover

Tag Description for Button = hover

Tag type = Parsed Equals

The HTML used for the tag:

Code: [Select]
<abbr title="{option1}">{content}</abbr>
Usage:

[hoverBBC=MESSAGE THAT POPS UP SO NO NEED FOR A LINK]hover over me[/hoverBBC]

Example:

https://forum.drugs-and-users.org/index.php/topic,4303
« Last Edit: May 12, 2018, 06:17:30 AM by aegersz »
Linux CentOS VPS running SMF 2.0 with 140+ mods installed (the full h/w and s/w can be seen at http://forum.drugs-and-users.org/index.php/topic,3301)