Previous Thread
Next Thread
Print Thread
Rate Thread
Page 1 of 2 1 2
Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
Mod Name / Version: IIP SidebarPal 2.2

Description: This allows a user selected sidebar (left/right/off) of IIP pal boxes.
It's fully configurable, you you can decide what boxes you want to display, and in
what order they display.
Version 1.1 fixes an error on some servers which displays a headers already sent error.
Version 2.0 updates for UBB.Threads 6.4
Version 2.1 adds multi-language file support introduced in IIP 5.4.1
Version 2.2 is updated to work with IIP 5.4.4


Working Under: UBB.Threads 6.4

Mod Status: Beta

Any pre-requisites: IIP 5.4.4 & UBB.Threads 6.4

Author(s): JoshPet, JustDave

Date: 10/29/03

Credits: JustDave for IIP and the SidebarPal Scripts

Files Altered: admin/edittheme.php, admin/doedittheme.php, admin/editconfig.php, admin/doeditconfig.php, editdisplay.php, changedisplay.php, ubbt.inc.php, templates/editdisplay.tmpl


New Files: sidebar_leftopen.tmpl, sidebar_leftclose.tmpl, sidebar_rightopen.tmpl, sidebar_rightclose.tmpl, sidebarpal.php

Database Altered: Yes, U_SideBar added to the w3t_Users table to store the user's sidebar preference

Info/Instructions:

Disclaimer: Please backup every file that you intend to modify.
If the modification modifies the database, it's a good idea to backup your database before doing so.

Note: If you modify your UBB.Threads code, you may be giving up your right for "official" support from Infopop.If you need official support, you'll need to restore unmodified files.


Attachments
98108-IIP SidebarPal 2.2.zip (0 Bytes, 214 downloads)

Last edited by JoshPet; 01/04/2004 5:25 AM.
Sponsored Links
Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
Updated this to 2.1 - adding multi-language file support which was introduced in IIP 5.4.1.

Upload the new sidebarpal.php script and add the language cookie into the global call of the send_footer function.

Joined: Mar 2003
Posts: 118
Journeyman
Journeyman
Offline
Joined: Mar 2003
Posts: 118
Cool...works great... Thanks a bunch Josh.

Joined: Oct 2003
Posts: 2
Lurker
Lurker
Offline
Joined: Oct 2003
Posts: 2
I getting an error

Warning: in_array(): Wrong datatype for second argument in e:\www\jorumgand\ubbthreads\pals\custombox1pal.php on line 179

when i put the calendar in the sidebar.

does this ring a bell to anyone?

Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
Sorry for the delay.

I was just able to add the calendar to the sidebar here - no problem, no errors. So I'm not sure. It works on both the left or the right.

Sponsored Links
Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
Wait - I have an idea

Open your calendar pal box script


Find this:

$user = $userob -> authenticate("U_Groups");

ABOVE it, ADD this:

$config['reauth'] = '1';


Tell me if that helps.

Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
OK - it seems the calendar pal box does not like to display events taht are added as part of a post. It throws that error.

It works fine with events added directly to the calendar, but not with calendar events from posts.

Also, if you put the calendar box in the sidebar, it will throw an error on the calendar page - so you need to disable the sidebar on the calendar.

Joined: Oct 2003
Posts: 2,305
Old Hand
Old Hand
Joined: Oct 2003
Posts: 2,305
Hmm Im not using the sidebar but it works fine with no errors when added to the IIP front entrance. I have added events using the post and no issues.. I may load IIP sidebar to my server and see what it could be but this is strange..

Joined: Jul 2001
Posts: 808
Coder
Coder
Joined: Jul 2001
Posts: 808
The Sidebar works well under 6.4 and Internet Explorer 6.x
But do you ever try to view with Opera V6.5 ? It seems that he ignores the table width of 20% completly and destroy the whole layout. Any idea (witout changing the browser to 7.x ) ?

Joined: Sep 2003
Posts: 488
Code Monkey
Code Monkey
Joined: Sep 2003
Posts: 488
Hmm, try this:

In sidebar_leftopen.tmpl...

CHANGE:
======

<table width="{$theme['tablewidth']}" cellpadding="0" cellspacing="0" border="0" align="center">

TO:
===

<table width="{$theme['tablewidth']}" style="table-layout:fixed" cellpadding="0" cellspacing="0" border="0" align="center">


In sidebar_rightopen.tmpl...

CHANGE:
======

<table width="{$theme['tablewidth']}" cellpadding="0" cellspacing="0" border="0" align="center">

TO:
===

<table width="{$theme['tablewidth']}" style="table-layout:fixed" cellpadding="0" cellspacing="0" border="0" align="center">

NOTE: I haven't tested this, don't have Opera installed, and don't have this mod installed, so this may or may not work

