BB-Code-Button for Code-Block (Features)

by Auge, Monday, June 22, 2009, 01:28 (5421 days ago) @ Micha

Hello Milo

I think, your solution is a bit overcomplicated. Some people would miss the PopUp (blocked or a missed new tab instead a PopUp)

I think, a blocker-software do not block this popup because it is not a undesirable window.

Yes, it's a desired window. I don't know if some browsers allow it to forbid PopUps for every case? It was only an idea. In other hand, if there is no needed window, there is no need to handle this window. :-)

... in this case you can create a new box inside the document instead to open a new window. In this box the user selects only the language for the code-BB-code and that's it.


Like the colorpicker? Yes, that's possible but, in my discretion, it is not a better solution because the php-script has to read the geshi-directory permanent.

What you mean with "permanent"? The script would read and act and write and do anything when the page is requested. When the page is supplied PHP's work is done. If you mean "every time the page is requested", yes that's the case (see below).

At the moment, the directory will only be read, if the list of languages are required. Isn't it the better way?

It's the same way (generally; some posters will not use code blocks). But, what's the problem to deliver a list of supported languages (I don't know geshi's code)? All other steps are independent from any external code. With the list you can build a JavaScript array into the source code of the page to build the box via JavaScript if the code button is pushed. Or you fetch the list via Ajax and build the box that way. What remains is to react to a click or something similar to put the BB-codes into the textarea. And that's done.

Tschö, Auge


Complete thread:

 RSS Feed of thread