miniBB Support Forums | 16 years on The Web
miniBB ® 


 | Begin | Register | Reply | Search | Statistics | File Bank | Manual |
Specific miniBB Support Forums / Specific /   

FancyBOX and miniBB integration

Author Noliprel
#1 | Posted: 14 Aug 2012 20:18 
Hello everyone.
First of all, sorry for my english.

I want to integrate FancyBOX into my miniBB forum.
Well, from what I see, miniBB use of BBcode putting [imgs] tag into message image.

Question is, how can i change it ?
Thanks in advence..

Author Paul
Lead Developer
#2 | Posted: 14 Aug 2012 22:30 | Edited by: Paul 
Hey there,

bb_codes.php is the file you may modify for any new codes.
Image buttons are set up in templates/main_post_form.html

If you are a good coder, I'd recommend to use a solution on how to find where to edit this and that.

Let us know if you've got success with it.

Author Noliprel
#3 | Posted: 14 Aug 2012 22:55 | Edited by: Noliprel 
Thanks very much.
Of course I will let you know when I manage to integrate it.

By the way ..
It is a pity that paid plugins do not have their free counterparts with less functionality :-(

Author Paul
Lead Developer
#4 | Posted: 15 Aug 2012 12:45 | Edited by: Paul 
I think that the price we offer for them, is very fair. Count on many years of testing and stable versions - if you would develop such code on your end, it may take much more to invest in price. It would be really pity if we would have this, we would have that - and all of that would be in neverending development stage. Sorry! Not our point.

Author tom322
Active Member
#5 | Posted: 15 Aug 2012 17:55 
It is a pity that paid plugins do not have their free counterparts with less functionality :-(

Priorities are what counts. If you want to make your life easier and forum even more attractive, spending the small amount is absolutely worth it.

Author Noliprel
#6 | Posted: 19 Aug 2012 01:20 | Edited by: Noliprel 
So i manage to work my miniBB with FancyBOX, but .... there is one problem.

Form start, i changed these lines in bb_codes.php:

/* fixed width and ALT */
$pattern[]="/\[imgs=(http[s]*:\/\/([^<> \n\r\[\]&]+?)\.(gif|jpg|jpeg|png))\]([^<>\n\r\[\]&=\/\"']+?)\[\/imgs\]/i";
$replacement[]='<a href="\\1" class="fancybox" target="_blank"'.$GLOBALS['relFollowUrl'].'> <img src="\\1" alt="\\4" title="\\4" style="width:'.$GLOBALS['imgsWidth'].'px; border: 1px solid #bbcdb2;" /></a>';

/* fixed width */
$pattern[]="/\[imgs\](http[s]*:\/\/([^<> \n\r\[\]&]+?)\.(gif|jpg|jpeg|png))\[\/imgs\]/i";
$replacement[]='<a href="\\1" class="fancybox" target="_blank"'.$GLOBALS['relFollowUrl'].'> <img src="\\1" alt="" title="" style="width:'.$GLOBALS['imgsWidth'].'px; border: 1px solid #bbcdb2;" /></a>';

i have one problem to solve, when i add image to post i have something like that:

[imgs=http://mywebpage/forum/img/source/1.jpg]IMG TEST[/imgs]

everything ok, FancyBOX works just fine, but ... when i try to edit this post message i should see same code:

[imgs=http://mywebpage/forum/img/source/1.jpg]IMG TEST[/imgs]

Unfortunately, there is something else, something like that:

<a href="http://mywebpage/forum/img/source/1.jpg" class="fancybox" target="_blank" rel="nofollow"> [img=http://mywebpage/forum/img/source/1.jpg]IMG TEST[/img]</a>

party is over, I have to change the code manually if i want to have small thumb with FancyBOX..

My question is, why script showing <a href></a> ???

Author Paul
Lead Developer
#7 | Posted: 19 Aug 2012 21:07 
why script showing <a href></a> ?

Obviously, because of not decoding it back. Try to investigate deCodeBB function on your end - did you modified it as well?

Author Noliprel
#8 | Posted: 19 Aug 2012 21:10 
That's why i switch back to full PHPBB forum.
Everything is free & everything is working ..

Wish you luck with this project !

Author Paul
Lead Developer
#9 | Posted: 19 Aug 2012 21:33 | Edited by: Paul 
Ok, I may understand you. Instead of spending hour of work to you very own custom task, you prefer to take a code which is already here (despite it also may have its own cons...) No problem! Good luck! You are welcome to come back here after years of using to say the same ;)

If anybody still needs such of integration, I suppose we could provide it within our paid support rates (as for couple of hours of work). Unfortunately, we have no resources to support 3rd party apps, which are upgraded twice a month or even more often, with no chances, at least sometimes, to be a stable software. Also, we do not support apps which may be spyware or tracking software.

During years of my practice, I've passed through tens of jQuery image displaying extensions. LightBox, ThickBox, ColorBox, ChillBox, ShadowBox, SlimBox... now you have FancyBox... oh well, there appears to be lot of Boxing, which actually I've left many years ago. It's impossible to support all of such extensions, and there is no sense to support them, as it appears the matter of very personal taste to plug them in at all. As I've noticed, current versions go much further than the truly "open source" software - they force to load libraries from Google APIs website, so called CDN (Content Delivery Network) - it is "recommended" to load JavaScript codes from there, but nobody mentions why it's recommended.

I can explain, why. Such libraries do need often updates, as the client-side software versions come up each week, and they obviously force some updates of JavaScript code, as they change their JS routine quite well with each version. Plugging in the code, which refers to the same link each time, will save you from updating it manually, downloading the updated library, changing version number in the filename, updating the library itself, and so on.

But that also means, you can't control the code, which is inside. All the times I've thought that the root benefits of installing the open source software, is that you control the code which is inside. You know what's there; even if you don't know, lots of people know it for you. Another negative side of such inclusion, is that the website will loose in speed while loading. Obviously, loading all libraries from one connection means more speed, than if they would load from different connections.

Now it appears jQuery codes are distributed under Google downloads; that means, Google can easily track any website which refers to such codes. It's not truly open source anymore.

I think while working out the miniBB project, I will not place any of the codes on the 3rd party website downloads. When you choose, download and install miniBB, we hope to provide the highest level of personal security. It means, you run ALL codes on your own server place, with no referring to any of the 3rd party tracking websites. Surely, we will not have internal or hidden tracking in miniBB, never. That's the main point of this project: to build a completely personified, still very independant software.

I think, choosing tools like FancyBox or similar I've mentioned above, you break the level of your personal security. Static images in miniBB are shown on the screen with no problem in any browser, on any device. They can be saved on disk with no problem. The problem comes when you install solutions like this - but like I said above, it's your personal taste. If you want to limit some users in viewing the pictures the most native way, and if you would like to limit your own security - you have lots of "everything-free-in-a-mousetrap" ways to go.

Author Guest
#10 | Posted: 29 Aug 2012 11:17 
Wow it was a long reading, but Paul is right! I was waiting about couple of minutes for one website to be opened, while it was loading something extremely heavy or extremely slow from code jquery com - most likely not always jquery support servers could handle so many worldwide requests! It's a pity to sacrifice your own website or forums just because of the unbelievable "coders fashion" which appears to be an international madness these days!!!

Author Guest
#11 | Posted: 11 Oct 2012 22:08 
It's a curious topic and reading. Fancybox from Fancyapps was developed by Janis Skarnelis, the person coming from Latvia, Ikskile. As I understand, the developer of miniBB, Paul Puzyrev, comes from Latvia, too (not sure which town). It would be great if both developers co-operate for something regarding the common project, if they live a step neighborhood. But it seems, even for a simple task, they do not have a wish to co-operate.


Author Paul
Lead Developer
#12 | Posted: 12 Oct 2012 20:57 | Edited by: Paul 
You will wonder to know that Latvia is in TOP 10 of Worldwide Internet Connections by quality and speed (I think, it could be in TOP 3 in Europe at least), and here is quite a lot of IT companies and freelance coders/software developers working on various projects outside of the state.

Thanks for informing me on the authorship of Fancybox add-on - on the author's Facebook page, it is stated that Janis studied at Latvia University of Agriculture, so I'm not sure where and why did he get the coding experience, also it lets me think that the Fancybox could be just a clone of Lightbox... like many other things in Latvia you may meet, they are clones.

With miniBB it's not the same story, despite it's often considered as "phpBB" clone. However it's not clone at all. The code was written purely from scratch. The add-ons I have developed later, were all inherited from the original customer ideas, which can't be found in other forum software. Finally, miniBB trademark registered in USPTO proves we run a purely original project.

That's why I would like to cooperate with similar lever coders or projects. If Janis would like to co-operate with us directly, I would get a note about it. However I didn't get it. Then sorry.

Specific miniBB Support Forums / Specific /
 FancyBOX and miniBB integration
 Share Topic's Link

Your Reply Click this icon to move up to the quoted message

Post as a Guest, leaving the Password field blank. You could also enter a Guest name, if it's not taken by a member yet. Sign-in and post at once, or just sign-in, bypassing the message's text.

Before posting, make sure your message is compliant with our forum posting rules. If not, it may be locked or deleted with no explanation.


miniBB Support Forums Powered by Forum Software miniBB ® Home  Features  Requirements  Demo  Download  Showcase  Gallery of Arts
Compiler  Premium Extensions  Premium Support  License  Contact Us
Proceed with the Captcha add-on: protect your miniBB-forums from the automated spam and flood.