Sponsored Links
Joined: Apr 2001
Posts: 3,266
Member
Member
Offline
Joined: Apr 2001
Posts: 3,266
I would switch browsers if it has such a serious design flaw as to not read tables correctly

Joined: Jul 2001
Posts: 808
Coder
Coder
Joined: Jul 2001
Posts: 808
Twisty, thank you. I try it, but it dont work
Omegatron, I know, I know. Opera make my hair grey But the eMail client it is much better then in the V7.x

I try also for every user. You know eMails with complains from user with exotic browser ? So I check out everything. But if any write me, that he use Netscape 4.x I will kick his account *eg*

Joined: Apr 2001
Posts: 3,266
Member
Member
Offline
Joined: Apr 2001
Posts: 3,266
I can tell you from similar instances on IE on some clients that you may want to try a fixed pixel width instead of a global percentage. So instead of 20% try something like 110 or 136.

Joined: Jul 2001
Posts: 808
Coder
Coder
Joined: Jul 2001
Posts: 808
Ah, thats look good. Work in both browser. Thanks again.

Joined: Apr 2001
Posts: 3,266
Member
Member
Offline
Joined: Apr 2001
Posts: 3,266
No biggy. Some browser versions for whatever reason have problems with translating percentages

Joined: Oct 2003
Posts: 2,305
Old Hand
Old Hand
Joined: Oct 2003
Posts: 2,305
[]Omegatron said:
No biggy. Some browser versions for whatever reason have problems with translating percentages [/]

so do most humans

Joined: Sep 2000
Posts: 49
Power User
Power User
Offline
Joined: Sep 2000
Posts: 49
It's probably all my fault since nobody else seems to be having any problems with this, but when a user chooses to display the sidebar on the RIGHT it throws errors. On the LEFT it works OK.

Here's the error message that appears on the right above what would otherwise be the sidebar (some of which does show up):

