default expand
 
 
Post new topic   Reply to topic   printer-friendly view    phpMiX.org Forum Index -> phpBB MODs -> Select Expand BBCodes
View previous topic :: View next topic  
Author Message
bdemircan
Starter
Starter


Joined: 11 May 2006
Posts: 3

PostPosted: Thu May 11, 2006 12:21 pm    Post subject: default expand Reply with quote

Hi,
I use phpbbplus 1.53. How can I make all quotes or codes default
expanded without to force user to click "Expand"?
Regards,
Burak
 
Back to top
View user's profile Send private message
markus
[Administrator]
[Administrator]


Joined: 28 Jul 2003
Posts: 1124

PostPosted: Thu May 11, 2006 5:12 pm    Post subject: Reply with quote

Hi,

Here's one possible solution, I think.

OPEN: templates/select_expand_bbcodes.js

FIND:
Code:
   SXBB_evalSize('onload');


REPLACE WITH:
Code:
   for( var id in SXBB ) SXBB[id].resize(SXBB[id].T['expand']);

Works?

 
 
_________________
http://www.phpmix.org
 
Back to top
View user's profile Send private message
bdemircan
Starter
Starter


Joined: 11 May 2006
Posts: 3

PostPosted: Thu May 11, 2006 7:19 pm    Post subject: Reply with quote

I dont know whether it works or not but I found the solution in another
post from youç Here is the post: solution
I applied exactly what you have written for 2 files: viewtopic_body.tpl and viewtopic.php. But for the select_expand_bbcodes.js I did the
following. It always returns false for everybody and it also works.

OPEN: select_expand_bbcodes.js

FIND:

Code:

function SXBB_IsOverflowAble()
{


AFTER, ADD:

Code:

return false;
 
Back to top
View user's profile Send private message
markus
[Administrator]
[Administrator]


Joined: 28 Jul 2003
Posts: 1124

PostPosted: Thu May 11, 2006 7:35 pm    Post subject: Reply with quote

This is going to completely disable expand/contract capabilities, however. The changes I posted above would show the boxes expanded by default when the page is loaded (this is what you asked for, I believe), but users will still be able to contract/expand them at will.
 
 
_________________
http://www.phpmix.org
 
Back to top
View user's profile Send private message
bdemircan
Starter
Starter


Joined: 11 May 2006
Posts: 3

PostPosted: Fri May 12, 2006 6:27 am    Post subject: Reply with quote

You are right Markus. I really wanted to disable it for everybody.
By the way to disable it like I did, do I need to change other 2 files
really?
Regards,
Burak
 
Back to top
View user's profile Send private message
markus
[Administrator]
[Administrator]


Joined: 28 Jul 2003
Posts: 1124

PostPosted: Fri May 12, 2006 10:12 am    Post subject: Reply with quote

If you prefer the other method (let your users choose), then yes, I'afraid. Also, you would have to add a new field in their profiles, so they can choose. This is something Smudge didn't post here. There's a guide somewhere in the phpBB MOD Writers forum.
 
 
_________________
http://www.phpmix.org
 
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    phpMiX.org Forum Index -> phpBB MODs -> Select Expand BBCodes All times are GMT + 1 Hour
 
Page 1 of 1


 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum