phpBB

Development Discussion Board

phpBB's testing ground of bleeding edge code
Advanced search

[RFC|Merged] AJAX

These requests for comments have lead to an implemented feature that has been successfully merged into the 3.1/Ascraeus branch. Everything listed in this forum will be available in phpBB 3.1.

Re: [RFC] AJAX

Postby callumacrae » Sat Aug 20, 2011 12:58 pm

Oleg wrote:One of the reasons people brought up for using subsilver was because they considered it "lighter" than prosilver.

With eye to that argument I would say don't add ajax to subsilver until someone requests it, and if you do make very sure it impacts performance including perceived performance as little as possible.

How about release it as a modification? I'll be doing it anyway, because I know at least one of my clients with a subsilver2 based board will want the AJAX features.

~Callum
"In JavaScript, there is a beautiful, elegant, highly expressive language that is buried under a steaming pile of good intentions and blunders"
—Douglas Crockford

View my MOD, phpBB Mobile
User avatar
callumacrae
Website Team
Website Team
 
Posts: 883
Joined: Tue Apr 27, 2010 9:37 am
Location: England

Re: [RFC] AJAX

Postby naderman » Tue Aug 23, 2011 4:30 pm

Since we're trying to move away from subsilver2, I'd rather not add new features like AJAX to it.
www.naderman.de
Move your forum to Forumatic - we'll take care of maintenance & spam
User avatar
naderman
Development Team Leader
Development Team Leader
 
Posts: 1650
Joined: Sun Jan 11, 2004 2:11 am
Location: Karlsruhe, Germany

Re: [RFC] AJAX

Postby callumacrae » Wed Aug 24, 2011 3:09 pm

How about suggesting / autocompleting usernames in places like user administration in the ACP?
"In JavaScript, there is a beautiful, elegant, highly expressive language that is buried under a steaming pile of good intentions and blunders"
—Douglas Crockford

View my MOD, phpBB Mobile
User avatar
callumacrae
Website Team
Website Team
 
Posts: 883
Joined: Tue Apr 27, 2010 9:37 am
Location: England

Re: [RFC] AJAX

Postby naderman » Fri Aug 26, 2011 7:21 pm

That would most useful I think.
www.naderman.de
Move your forum to Forumatic - we'll take care of maintenance & spam
User avatar
naderman
Development Team Leader
Development Team Leader
 
Posts: 1650
Joined: Sun Jan 11, 2004 2:11 am
Location: Karlsruhe, Germany

Re: [RFC] AJAX

Postby Oleg » Tue Aug 30, 2011 5:05 am

Moved to 3.1.
Oleg
 
Posts: 1150
Joined: Tue Feb 23, 2010 2:38 am

Re: [RFC] AJAX

Postby Arty » Tue Aug 30, 2011 7:59 am

I have a small request: whenever you are inserting/replacing data with ajax, please run that data through a function before inserting/replacing. Something like this:
Code: Select all
$.ajax({
  stuff here
  success: function(data, textStatus, jqXHR)
  {
     ... do some stuff to generate "html" variable ...
     if(typeof(phpBBParse) == 'function') html = phpBBParse('post', html);
     $('#last-post-id').after(html);
  }
});


First parameter is a keyword to help identify where code will be used (like 'post' if html code is content of a post, 'confirm' if its confirmation message, 'error' if error message, etc), second parameter is html code.

What is it for? I'm using multiple backgrounds css3 feature in my styles, but IE7/8 don't support it, so I alter html structure in javascript when document structure is loaded adding more nested divs to all blocks to show multiple backgrounds. I'll need to alter structure of any code inserted via javascript too.
Formerly known as CyberAlien.
User avatar
Arty
Styles Team
Styles Team
 
Posts: 802
Joined: Wed Mar 06, 2002 2:36 pm
Location: Mars

Re: [RFC] AJAX

Postby callumacrae » Tue Aug 30, 2011 10:34 am

Everything will be in the style directory and entirely optional, so style authors can change stuff like that anyway. I can't see the need for this in producer, except for the fact that a lot of people base their styles off prosilver.

Oleg wrote:Moved to 3.1.

Thanks.
"In JavaScript, there is a beautiful, elegant, highly expressive language that is buried under a steaming pile of good intentions and blunders"
—Douglas Crockford

View my MOD, phpBB Mobile
User avatar
callumacrae
Website Team
Website Team
 
Posts: 883
Joined: Tue Apr 27, 2010 9:37 am
Location: England

Re: [RFC] AJAX

Postby Erik Frèrejean » Tue Sep 20, 2011 1:55 pm

naderman wrote:Since we're trying to move away from subsilver2, I'd rather not add new features like AJAX to it.

IMHO this is the wrong approach. Subsilver 2 is kept for the 3.1.x branch and is officially developed/supported, but not all new 3.1.x features are added to an officially developed/supported style? Even though I hate the fact that ss2 is kept for 3.1.x I do believe that it should be developed in the same fashion as prosilver and thus receive all new 3.1.x features.
Not adding certain features to it is like saying "yes we will keep developing ss2 due to popular request but we won't be adding new features to that style because it is dropped somewhere in the future".
Available on .com
Support Toolkit developer
User avatar
Erik Frèrejean
Registered User
 
Posts: 207
Joined: Thu Oct 25, 2007 2:25 pm
Location: surfnet

Re: [RFC] AJAX

Postby naderman » Tue Sep 20, 2011 2:52 pm

The only reason we still support it, is because so many people use it or rather styles based on it. These would have to add AJAX themselves anyway. We will not ship subsilver2 with 3.1, it will merely be made sure that the upgrade works properly when you use subsilver2. So I think this makes perfect sense.
www.naderman.de
Move your forum to Forumatic - we'll take care of maintenance & spam
User avatar
naderman
Development Team Leader
Development Team Leader
 
Posts: 1650
Joined: Sun Jan 11, 2004 2:11 am
Location: Karlsruhe, Germany

Re: [RFC] AJAX

Postby callumacrae » Sat Sep 24, 2011 9:27 pm

Nearly done with the pull request. Only things holding me back is language (although I think I can work around that with data attributes), and I need a close icon for the alert box.
"In JavaScript, there is a beautiful, elegant, highly expressive language that is buried under a steaming pile of good intentions and blunders"
—Douglas Crockford

View my MOD, phpBB Mobile
User avatar
callumacrae
Website Team
Website Team
 
Posts: 883
Joined: Tue Apr 27, 2010 9:37 am
Location: England

Previous Next

Return to [3.1/Ascraeus] Merged RFCs

Who is online

Users browsing this forum: No registered users and 8 guests