Warning: main(/home/xxxxx/public_html/ubbthreads/pals/languages//languagepal.php): failed to open stream: No such file or directory in /home/xxxxxx/public_html/ubbthreads/pals/sidebarpal.php on line 43

Warning: main(): Failed opening '/home/xxxxx/public_html/ubbthreads/pals/languages//languagepal.php' for inclusion (include_path='.:/usr/local/lib/php') in /home/xxxxx/public_html/ubbthreads/pals/sidebarpal.php on line 43

Joined: Oct 2003
Posts: 2,305
Old Hand
Old Hand
Joined: Oct 2003
Posts: 2,305
looks like you have a leading / or trailing / where its not suppose to be I would recheck your work..

[]/languages//languagepal.php[/]

Joined: Sep 2000
Posts: 49
Power User
Power User
Offline
Joined: Sep 2000
Posts: 49
I think it seems to be missing the language folder (i.e., "english") in between the two // marks, rather than me having an extra slash mark.

I did also try installing this a second time on my clean "test" install, and got the same problem.

Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
Are you sure you added the extra global variables to the send_footer function? The name of the language would come from the cookies, which don't normally work in the footer.

I'd double check your instructions for ubbt.inc.php - particularly the steps in the send_footer function. Make sure you're adding these:

$dbh,${$config['cookieprefix']."w3t_language"},

to the global call in send_footer.

Joined: Sep 2000
Posts: 49
Power User
Power User
Offline
Joined: Sep 2000
Posts: 49
Hi Josh -- I double-checked that and I had it right.

global $dbh,${$config['cookieprefix']."w3t_language"}, $config, $theme, $thispath, $VERSION, $ubbt_lang, $tempstyle, $timea,$querycount,$zlib,$fheader,$Board,$mysqltime,$debug,$debugprint;

Joined: Feb 2002
Posts: 2,286
Veteran
Veteran
Joined: Feb 2002
Posts: 2,286
Suggestion.

If you want all new users to automatically display the sidebar on the left or right

open adduser.php

find

Code
// ----------------------------------<br />// Insert this user into the database<br />   $query = "<br />         INSERT INTO {$config['tbprefix']}Users (U_LoginName,U_Username,U_Password,U_Email,U_Totalposts,U_Laston,U_Status,U_Sort,U_Display,U_View,U_PostsPer,U_EReplies,U_Registered,U_RegEmail,U_RegIP,U_Groups,U_Title,U_Color,U_Privates,U_Approved,U_PicturePosts,U_CoppaUser,U_Birthday,U_AdminEmails)<br />         VALUES ('$Login_q','$Displayn_q','$crypt','$Email_q','0','$date','$Status_q','{$theme['sort']}','$Display_q','$View_q','{$theme['postsperpage']}','$EReplies_q','$date','$Email_q','$ip_q','$Groups_q','$Title_q','$Color_q','1','$approved','$PicturePosts','$coppauser','$birthday','')<br />   ";  


change to

Code
// ----------------------------------<br />// Insert this user into the database<br />   $query = "<br />         INSERT INTO {$config['tbprefix']}Users (U_LoginName,U_Username,U_Password,U_Email,U_Totalposts,U_Laston,U_Status,U_Sort,U_Display,U_View,U_PostsPer,U_EReplies,U_Registered,U_RegEmail,U_RegIP,U_Groups,U_Title,U_Color,U_Privates,U_Approved,U_PicturePosts,U_CoppaUser,U_Birthday,U_AdminEmails,U_SideBar)<br />         VALUES ('$Login_q','$Displayn_q','$crypt','$Email_q','0','$date','$Status_q','{$theme['sort']}','$Display_q','$View_q','{$theme['postsperpage']}','$EReplies_q','$date','$Email_q','$ip_q','$Groups_q','$Title_q','$Color_q','1','$approved','$PicturePosts','$coppauser','$birthday','','1')<br />   ";  


Where the final digit 1 in the new code is left hand side - this can be changed to 2 for the right hand side.

If you don't do this, by default new users will be off until they update their settings under 'my home'.


Fans Focus - Focusing on Fans of Sport

(Okay - mainly football (the British variety wink at the moment - but expanding all the time....)
Joined: Jun 2002
Posts: 670
Code Monkey
Code Monkey
Offline
Joined: Jun 2002
Posts: 670
Thanks Ian. I had noticed new users don't have it set on. I had recently used an SQL command tu turn it on for everyone, but this will help. BTW, saving SQL commands is very useful for this sort of stuff, which I like about 6.4

Joined: Jul 2001
Posts: 808
Coder
Coder
Joined: Jul 2001
Posts: 808
I found a litte display problem in thread mode. I have a monster thread ( http://www.dragonclan-forum.de/ubbthread...amp;sb=5&o= ). Without Sidebar I have a horizontal scrollbar, if Sidebar right enabled the scrollbar is gone and you cannot navigate anymore. This will bring me to another suggstion, but I put tihs in the propper forum.

Happy new year ! Lots of fun, health, peace and money.

Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
Updated this to version 2.2 which works with IIP 5.4.4.

If you are upgrading.... make sure you update IIP to 5.4.4 first. Then simply reupload the sidebarpal script to your /pals directory.

Joined: Jan 2002
Posts: 674
Junior Member
Junior Member
Offline
Joined: Jan 2002
Posts: 674
I am having trouble shutting off the sidebar in the raidersoft chat hack. the sidebar seems to be pulled with the iframe header. Tried both settings but made no difference

Joined: Apr 2001
Posts: 3,266
Member
Member
Offline
Joined: Apr 2001
Posts: 3,266
Usually to shut off the side bar you add this line directly below the call to main-inc.php

$config['iip_call'] = 1;

Joined: Jan 2002
Posts: 674
Junior Member
Junior Member
Offline
Joined: Jan 2002
Posts: 674
/ -------- end of variables


// Require the library
require ("main.inc.php");
$config['iip_call'] = 1;

$html = new html;

is what I have and they still are there. Hard to see but if you click on top of chat room and drag they can still be seen as part of the iframe header.

Joined: Jan 2003
Posts: 24
Junior Member
Junior Member
Offline
Joined: Jan 2003
Posts: 24
Just wondering if 2.2 will work fine with IIP 5.4.5?

Joined: Jan 2003
Posts: 24
Junior Member
Junior Member
Offline
Joined: Jan 2003
Posts: 24
Starting to think it doesnt work with IIP 5.4.5 or I'm doing something seriously wrong.....

When I call my index page up after making mods...

Code
Parse error: parse error, expecting `T_OLD_FUNCTION' or `T_FUNCTION' or `T_VAR' or `'}'' in /home/teamblit/public_html/ubbthreads/ubbt.inc.php on line 1967<br /><br />Fatal error: Call to undefined function: getmicrotime() in /home/teamblit/public_html/ubbthreads/main.inc.php on line 16  


Help?

Joined: Oct 2003
Posts: 2,305
Old Hand
Old Hand
Joined: Oct 2003
Posts: 2,305
I am using 2.2 with 5.4.5 so it does work. getmicrotime() is established in ubbt.inc.php for some reason your not including the main.inc.php. I would recheck the instructions and try again.

Joined: Jan 2003
Posts: 24
Junior Member
Junior Member
Offline
Joined: Jan 2003
Posts: 24
Ok, re-did the mods and this time got a little further. However, when I ope Display Preferences through My Home I get this error...

We could not find your profile 'Doogz'

Please use your back button to return to the previous page.

I checked the error log and I'm getting this back...

Code
Unable to do_query: ELECT U_Sort,U_Display,U_View,U_PostsPer,U_TextCols,U_TextRows,U_StyleSheet,U_Preview,U_PictureView,U_PicturePosts,U_Language,U_FlatPosts,U_TimeOffset,U_FrontPage,U_ActiveThread,U_StartPage,U_ShowSigs,U_TimeFormat,U_SideBar FROM w3t_Users WHERE U_Username = 'Doogz' - You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near 'ELECT U_Sort,U_Display,U_View,U_PostsPer,U_TextCols,U_TextRows,   


Theres also a few extra fields appeared in config/variables.

This really isnt going well for me

Someone be a life saver!

Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
[]
Unable to do_query: ELECT U_Sort,[/]

You've boogere the instructions.

That should be SELECT
not ELECT

Copy and paste, search and replace all the text VERY carefully. There's no room for errors in PHP code.

So make sure you're a master at copy and paste, search and replace before adding any mods. A missing letter, comma etc... will make a huge difference.

Joined: Jan 2003
Posts: 24
Junior Member
Junior Member
Offline
Joined: Jan 2003
Posts: 24
Oh my!

Thats all I have to say

Thanks JoshPet! you've made my night infront of my computer much shorter!

And to think I must have missed it not once, but twice! I deserve a slap round the head!

Joined: Oct 2003
Posts: 2,305
Old Hand
Old Hand
Joined: Oct 2003
Posts: 2,305
Yup cut and past is your frind. Also beyond Compare will make your life easier also.

Joined: Aug 2003
Posts: 15
Newbie
Newbie
Offline
Joined: Aug 2003
Posts: 15
My only problem is for some reason I can not find a place to turn it on or off after I installed it.

Joined: Jul 2002
Posts: 15
Newbie
Newbie
Offline
Joined: Jul 2002
Posts: 15
I think it would be great to join the pals of the SideBar like that in the next releases

[]http://homepage.mac.com/bferran/.Pictures/sidebar.jpg[/]

Joined: Oct 2003
Posts: 2,305
Old Hand
Old Hand
Joined: Oct 2003
Posts: 2,305
[]My only problem is for some reason I can not find a place to turn it on or off after I installed it. [/]

Admiral to turn it on you must go into your Admin Panel and Under Themes you see the option for the sidebar left, right, off. Also to get it for all users you may have to either have them set the sidebar as they want or in the SQL Area do a UPDATE w3t_Users SET U_Sidebar = "left" WHERE U_Sidebar = ''

to change the box's that show you must change that in the script itself.

Joined: Aug 2002
Posts: 22
Newbie
Newbie
Offline
Joined: Aug 2002
Posts: 22
I've installed the SidebarPal mod and it seems to be having a problem on some code I have in my custombox1pal.php. The code works fine when accessed from the Entrance page but won't work when accessed from a SidebarPal (left or right). It seems to be choking on this line:

Code
$fp = fsockopen("localhost", $port, $errno, $errstr, 2);

I get the following error when it's run from the Sidebar:

No such file or directory (2)

Anyone have any ideas why it runs fine from the IIP entrance page but not from a Sidebar?

Thanks,
Bill

Joined: Sep 2002
Posts: 151
Member
Member
Offline
Joined: Sep 2002
Posts: 151
Post deleted by Gregori

Page 1 of 2 1 2

Link Copied to Clipboard
Donate Today!
Donate via PayPal

Donate to UBBDev today to help aid in Operational, Server and Script Maintenance, and Development costs.

Please also see our parent organization VNC Web Services if you're in the need of a new UBB.threads Install or Upgrade, Site/Server Migrations, or Security and Coding Services.
Recommended Hosts
We have personally worked with and recommend the following Web Hosts:
Stable Host
bluehost
InterServer
Visit us on Facebook
Member Spotlight
isaac
isaac
California
Posts: 1,157
Joined: July 2001
Forum Statistics
Forums63
Topics37,573
Posts293,925
Members13,849
Most Online5,166
Sep 15th, 2019
Today's Statistics
Currently Online
Topics Created
Posts Made
Users Online
Birthdays
Top Posters
AllenAyres 21,079
JoshPet 10,369
LK 7,394
Lord Dexter 6,708
Gizmo 5,833
Greg Hard 4,625
Top Posters(30 Days)
Top Likes Received
isaac 82
Gizmo 20
Brett 7
WebGuy 2
Morgan 2
Top Likes Received (30 Days)
None yet
The UBB.Developers Network (UBB.Dev/Threads.Dev) is ©2000-2024 VNC Web Services

 
Powered by UBB.threads™ PHP Forum Software 8.0.0
(Preview build 20221218)