Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Few changes to MyCodes.
#1
Well at first - I will use MyCodes or BBCodes names, so it's just to inform you (personally I prefer BBCode name, byt MyCode isn't bad too).

Okay. Now few changes that maybe should be considered?

1. Some kind of MyCode priority: I have added one mycode that adds download button and it has url inside it (without bbcode). When trying to parse it I get only url parsed, and my whole own bbcode is left as is. Maybe I'm doing something wrong, so I don't know. But even if I think that adding possibility to force some bbcodes to be earlier parsed than others would make parsing them much easier.

2. Add option to include additional php file to run MyCode: Right now form ACP we can add SIMPLE MyCodes based on regex. Option to just connect special small php script to run mycode is better than writting whole plugin just to do the same thing. Also these php files could be smaller and simpler than plugins also not so powerful. It should allow people to perform more complicated stuff like getting some values from MyBB (like user name with it's format).

3. Simpler way to add new selfmade MyCodes to editor: Right now it's based on adding them through templates or right inside javascript files of editor and not always it is working properly. I had to modify url bbcode in editor just to make sure, that my new bbcode won't be parsed as URL (and these kind of things were happening all the time).

As for first "change" as I said, I can do something wrong, so if there's an option to make my own code to be invisible for other bbcodes then just tell me how to do it properly.
Reply
#2
1. Will be fixed with MyBB 1.8.16 (moving parsing standalone URLs as the last step)
2. I've replaced MyBB's parser with my own recursive own, but MyBB 2.0 (possibly 1.9) will use a different framework and parser, so it's not worth making big changes to the parser for the 1.8 series.
3. There are plugins for adding buttons to the editor, but let's see how things play out for 1.9 and 2.0.
Reply
#3
(05-14-2018, 08:46 PM)laie_techie Wrote: 1. Will be fixed with MyBB 1.8.16 (moving parsing standalone URLs as the last step)
2. I've replaced MyBB's parser with my own recursive own, but MyBB 2.0 (possibly 1.9) will use a different framework and parser, so it's not worth making big changes to the parser for the 1.8 series.
3. There are plugins for adding buttons to the editor, but let's see how things play out for 1.9 and 2.0.

The bigger parser changes may happen in 1.10 rather than 1.9 (we don't want to just keep adding stuff to 1.9 and slow down its release even futher), but otherwise this is pretty much spot on.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)