Previous Thread
Next Thread
Print Thread
Rating: 5
Page 1 of 4 1 2 3 4
#229473 12/18/2002 4:44 PM
Joined: Apr 2002
Posts: 1,768
Addict
Addict
Offline
Joined: Apr 2002
Posts: 1,768
[:"red"]WARNING: THERE ARE SOME ERRORS IN THE DOCUMENTATION FOR THIS HACK. YOU MAY WANT TO DELAY USING THIS HACK UNTIL THE ERRORS HAVE BEEN CORRECTED.[/]

Code
NAME:             Calendar <br />VERSION:          Dave_L.0.1 (temporary until someone decides what number this should be) <br />DESCRIPTION:      Enables one or more forums to be used as event calendars. <br />WORKING UNDER:    UBB.threads 6.2br2 <br />PREREQUISITES:    none <br />AUTHORS:          Gamejag, Max Fisch, Allen Ayers, Dave_L <br />CREDITS:          JustDave, Lunatik and others <br />DEMO:             none <br />FILES ALTERED:    postlist.php, showthreaded.php (optional changes) <br />DATABASE ALTERED: yes <br />NEW FILES:        addevent.php, newevent.php, postlist_event.php, <br />                  templates/default/addevent_preview.tmpl, templates/default/newevent.tmpl, <br />                  images/red_arrow.gif, images/red_arrow_1.gif <br /> <br />HISTORY: <br />  2002-12-18  Dave_L  Dave_L.0.0 <br />    Updated for UBB.threads 6.2 <br />    Use user's time zone offset and date/time format display preferences. <br />    Moved most of the postlist.php changes to a separate file postlist_event.php. <br />    Moved events table query in postlist_event.php out of loop for efficiency. <br />  2002-12-18  Dave_L  Dave_L.0.1 <br />    Corrected description above.


-----------------------------

Notes:

1) This was based on the version of the Calendar hack in this post: https://www.ubbdev.com/threads/php/showthreaded.php?Cat=&Board=beta&Number=53193

2) I didn't know what version this should be. Until someone else decides this, I temporarily numbered it "Dave_L.0.0".

3) As an experiment, I provided most of the change-instructions using BeyondCompare file-difference-report files.

-----------------------------

Updated to version Dave_L.0.1 - the only change was correcting the description above. I had copied the header info from another hack, and forgot to change it.
Attachments
62190-calendar-Dave_L-0-1.zip (0 Bytes, 160 downloads)

Last edited by Dave_L; 01/15/2003 1:34 PM.
Sponsored Links
joeuser #229474 12/18/2002 9:21 PM
Joined: Feb 2002
Posts: 950
Hacker
Hacker
Offline
Joined: Feb 2002
Posts: 950
Dave, do you have a site where I can see this?

gailg #229475 12/18/2002 10:42 PM
Joined: Apr 2002
Posts: 1,768
Addict
Addict
Offline
Joined: Apr 2002
Posts: 1,768
I don't have the hack installed on a public site. You might check the older calendar thread(s) to see if someone has a demo site. The 6.2 hack is basically the same as version 3.0.

joeuser #229476 12/20/2002 4:11 PM
Joined: Apr 2001
Posts: 3,266
Member
Member
Offline
Joined: Apr 2001
Posts: 3,266
Michael,

If you would like to see the calendar visit my site

http://www.reeftalk.com

Joined: Jun 2002
Posts: 27
User
User
Offline
Joined: Jun 2002
Posts: 27
Woot. My name in the list glad to be of help. Once 6.2 Beta 3 comes out ill test it out myself.

Sponsored Links
sari #229478 12/26/2002 7:36 PM
Joined: Apr 2001
Posts: 3,266
Member
Member
Offline
Joined: Apr 2001
Posts: 3,266
Dave,

You think you can tell me how to read a beyond compare difference report? I see nowhere in beyond compare to load it? I am missing something here. I can not read this to be able to install it.

Joined: Apr 2002
Posts: 1,768
Addict
Addict
Offline
Joined: Apr 2002
Posts: 1,768
They're just HTML files, so your browser should display them.

joeuser #229480 12/26/2002 8:13 PM
Joined: Apr 2001
Posts: 3,266
Member
Member
Offline
Joined: Apr 2001
Posts: 3,266
LOL I know I figured that out after beating myself over the head for asking such a stupid question. Just had me all turned around with the beyond compare thing. I was looking for some special thing until I woke up and brought them up in the browser.

joeuser #229481 12/31/2002 7:28 AM
Joined: Oct 2002
Posts: 165
Member
Member
Offline
Joined: Oct 2002
Posts: 165
I was wondering...
- Does this use any kind of cache. I read in the previous version that large boards may have problems with it. I have a reasonably large baord, so I'm concerned.

- Is there a Pal box for v. 6.2?

Thanks

Joined: Apr 2002
Posts: 1,768
Addict
Addict
Offline
Joined: Apr 2002
Posts: 1,768
This hack doesn't use any sort of cache.

For the postlist, the number of queries was reduced by fetching all the events for a month with one query. The old version did a separate query for each day of the month.

JustDave would have to answer the IIP question.

Sponsored Links
joeuser #229483 01/01/2003 5:04 PM
Joined: Oct 2002
Posts: 165
Member
Member
Offline
Joined: Oct 2002
Posts: 165
Was there a way to populate the calendar with the Birthdates automatically? I thought I saw that somewhere, but I can't find it. Maybe it was never done?


Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
I think Nikos put it together.

I never got a chance to use it (yet). We need to find it and I should add it to the instructions.

I haven't installed the calendar on any boards yet under 6.2, but I have a client that I probably will need to, so I'll be figuring it out eventually.

joeuser #229485 01/03/2003 6:45 PM
Joined: May 1999
Posts: 1,715
Addict
Addict
Joined: May 1999
Posts: 1,715
From what I could see this should be the latest and the greatest version of this mod, so I closed the other thread that was open. Please correct me if I'm wrong, I don't use the mod myself so I haven't really followed the development of it.

c0bra #229486 01/03/2003 8:19 PM
Joined: Apr 2002
Posts: 1,768
Addict
Addict
Offline
Joined: Apr 2002
Posts: 1,768
I based the version I posted here on the latest version I could find in the other thread, so closing the other thread probably makes sense, now that 6.2 is released.

I hereby turn over maintenance of this hack to ... everyone.

The first task is to decide on a better version number.

joeuser #229487 01/03/2003 10:37 PM
Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
We ought to name our hacks with the threads version number, but add letters.

Calendar 6.2.a
Calendar 6.2.b

It would be easier to know what version it was written for.

Daine #229488 01/04/2003 12:14 AM
Joined: Mar 2001
Posts: 644
Member
Member
Offline
Joined: Mar 2001
Posts: 644
Added this to my test board tonight to check it out. Looks like there are a number of documentation changes that need to be made.

I was able to muddle through but a number of items didn't match up and I had to do some heavy searching to find the appropriate places to edit.

Seems to be working though. Nice mod!


[EDIT: Should have mentioned I'm using 6.2 release ]

Last edited by Zackary; 01/04/2003 12:16 AM.
#229489 01/04/2003 7:14 AM
Joined: Jan 2001
Posts: 374
Enthusiast
Enthusiast
Offline
Joined: Jan 2001
Posts: 374
I think this hack developed to be one of the "must-have"s for everyone.
What a pity that this calender does not support language files yet.
And for international versions it is essential to be able to
- exchange AM/PM against a 24hrs display
- switch to a display where Monday is 1st day of the week intstead of sunday.

Of course we could try to develope a German version from it (and discuss it on the German board), embedding the neccessary changes. The problem would be only that then two separate calendar hacks would be to maintain instead of only one, a situation that imho. should be avoided....

Also I want to draw your attention again to a wonderful hack that combines Josh's phantastic BIRTHDAY hack with this cool one: it is displaying all found birthdays automatically in the calendar. This hack is burried deep inside this thread:
https://ubbdev.com/threads/php/...page=&view=&sb=5&o=&vc=1
Although I don't get it working with the new calendar hack, I think it is well worth not to be forgotten

rodrigo1 #229490 01/07/2003 2:01 PM
Joined: Apr 2002
Posts: 56
Power User
Power User
Joined: Apr 2002
Posts: 56
worked a treat!

Even I managed this one!!!!!!!!

demo on www.audi-sport.net

algorewon #229491 01/07/2003 2:05 PM
Joined: Nov 2000
Posts: 210
Member
Member
Offline
Joined: Nov 2000
Posts: 210
Yes Great Hack Thanks Dave

joeuser #229492 01/07/2003 3:42 PM
Joined: Sep 2001
Posts: 129
Member
Member
Offline
Joined: Sep 2001
Posts: 129
Am I missing somthing i have had the hack installed for ages, but just went to upgrade to this version and the installation was fine but the addpost.php instructions seem all wrong, is this hack ok for 6.2 RC ?

I cant find this bit for instance:
// -------------------------------------------------------------
// If HTML is off then we need to get rid of < and > in the body
if ( ($convert != "html") && ($convert !="both") ) {
$PrintBody = str_replace("<","<",$PrintBody);
$PrintBody = str_replace(">",">",$PrintBody);
}
$html -> send_header($ubbt_lang['PREV_POST'],$Cat,0,$user,$Extra,$ReadPerm);


$FormSubject = $html -> form_encode($FormSubject);
$FormBody = $html -> form_encode($FormBody);
$FormSubject = str_replace("&","&",$FormSubject);
$FormBody = str_replace("&","&",$FormBody);
$formLocation = $html -> form_encode($formLocation);
$formLocation = str_replace("&","&",$formLocation);


Regards
Clint

Running on WIN2003 Web Server.

Paranoid people get followed too!
Joined: Sep 2001
Posts: 129
Member
Member
Offline
Joined: Sep 2001
Posts: 129
I have this which is near
// -------------------------------------------------------------
// If HTML is off then we need to get rid of < and > in the body
if ( ($convert != "html") && ($convert !="both") ) {
$PrintBody = str_replace("<","<",$PrintBody);
$PrintBody = str_replace(">",">",$PrintBody);
}
else {
// No server side includes
$PrintBody = preg_replace("/<!--(.|\n)*-->/","",$PrintBody);
}


Regards
Clint

Running on WIN2003 Web Server.

Paranoid people get followed too!
Joined: Apr 2001
Posts: 3,266
Member
Member
Offline
Joined: Apr 2001
Posts: 3,266
I beleive the part you need to hack in is a formlocation just place it under these

$FormSubject = $html -> form_encode($FormSubject);
$FormBody = $html -> form_encode($FormBody);
$FormSubject = str_replace("&","&",$FormSubject);
$FormBody = str_replace("&","&",$FormBody);
$formLocation = $html -> form_encode($formLocation);
$formLocation = str_replace("&","&",$formLocation);

Joined: Jun 2002
Posts: 27
User
User
Offline
Joined: Jun 2002
Posts: 27
This version has been working fine for me. The only thing I would like to see is an editevent.php file.

sari #229496 01/08/2003 3:09 PM
Joined: Nov 2000
Posts: 210
Member
Member
Offline
Joined: Nov 2000
Posts: 210
yep agreed as a work around you can edit the events safely through phpmyadmin

MercAqua #229497 01/10/2003 9:19 AM
Joined: Jun 2001
Posts: 356
Junior Member
Junior Member
Offline
Joined: Jun 2001
Posts: 356
well, installed it, but it's not working! i dont get no calendar appearing, also no error messages to enable me to de-bug!
ideas??
i probably buggered up on the editing of the files, because they didnt tally up, so i had to give it an educated guess!

joeuser #229498 01/11/2003 10:48 AM
Joined: Apr 2002
Posts: 1,768
Addict
Addict
Offline
Joined: Apr 2002
Posts: 1,768
I've started using this hack on my production board, and have decided it needs several changes. If I have time, I'd like to change it as follows:

1) Get rid of the E_Location column. Many events don't really have a "location", and it would be much easier to just use the thread title instead. This would also simplify the installation of the hack, since many of the changes are only needed to support the location column.

2) Get rid of the E_Time column. This is unnecessary, since the E_Date column contains both the date and time.

3) Get rid of the other unused columns: E_Duration, E_Recurring, E_Recurtype, E_End, E_Frequency, E_Days. They could always be added back in later if support for them were needed.

4) Add a column E_AdjustTime. If 1, the event date/time is adjusted according to the viewer's time zone offset. If 0, the event date/time is not adjusted. The former setting would be appropriate for online events, the latter for "physical" events.

5) Add support for editing the date/time of an event.

6) Add changes to showflat.php for displaying the event date/time.

7) Add dimopoulos's changes that use the Profile Birthdays modification to populate the birthdays automatically.

Any feedback on these changes?

-------
Update:

I've revised the hack to effect all of the above changes except for 4, 5 and 7. (7 is a new item referred to in a post below.) I'm trying to figure out if 4 is feasible, and how much effort 5 will take. I've also updated the hack for UBB.threads 6.2.1, which should be released very soon. I'll try to get all this done, including fixing the documentation, within the next few days.

-------
Update:

Due to time constraints, I'm abandoning work on this hack. With the above changes, it's gotten far too complicated, is incompatible with the current version, and maintaining it will be too much of a headache.

Last edited by Dave_L; 01/28/2003 6:57 PM.
joeuser #229499 01/11/2003 10:55 AM
Joined: Jun 2001
Posts: 3,273
That 70's Guy
That 70's Guy
Offline
Joined: Jun 2001
Posts: 3,273
You have hit on everything I can think of that I don't like about this addon.

Looking forward to seeing your improvements!

Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
Mr. Eagle Eye - Changes sound good.

Daine #229501 01/12/2003 5:49 AM
Joined: Jun 2001
Posts: 356
Junior Member
Junior Member
Offline
Joined: Jun 2001
Posts: 356
the location part is very important to me.
because i run a car website, the calendar (will be, if i ever get it working) to post up dates and locations of meets throughout the country.

Luka_dup1 #229502 01/12/2003 6:04 AM
Joined: Apr 2002
Posts: 1,768
Addict
Addict
Offline
Joined: Apr 2002
Posts: 1,768
But is there any problem with simply stating the location in the thread title?

joeuser #229503 01/12/2003 6:34 AM
Joined: Jun 2001
Posts: 356
Junior Member
Junior Member
Offline
Joined: Jun 2001
Posts: 356
nah, thats true. i could always do that i guess

Daine #229504 01/13/2003 10:08 AM
Joined: Aug 2002
Posts: 1,191
Kahuna
Kahuna
Joined: Aug 2002
Posts: 1,191
Josh and Mike

Below the update for the Calendar 6.2 modification which uses the Profile Birthdays modification to populate the birthdays automatically.

Files altered: postlist_event.php

1. Find
Code
 <br />			if ($resp > 0) <br />			{ <br />				if ($tm == '0') <br />				{ <br />					[:"blue"]$Evnt = "<a href=\"$config[phpurl]/$mode.php? <br />					     Cat=$Cat&amp;Board=$Board&amp;Number=$Number&amp;view=$view <br />					     &amp;sb=$sb&amp;o=$o&amp;mon=$mon&amp;year=$year&amp;cs=$cs\"> <br />					     $Location:<br />$Subject</a>, ($resp responses)";[/] <br />				} <br />				else <br />				{ <br />					$tm = strtotime($html -> convert_time($tm, $user['U_TimeOffset'])); <br />					$h = strtolower(strftime ("%I", $tm)); <br />					$m = strtolower(strftime ("%M", $tm)); <br />					$mer = strtolower(strftime ("%p", $tm)); <br />					[:"blue"]$Evnt = "<a href=\"$config[phpurl]/$mode.php?Cat=$Cat&amp; <br />					     Board=$Board&amp;Number=$Number&amp;view=$view&amp;sb=$sb&amp; <br />					     o=$o&amp;mon=$mon&amp;year=$year&amp;cs=$cs\"> <br />					     $Location, $h:$m $mer:<br /> $Subject</a>, ($resp responses)";[/] <br />				} <br />			} <br />			else <br />			{ <br />				if ($tm == '0') <br />				{ <br />					[:"blue"]$Evnt = "<a href=\"$config[phpurl]/$mode.php?Cat=$Cat&amp;Board=$Board <br />					     &amp;Number=$Number&amp;view=$view&amp;sb=$sb&amp;o=$o&amp;mon=$mon <br />					     &amp;year=$year&amp;cs=$cs\">$Location:<br />$Subject</a>";[/][/] <br />				} <br />

Change it to
Code
 <br />			if ($resp > 0) <br />			{ <br />				if ($tm == '0') <br />				{ <br />					[:"blue"]$Evnt = "<a href=\"$config[phpurl]/$mode.php?Cat=$Cat&amp;Board=$Board <br />					     &amp;Number=$Number&amp;view=$view&amp;sb=$sb&amp;o=$o&amp;mon=$mon <br />					     &amp;year=$year&amp;cs=$cs\">$Location:<br />$Subject</a>, ($resp responses)";[/] <br />				} <br />				else <br />				{ <br />					$tm = strtotime($html -> convert_time($tm, $user['U_TimeOffset'])); <br />					$h = strtolower(strftime ("%I", $tm)); <br />					$m = strtolower(strftime ("%M", $tm)); <br />					$mer = strtolower(strftime ("%p", $tm)); <br />					[:"blue"]$Evnt = "<a href=\"$config[phpurl]/$mode.php?Cat=$Cat&amp;Board=$Board <br />					     &amp;Number=$Number&amp;view=$view&amp;sb=$sb&amp;o=$o&amp;mon=$mon <br />					     &amp;year=$year&amp;cs=$cs\">$Location, $h:$m $mer: <br />					     <br /> $Subject</a>, ($resp responses)";[/] <br />				} <br />			} <br />			else <br />			{ <br />				if ($tm == '0') <br />				{ <br />// 20030113 - Birthday Update New Start <br />					if ( $Location == "Birthday" ) <br />					{ <br />						$Evnt = $Subject; <br />					} <br />					else <br />					{ <br />// 20030113 - Birthday Update New End <br />						[:"blue"]$Evnt = "<a href=\"$config[phpurl]/$mode.php?Cat=$Cat&amp; <br />					             Board=$Board&amp;Number=$Number&amp;view=$view&amp;sb=$sb&amp; <br />					             o=$o&amp;mon=$mon&amp;year=$year&amp;cs=$cs\"> <br />					             $Location:<br />$Subject</a>";[/] <br />// 20030113 - Birthday Update New Start <br />					} <br />// 20030113 - Birthday Update New End <br />				} <br />


2. Find
Code
 <br />			// draw horizontal bar before each event except the first <br />			if ( !$first_event_for_day ) <br />			{ <br />				$events .= "<hr width=95% align=\"center\" />"; <br />			} <br /> <br />			$events .= "<font color=\"red\"><b>&rsaquo;&rsaquo;&rsaquo;</b></font> $Evnt<br />"; <br />

and CHANGE it to
Code
 <br />			// draw horizontal bar before each event except the first <br />// 20030113 - Birthday Update Old Start <br />//			if ( !$first_event_for_day ) <br />// 20030113 - Birthday Update Old End <br />// 20030113 - Birthday Update New Start <br />			if ( (!$first_event_for_day) and ($Location <> "Birthday") ) <br />// 20030113 - Birthday Update New End <br />			{ <br />				$events .= "<hr width=95% align=\"center\" />"; <br />			} <br /> <br />// 20030113 - Birthday Update New Start <br />			if ( $Location == "Birthday" ) <br />			{ <br />				$events .= "<font color=\"blue\"><b>&rsaquo;</b></font> $Evnt<br />"; <br />			} <br />			else <br />			{ <br />// 20030113 - Birthday Update New End <br />				$events .= "<font color=\"red\"><b>&rsaquo;</b></font> $Evnt<br />"; <br />// 20030113 - Birthday Update New Start <br />			} <br />// 20030113 - Birthday Update New End <br />


3. Find (function get_events_for_month($month, $year))

Code
 <br />	[:"blue"]$lowdate  = mktime(0, 0, 0, $month,   1, $year) - <br />                           $user['U_TimeOffset'] * 3600; // first day of this month, time 00:00:00 <br />	$highdate = mktime(0, 0, 0, $month+1, 1, $year) - <br />                           $user['U_TimeOffset'] * 3600; // first day of next month, time 00:00:00 <br />	$birthMonth	=	mktime( 0, 0, 0, $month, 1, $year );[/] <br />	$Board_q = addslashes($Board); <br />

and CHANGE it to
Code
 <br />	[:"blue"]$lowdate  = mktime(0, 0, 0, $month,   1, $year) - <br />                           $user['U_TimeOffset'] * 3600; // first day of this month, time 00:00:00[/] <br />	[:"blue"]$highdate = mktime(0, 0, 0, $month+1, 1, $year) - <br />                           $user['U_TimeOffset'] * 3600; // first day of next month, time 00:00:00[/] <br /> <br />	$events_for_month = array(); <br />// 20030113 - Birthday Update New Start <br />	// Construct the query to check for the birthday modification <br />	$strQuery	=	" <br />    	SHOW	FIELDS <br />		FROM	{$config['tbprefix']}Users <br />	"; <br /> <br />	$result = $dbh -> do_query($strQuery); <br /> <br />	$intFieldsFound	=	0; <br /> <br />	// Cycle through the fields and increase the counter where appropriate <br />	while ( $arrDataLine = $dbh -> fetch_array($result) ) <br />	{ <br />		if ( $arrDataLine[0] == "U_BirthYear" 	) { $intFieldsFound++; 	}; <br />		if ( $arrDataLine[0] == "U_BirthDay"	) {	$intFieldsFound++;	}; <br />		if ( $arrDataLine[0] == "U_BirthMonth"	) { $intFieldsFound++;	}; <br /> <br />		// Exit the loop if all three fields have been found <br />		if ( $intFieldsFound == 3 ) <br />		{ <br />			break; <br />		} <br />	} <br /> <br />	$dbh -> finish_sth($result); <br /> <br />	if ( $intFieldsFound == 3 ) <br />	{ <br />		$query = " <br />			SELECT U_Username, U_Birthday, U_BirthYear, U_Number <br />			FROM   {$config['tbprefix']}Users <br />			WHERE  U_BirthMonth = FROM_UNIXTIME($birthMonth,'%b') <br />			ORDER BY U_Username <br />			"; <br />		$result = $dbh->do_query($query); <br />		while(list($bUsername, $bBirthday, $bBirthYear, $bNumber ) = $dbh->fetch_array($result)) <br />		{ <br /> <br />			if ( $bBirthYear > 0 ) <br />			{ <br />				$bAge	=	$year - $bBirthYear; <br />				$bExtra =	" ($bAge)"; <br />			} <br />			else <br />			{ <br />				$bExtra	=	""; <br />			} <br /> <br />			$arrData['E_ID']		=	0; <br />			$arrData['E_Date']		=	mktime(0, 0, 0, $month, $bBirthday, $year) - $user['U_TimeOffset'] * 3600; // first day of this month, time 00:00:00 <br />			$arrData['E_Time']		=	0; <br />			$arrData['E_Location']	=	"Birthday"; <br />			$arrData['B_Subject']	=	"<a href=\"$config[phpurl]/showprofile.php?Cat=$Cat&amp;User=$bNumber&amp;what=\">$bUsername$bExtra</a><br />"; <br />			$arrData['B_Number']	=	0; <br />			$arrData['B_Replies']	=	0; <br /> <br />			$date = getdate($arrData['E_Date'] + $user['U_TimeOffset'] * 3600); <br />			$mday = $date['mday']; <br /> <br />			if (empty($events_for_month[$mday])) <br />			{ <br />				$events_for_month[$mday] = array(); <br />			} <br />			array_push($events_for_month[$mday], $arrData); <br />		} <br /> <br />		$dbh->finish_sth($result); <br />	} <br />// 20030113 - Birthday Update New End <br /> <br /> <br />	$Board_q = addslashes($Board); <br />


4. Find this:
Code
 <br />// The second parameter MYSQL_ASSOC in the call to sql::to fetch_array() anticipates a <br />// requested change to that method, which will increase efficiency.  Until that change <br />// is made, the parameter has no effect, but there's harm in leaving it there. <br /> <br />	$events_for_month = array(); <br />	while($row = $dbh->fetch_array($result, MYSQL_ASSOC)) { <br />

and CHANGE it to this
Code
 <br />// The second parameter MYSQL_ASSOC in the call to sql::to fetch_array() anticipates a <br />// requested change to that method, which will increase efficiency.  Until that change <br />// is made, the parameter has no effect, but there's harm in leaving it there. <br /> <br />	while($row = $dbh->fetch_array($result, MYSQL_ASSOC)) { <br />


NOTE: The code in [:"blue"]BLUE[/] is in ONE line only and has been split for aesthetic purposes only!

That should do the trick

Warm regards

Nikos

PS: Sorry that it took me so long to get this thing but I have been awfully busy lately

[b]Edit:[b]
Fixed small bug with Age calculation when the Age was not set.
Added code to check for the Profile Birthday modification and display the birthdays automatically on the calendar. If the modification has not been installed the paricular code will not execute
2002-02-03 - Change to show the correct birthdays for users with time offset

Last edited by dimopoulos; 02/03/2003 5:00 AM.

Nikos
alsalmicom #229505 01/13/2003 10:15 AM
Joined: Aug 2002
Posts: 1,191
Kahuna
Kahuna
Joined: Aug 2002
Posts: 1,191
Mike and the rest of the gang

Attached is a custombox6pal.php file which you can use as a birthday pal. If you already use the 6th custom box in your IIP, change its number to something that you don't use.

Warm regards

Nikos
Attachments
64756-custombox6pal.zip (0 Bytes, 42 downloads)


Nikos
Hal_dup2 #229506 01/13/2003 11:07 AM
Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
Thanks!

Daine #229507 01/13/2003 11:29 AM
Joined: Aug 2002
Posts: 1,191
Kahuna
Kahuna
Joined: Aug 2002
Posts: 1,191
You are welcome Mr. Bug

Warm regards

Nikos


Nikos
Hal_dup2 #229508 01/13/2003 12:27 PM
Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
That's my assigned name from Rick.

I kept posting too many bugs, he renamed me.


Daine #229509 01/15/2003 11:03 AM
Joined: Dec 2002
Posts: 173
Member
Member
Offline
Joined: Dec 2002
Posts: 173
Hi

Edit:.........
I've just installed 6.2 Calendar Sorry had an error but fixed it

Thanks

Last edited by Liahona; 01/15/2003 11:09 AM.

Thanks

Liahona
jfrosch #229510 01/15/2003 11:22 AM
Joined: Dec 2002
Posts: 173
Member
Member
Offline
Joined: Dec 2002
Posts: 173
Hi anyone

Well, no sql errors anyway...........but

I can't see any calendar when I click the calendar link on the forum?

It just takes me to the posting page nothing else there.

Have I missed something thats not in the attachment file at no. 1 post?






Thanks

Liahona
jfrosch #229511 01/15/2003 11:26 AM
Joined: Apr 2002
Posts: 1,768
Addict
Addict
Offline
Joined: Apr 2002
Posts: 1,768
I'm not sure what you mean by "calendar link on the forum".

Did you change the Bo_Calendar column for that forum to 'Y'?

joeuser #229512 01/15/2003 11:46 AM
Joined: Dec 2002
Posts: 173
Member
Member
Offline
Joined: Dec 2002
Posts: 173
Hi Dave

Sorry in my haste to get it the calender going I forgot to do step 3.

I have the calender showing now....

So how to I populate do I
alter the postlist_event.php as dimopoulos says?



Thanks

Liahona
jfrosch #229513 01/15/2003 11:52 AM
Joined: Dec 2002
Posts: 173
Member
Member
Offline
Joined: Dec 2002
Posts: 173
Hi Dave

I clicked on the corner of a date square on the calender that says add new event and got

Parse error: parse error in /home/www/hillcrestknitwear/ubbthreads/newevent.php on line 269

Edit : Which is the very end line of the file ?>

Any ideas

Last edited by Liahona; 01/15/2003 11:54 AM.

Thanks

Liahona
jfrosch #229514 01/15/2003 12:03 PM
Joined: Apr 2002
Posts: 1,768
Addict
Addict
Offline
Joined: Apr 2002
Posts: 1,768
That suggests that you didn't install the changes correctly. Without seeing the actual file, I can't be more specific, and we're not allowed to post that stuff here.

jfrosch #229515 01/15/2003 12:07 PM
Joined: Aug 2002
Posts: 1,191
Kahuna
Kahuna
Joined: Aug 2002
Posts: 1,191
Liahona,

Make sure that you have followed the instructions as per the modification. When I was installing it, I used the files provided in the attachment, without realizing that I actually need to copy and paste content from existing files and then change some of it.

The modification that I posted you can leave it out for the time being so that you don't get confused. Later on you can apply the modification along with Josh's Birthday 1.4.

If you wish PM me and I can email you my files so that you can compare them and see where you went wrong.

Warm regards

Nikos


Nikos
joeuser #229516 01/15/2003 12:09 PM
Joined: Dec 2002
Posts: 173
Member
Member
Offline
Joined: Dec 2002
Posts: 173
Hi

Well, I'll check it again, but I think someone needs to redo the instructions as a few of the changes do not match and had to guess. lol


Thanks

Liahona
jfrosch #229517 01/15/2003 12:19 PM
Joined: Apr 2002
Posts: 1,768
Addict
Addict
Offline
Joined: Apr 2002
Posts: 1,768
When I have time, I was going to make the changes I proposed several posts ago, which will include redoing the instructions. If the Location column is removed, that should simplify the instructions too.

Maybe my experiment at using BeyondCompare difference files didn't work very well.

If someone else wants to fix the instructions in the meantime, feel free.

Nikos: I'm not sure how to deal with your changes. Should I try to incorporate those into the main hack, or should I just ignore them? On my board, I don't want to populate the calendar with birthdays, but I guess the main hack's documentation could indicate your changes as an option. This is getting complicated.

joeuser #229518 01/15/2003 12:38 PM
Joined: Aug 2002
Posts: 1,191
Kahuna
Kahuna
Joined: Aug 2002
Posts: 1,191
I agree that we need to put this as an option at the bottom of the instructions. If you want I can put a check in there that will query the fields of the Users table and if the ones for the calendar exist then the code will be executed.

Do you think that this check will increase the overhead on the script, since it will be another query in the database?

Warm regards

Nikos


Nikos
joeuser #229519 01/15/2003 12:38 PM
Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
I had trouble with the instructions. But have installed this on a couple of board so far.

If nobody beats me to it, I'll update the instructions maybe later this week.

Hal_dup2 #229520 01/15/2003 12:45 PM
Joined: Apr 2002
Posts: 1,768
Addict
Addict
Offline
Joined: Apr 2002
Posts: 1,768
[]Do you think that this check will increase the overhead on the script, since it will be another query in the database?[/]

If it's only one query for the entire month, I don't think it would be significant.

joeuser #229521 01/15/2003 1:09 PM
Joined: Dec 2002
Posts: 173
Member
Member
Offline
Joined: Dec 2002
Posts: 173
Hi Dave

Could you check if this is in the correct place
Inserted the red text as it says but the
The instructions says insert the red text ...

==============================================
// ---------------------
// Grab the tablewrapper
list($tbopen,$tbclose) = $html -> table_wrapper();




[:"red"]if($Calendar == 'Y') {
require ('postlist_event.php');
} [/]


include ("$thispath/templates/$tempstyle/postlist.tmpl");

===============================================
I can only find the below so I inserted it there is this correct. This [:"blue"] if (!$debug) [/] {is omitted from the instructions do I keep it in or take it out?

===============================================
// Grab the tablewrapper
list($tbopen,$tbclose) = $html -> table_wrapper();

[:"red"] if($Calendar == 'Y') {
require ('postlist_event.php');
} [/]

[:"blue"] if (!$debug) { [/]
include ("$thispath/templates/$tempstyle/postlist.tmpl");
}

// Send the footer
$html -> send_footer();

?>
=============================================


Thanks

Liahona
jfrosch #229522 01/15/2003 1:23 PM
Joined: Dec 2002
Posts: 173
Member
Member
Offline
Joined: Dec 2002
Posts: 173
Hi Dave

I found the prob with my error.....ell, this one so far.....
In the "newevent.htm" instruction file thee is a closing bracket missing as below in [:"blue"]blue (I inserted) [/]

$d = get_input('d', 'get');
$mon = get_input('mon', 'get');
$year = get_input('year', 'get');
include("$thispath/templates/$tempstyle/newevent.tmpl");
[:"blue"] } (This bracketis missing) [/]
$html -> send_footer();


Thanks

Liahona
jfrosch #229523 01/15/2003 1:26 PM
Joined: Apr 2002
Posts: 1,768
Addict
Addict
Offline
Joined: Apr 2002
Posts: 1,768
That looks correct. The [:"blue"]if (!$debug) {[/] was incorrectly omitted from the instructions.

P.S. Thanks for pointing out these errors. I'll think I'll post a warning in the first post about them.

Last edited by Dave_L; 01/15/2003 1:28 PM.
jfrosch #229524 01/15/2003 1:27 PM
Joined: Dec 2002
Posts: 173
Member
Member
Offline
Joined: Dec 2002
Posts: 173
Hi me again

Filled in the calendar part where you put in the event, date etc ... then posted ....but received this.

Parse error: parse error in /home/www/hillcrestknitwear/ubbthreads/addevent.php on line 347

What next


Thanks

Liahona
jfrosch #229525 01/15/2003 1:44 PM
Joined: Dec 2002
Posts: 173
Member
Member
Offline
Joined: Dec 2002
Posts: 173
Hi

I give up

I took out the if (!$debug) {

and still got this error.

Parse error: parse error in /home/www/hillcrestknitwear/ubbthreads/addevent.php on line 347

I give in --- going to wait till there are better instructions my head all minced up.


Thanks

Liahona
jfrosch #229526 01/15/2003 1:51 PM
Joined: Aug 2002
Posts: 1,191
Kahuna
Kahuna
Joined: Aug 2002
Posts: 1,191
[]Parse error: parse error in /home/www/hillcrestknitwear/ubbthreads/addevent.php on line 347[/]

Strange... The addevent.php has this
Code
<br />   if (isset($user['U_Signature'])) {<br />      $user['U_Signature'] = str_replace("&lt;br&gt;","<br />",$user['U_Signature']);<br />      $printsig = $user['U_Signature'];<br />   }<br />

in those lines....

May I suggest a hot cup of tea to get your mind off the computer for a bit and then try and have a go at it? I am sure that it is a small typo that doesn't allow you to proceed.

Warm regards

Nikos


Nikos
joeuser #229527 01/15/2003 1:52 PM
Joined: Aug 2002
Posts: 1,191
Kahuna
Kahuna
Joined: Aug 2002
Posts: 1,191
Dave,

It is one query per month and it is working as expected. I have updated my previous post above, so go ahead and take it as it is and use it with the instructions.

Warm regards

Nikos


Nikos
joeuser #229528 01/16/2003 2:22 PM
Joined: Dec 2002
Posts: 173
Member
Member
Offline
Joined: Dec 2002
Posts: 173
Hi Dave

I've been trying to get this going for 2 days now - downloaded 3 times - uploaded after checking well, lost count.

I can only get as far as the calendar page and get this error.....

Parse error: parse error in /home/www/hillcrestknitwear/ubbthreads/newevent.php on line 261

I have checked this page about a million times but still the same.

I think it is the last bit that's wonky.
Can someone check this bit for me..The red bit is supposed to be deleted.

In newevent.php
==================================================
// ---------------------
// Grab the tablewrapper
list($tbopen,$tbclose) = $html -> table_wrapper();


if (!$debug) {
[:"red"] include("$thispath/templates/$tempstyle/newpost.tmpl"); [/]
$d = get_input('d', 'get');
$mon = get_input('mon', 'get');
$year = get_input('year', 'get');
include("$thispath/templates/$tempstyle/newevent.tmpl");
$html -> send_footer();
==========================================

I've tried it already with the closing bracket on every line but no good, is there supposed to be a closing bracket here or not.

I know we have to wait until someone fixes the instructions, but (excuse the pun) it's bugging me.

Is there someone trying to fix it or is it a dead duck?

LOL

Thanks


Thanks

Liahona
jfrosch #229529 01/16/2003 2:26 PM
Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
There should probably be a closing } after the send footer. Did you try one on the line below that?

Daine #229530 01/16/2003 2:36 PM
Joined: Dec 2002
Posts: 173
Member
Member
Offline
Joined: Dec 2002
Posts: 173
Hi Josh

Just did that and still the same?

THX


Thanks

Liahona
jfrosch #229531 01/16/2003 2:40 PM
Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
I hope to be able to look at and post updating instructions here maybe by this weekend. I've installed this for several clients and it's worked.. but I don't think the instructions were exactly right. (In other words some code may have changed from when this was written to the current version).

I've just been too busy to look at updating it, but it's on my list. Maybe that will help.

Daine #229532 01/16/2003 3:01 PM
Joined: Apr 2002
Posts: 1,768
Addict
Addict
Offline
Joined: Apr 2002
Posts: 1,768
I've posted a status update here. You're welcome to post corrected documentation if you like. In any case, I'll try to post the updated hack, with correct documentation, within the next few days.

Hal_dup2 #229533 01/16/2003 3:08 PM
Joined: Dec 2002
Posts: 173
Member
Member
Offline
Joined: Dec 2002
Posts: 173
Hi Josh/Dave

Thanks, I really need this as I have a whole years things to put on before I go live and let lots (dreaming) of members loose.

I will wait with bated breath.

THX


Thanks

Liahona
joeuser #229534 01/16/2003 3:18 PM
Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
Cool. Thanks Dave. Hadn't been paying attention to the main post.

Looks good.

Daine #229535 01/16/2003 6:39 PM
Joined: Dec 2002
Posts: 173
Member
Member
Offline
Joined: Dec 2002
Posts: 173
Hi all

I now have my calendar working..........

Thanks to Nikos for fixing all the wobbley bits out.

You guys are just great.

Thanks all


Thanks

Liahona
joeuser #229536 01/20/2003 4:42 PM
Joined: Dec 2002
Posts: 173
Member
Member
Offline
Joined: Dec 2002
Posts: 173
Hi Dave

Do you know how I can hide the time that shows on the
calendar as lots of my things don't have a time as yet,
or maybe left blank instead of having a time that is
wrong displaying?

Thanks


Thanks

Liahona
jfrosch #229537 01/20/2003 5:04 PM
Joined: Apr 2002
Posts: 1,768
Addict
Addict
Offline
Joined: Apr 2002
Posts: 1,768
Coincidentally, one of the changes I'm adding is a checkbox to hide the time when you post an event.

With the current hack, I think if you manually set the w3t_Events.E_Time field to 0 with a database query, that will hide the event time on the postlist (calendar display).

joeuser #229538 01/20/2003 5:45 PM
Joined: Dec 2002
Posts: 173
Member
Member
Offline
Joined: Dec 2002
Posts: 173
Hi Dave

UPDATE w3t_Events SET E_Time = "0"

Here is the output of your SQL command; Query executed OK, MySQL returned `0' with message `'.
rows returned by query, each with 0 fields.

Never worked, am I doing it wrong


Thanks

Liahona
jfrosch #229539 01/20/2003 6:15 PM
Joined: Apr 2002
Posts: 1,768
Addict
Addict
Offline
Joined: Apr 2002
Posts: 1,768
I meant that you should manually set E_Time to 0 for the events whose time you don't want displayed, not all the events.

But setting E_Time to 0 should have the effect I decribed. I just tested it with the current published version of the hack, and it worked.

joeuser #229540 01/20/2003 6:29 PM
Joined: Dec 2002
Posts: 173
Member
Member
Offline
Joined: Dec 2002
Posts: 173
Hi

I don't understand "manually set E_Time to 0"

This is what's in my postlist_event.php
$arrData['E_ID'] = 0;
$arrData['E_Date'] = mktime(0, 0, 0, $month, $bBirthday, $year) - $user['U_TimeOffset'] * 3600; // first day of this month, time 00:00:00
$arrData['E_Time'] = 0;
$arrData['E_Location'] = "Birthday";
$arrData['B_Subject'] = "<a href="$config[phpurl]/showprofile.php?Cat=$Cat&User=$bNumber&what=">$bUsername$bExtra</a><br />";
$arrData['B_Number'] = 0;
$arrData['B_Replies'] = 0;


Last edited by Liahona; 01/20/2003 6:36 PM.

Thanks

Liahona
jfrosch #229541 01/20/2003 6:39 PM
Joined: Aug 2002
Posts: 1,191
Kahuna
Kahuna
Joined: Aug 2002
Posts: 1,191
Dave,

In the current mod, there is no way to set the time to 0, since it defaults to a time on its own from the form. What Liahona though did seems quite reasonable to me, since this is how I used to do it.

Liahona, your query should have done the trick, but that error still bugs me... Any more info?

Warm regards

Nikos


Nikos
Hal_dup2 #229542 01/20/2003 6:47 PM
Joined: Dec 2002
Posts: 173
Member
Member
Offline
Joined: Dec 2002
Posts: 173
Hi Nikos

I don't have any errors?

Just the time which I have to put at 1:00 am so people will hopefully know that it is a mistake as there are no 0:00 hrs in the list.

THX


Thanks

Liahona
jfrosch #229543 01/20/2003 6:56 PM
Joined: Apr 2002
Posts: 1,768
Addict
Addict
Offline
Joined: Apr 2002
Posts: 1,768
The query you posted above is correct, but I expected to see a WHERE clause, so that it would only affect a specific event:

UPDATE w3t_Events SET E_Time = 0 WHERE E_ID = 'xxxxx'

jfrosch #229544 01/21/2003 3:54 AM
Joined: Dec 2002
Posts: 173
Member
Member
Offline
Joined: Dec 2002
Posts: 173
Hi

Is it possible to add a " 0 " (blank) to the list of time,
if so how do it, do I just search for "11" in the
postlist.php and add lines the same as the others with
" 0 " instead of a number?

Cheers


Thanks

Liahona
joeuser #229545 01/28/2003 7:00 PM
Joined: Apr 2002
Posts: 1,768
Addict
Addict
Offline
Joined: Apr 2002
Posts: 1,768
Update:

Due to time constraints, I'm abandoning work on this hack. With the planned changes, it's gotten far too complicated, is incompatible with the current version, and maintaining it will be too much of a headache.

joeuser #229546 01/31/2003 5:32 PM
Joined: Jan 2003
Posts: 1
Lurker
Lurker
Offline
Joined: Jan 2003
Posts: 1
I'm gonna wade right in here with some newbie questions...I need a calendar to work with UBB.x 3.0.4. (Or some other calander I can use on our site if it is not possible to combine with UBB) How would I set this up? If it is a complicated procedure, is it allowable to ask if someone on this list can be hired to do it? I can provide more details if required. Thanks for any help.

DetR6oit #229547 01/31/2003 5:45 PM
Joined: Apr 2001
Posts: 3,266
Member
Member
Offline
Joined: Apr 2001
Posts: 3,266
UBB version 3? Have you considered upgrading to UBB 6.3 or Threads 6.2. Either forum has hacks that provide a calendar like this one or the calendar mod over at ubbdev.com for UBB 6.3

Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
Actually... if I'm not mistaken.... UBB.x is an infopop hosted solution. (Basically a MySQL version of OpenTopic). Since it's hosted by Infopop, I don't think you can hack or modify any of the scripts, as you don't have access to them.
Sorry. You might wish to run UBB.Threads on your own server.. much more flexibility.

Daine #229549 01/31/2003 6:11 PM
Joined: Apr 2001
Posts: 3,266
Member
Member
Offline
Joined: Apr 2001
Posts: 3,266
I thought there were talking about a old version of UBB

Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
We got too many "UBB"'s to keep straight these days.

Daine #229551 01/31/2003 6:25 PM
Joined: Apr 2001
Posts: 3,266
Member
Member
Offline
Joined: Apr 2001
Posts: 3,266
LOL yeah they would have to wipe the dirt and dust off that version if they were talking the old version.

Joined: Aug 2002
Posts: 1,191
Kahuna
Kahuna
Joined: Aug 2002
Posts: 1,191
Just to inform everyone: I have made a slight change on the my post earlier concerning the integration of Profile Birthdays and Calendar 6.2. It appeared that for users with a time offset other than 0 the modification was moving the user's birthdays as many months forward or backward as the time offset.

Please refer to the previous post concerning this modification. The changes are a new variable declaration ignoring the time offset and the use of that variable in the database query.

Nikos


Nikos
Joined: Aug 1999
Posts: 184
Member
Member
Offline
Joined: Aug 1999
Posts: 184
Here is my attached instructions. Anyone is welcome to improve upon them. I will not be able to since I am changing a lot in the way the calendar diplays things for my own custom set now.

Attachments
67560-excelcalendar62instructs.txt (0 Bytes, 115 downloads)


Silly ricer.. Wings are for airplanes!
Joined: Aug 1999
Posts: 184
Member
Member
Offline
Joined: Aug 1999
Posts: 184
Now I just need to get the actual post display the date and time of the event instead of JUST the calendar. Anyone already do this?


Silly ricer.. Wings are for airplanes!
Joined: Mar 2000
Posts: 21,079
Likes: 3
I type Like navaho
I type Like navaho
Joined: Mar 2000
Posts: 21,079
Likes: 3
is it a 'members only' forum at your site? I'd love to see what you've done with it so far


- Allen wavey
- What Drives You?
Joined: Aug 1999
Posts: 184
Member
Member
Offline
Joined: Aug 1999
Posts: 184
Sign up and I will toss you access. It just a template change more or less to accomodate the reason the calendar is there.

www.theddz.com


Silly ricer.. Wings are for airplanes!
Joined: Aug 1999
Posts: 184
Member
Member
Offline
Joined: Aug 1999
Posts: 184
NOTICE: The time does not seem to wrok properly for the 12:00 hour and selecting am. It will display pm for the link in the calendar. Could this be from the time zone thing implemented?

Maybe this would be a good opportunity to try a conversion to military time??

And while I am thinkin about it. Is there a way to take that date and time of the event posted in teh calendar to display in the actual thread post? I confuse myself sometime if I read something and forgot what day it was listed under in the calendar part.


Silly ricer.. Wings are for airplanes!
Daine #229558 02/11/2003 1:55 AM
Joined: Apr 2002
Posts: 610
Code Monkey
Code Monkey
Joined: Apr 2002
Posts: 610
dont' know if this has been discussed or not, but I think it would be a good idea to add a blank spot in the time selection table. Honestly, I have no idea what time I was born, as well as with holidays and stuff. Just a thought.

Joined: Aug 2002
Posts: 1,191
Kahuna
Kahuna
Joined: Aug 2002
Posts: 1,191
I agree that we need to enhace the calendar and it is already on my list of things to do, since Dave_L is quite busy to continue supporting this modification.

The first thing I was working on was to allow for a null time, which will make this an all-day-event (like your birthday or other related events). I think I have something good set up on my machine at home but haven't been able to post anything since I had problems with my isp.

The next thing on my list will be to create an edit screen which will allow you to edit the events and also allow for deletion of the events when the parent post is deleted.

I will keep you posted on the progress and once I have this finished then I can take up on requests


Nikos
Hal_dup2 #229560 02/11/2003 10:02 AM
Joined: Jun 2001
Posts: 3,273
That 70's Guy
That 70's Guy
Offline
Joined: Jun 2001
Posts: 3,273
I posted a code change that will delete the event when the related post is deleted a while back in one of the earlier version threads. I'll have to search for it. It's pretty simple though.

Is the event timestamp more than one field? I forget but I don't think it is. I thought Dave_L mentioned something about condensing the time/date fields into a single timestamp. If that's the case then the null value wouldn't work. I guess it's a matter of choice though.

sjsaunders #229561 02/11/2003 10:13 AM
Joined: Aug 2002
Posts: 1,191
Kahuna
Kahuna
Joined: Aug 2002
Posts: 1,191
I recall the post of Dave_L regarding the merging of the two fields. At the moment there are two fields one for the date and one for the time, however I don't remember if the time is used. The null value on the time that I was thinking could in effect set the time to be 00:00:00 but also set a new field "AllDayEvent" to yes. this way we can cater for events that will occur at midnight but also get rid of the time if we have an all-day event.

There are also some other fields there for recurrance etc. Those need additional consideration in the future.


Nikos
Hal_dup2 #229562 02/11/2003 10:19 AM
Joined: Jun 2001
Posts: 3,273
That 70's Guy
That 70's Guy
Offline
Joined: Jun 2001
Posts: 3,273
Sounds good.

I believe Dave intended on stripping those other fields out for the time being and then add them back as needed.

sjsaunders #229563 02/11/2003 10:47 AM
Joined: Apr 2002
Posts: 1,768
Addict
Addict
Offline
Joined: Apr 2002
Posts: 1,768
I had implemented most of the changes I had talked about, including getting rid of the extra time column, and replacing it with a flag indicating whether the time-of-day should be displayed, or only the date.

One problem with these changes is that they would not be downward-compatible with the current version of this hack, so an "altertable" would be needed.

I had started to add editing capability. It involved changes to a bunch of files (several scripts and several templates). Keeping all of these files up to date when doing version upgrades would have been a big headache.

And then there was the birthdate modification to this hack.

These problems, combined with the fact that I was getting behind on other work, are why I had to abandon work on this hack.

Nikko, if you want, I could give you the changed files, although the changes are incomplete, and they're not fully tested or documented.

I'm wondering if it would be better to make the calendar a separate add-on, rather than a hacked forum.

joeuser #229564 02/11/2003 11:55 AM
Joined: Aug 2002
Posts: 1,191
Kahuna
Kahuna
Joined: Aug 2002
Posts: 1,191
Dave (L)

I wouldn't mind having a look at the implementation although come to think of it your suggestion concerning an addon is far better for future releases of the threads software. Even with the best comments in the code we will have problems.

If you want we can discuss it a bit in private and then come up with a better design. I have already implemented a calendar solution (needs tidying up though and documenting) which could in effect be modified to work as an addon.

Damn! Why does the day have to have only 24 hours and I have to sleep 5 of them


Nikos
Hal_dup2 #229565 02/11/2003 2:31 PM
Joined: Mar 2000
Posts: 528
Junior Member
Junior Member
Offline
Joined: Mar 2000
Posts: 528
My opinion on the Calendar at this stage is that it would be best served to separate it from inclusion to UBB.Threads...for a few reasons.

1. Easier to install
2. Does not get touched with subsequent UBB.threads upgrades
3. Adds to front page much the same way the "WHO'S ONLINE" hack does...an addition to the template.

I might try messing with the 6.2 a bit, see if I can happily separate it.

joeuser #229566 02/11/2003 3:11 PM
Joined: Mar 2000
Posts: 528
Junior Member
Junior Member
Offline
Joined: Mar 2000
Posts: 528
I thought more on this and looked at some detail in the code, and it should be fairly easy (as a quick, not a perma thing) to separate out.

1. Copy the w3t_Posts table and name it w3t_EventData
2. DELETE FROM w3t_EventData WHERE B_Board not like 'calendar' (change this to keep only your calendar posts)
3. Copy the modified postlist.php and rename it eventlist.php
4. In the ubbthreads.tmpl write an "IF" statement that says if $Calendar='Y', then the <a href="{$config['phpurl']}/postlist.php?Cat=$Cat&Board={$forum[$c][$f]['Keyword']}"> url should point to eventlist.php instead of postlist.

This might be easier to install once this has had a few iterations with all of you...as we would have 4 separate php pages and a few tmpl pages...and the only UBBThreads page we would have to modify would be the ubbthreads.tmpl. Adding the w3t_Events would stay the same, and we would add a w3t_EventData in a fresh install.

I know I am missing something (passing $Calendar to ubbthreads is first in my head)...but I am sure this would be easy to figure out, and we could then modify this calendar add-on MUCH easier than trying to re-hack it every upgrade.

Thoughts?

Joined: Aug 1999
Posts: 184
Member
Member
Offline
Joined: Aug 1999
Posts: 184
Seperating it would also remove the ability for visitors to comment on anything put there I think.

Personally I have come to like the ability to reply to a post.


Silly ricer.. Wings are for airplanes!
Franky #229568 02/12/2003 2:32 AM
Joined: Mar 2000
Posts: 528
Junior Member
Junior Member
Offline
Joined: Mar 2000
Posts: 528
Actually you can still comment, etc on the above setup. I changed my test board tonight just to see how it would work.

But on the flip side...on my live board I copied postlist.php to eventlist.php - and I copied showflat.php to showevent.php. So I separated the PHP pages, made 2 new templates for them, and voila...I can customize the Events pages AND/OR upgrade UBBThreads - and they stay separate.

Joined: Jan 2002
Posts: 674
Junior Member
Junior Member
Offline
Joined: Jan 2002
Posts: 674
do i dare install this.... with the warning ?

Kelly #229570 03/24/2003 4:46 AM
Joined: Aug 2002
Posts: 218
Member
Member
Offline
Joined: Aug 2002
Posts: 218
Any news about this? Has anyone now a working calendar and a 100% documentation?

edr #229571 03/24/2003 5:37 AM
Joined: Apr 2001
Posts: 3,266
Member
Member
Offline
Joined: Apr 2001
Posts: 3,266
This works on 6.2.3

edr #229572 03/24/2003 5:38 AM
Joined: Apr 2001
Posts: 3,266
Member
Member
Offline
Joined: Apr 2001
Posts: 3,266
This works on 6.2.3 you just need to sift through and find any updates you mightr like. Try Nikos's version.

Joined: Mar 2000
Posts: 21,079
Likes: 3
I type Like navaho
I type Like navaho
Joined: Mar 2000
Posts: 21,079
Likes: 3
hmmm... might be best to start a new thread with the most current code in the first post - even I am a bit lost about which version to use, lots of changes on many pages


- Allen wavey
- What Drives You?
Joined: Jan 2002
Posts: 674
Junior Member
Junior Member
Offline
Joined: Jan 2002
Posts: 674
Please

Joined: Jun 2002
Posts: 15
Newbie
Newbie
Offline
Joined: Jun 2002
Posts: 15
[]AllenAyres said:
hmmm... might be best to start a new thread with the most current code in the first post - even I am a bit lost about which version to use, lots of changes on many pages [/]

I agree, I really need a Calendar for our forum. We have the calendar hack for our UBB Classic which we are about to migrate over to Threads. Our users love the calendar and couldn't live without it for too long.

I am really confused as to the status of this calendar, who's presently "leading" development of it and which is the most recent download.

A new thread with updated info in the first post would be great.

Rob

Joined: Apr 2001
Posts: 3,266
Member
Member
Offline
Joined: Apr 2001
Posts: 3,266
Try downloading and installing the one posted by EzcelsiorDD on page 9

Joined: Aug 1999
Posts: 184
Member
Member
Offline
Joined: Aug 1999
Posts: 184
ExcelsiorDDZ I did not post it that I remember. Oh well, all I konw is that it works and I have not been touching it. See it at www.theddz.com in the gaming calendar section.


Silly ricer.. Wings are for airplanes!
Joined: May 1999
Posts: 3,039
Guru
Guru
Offline
Joined: May 1999
Posts: 3,039
Just an FYI. There will be a calendar system in 6.4. It won't be this particular version, rather a standalone system. I won't say much more than that at this time because it's still under development.


UBB.threads Developer
Sally #229579 04/13/2003 1:33 PM
Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369


Good work.


Daine #229580 04/13/2003 1:34 PM
Joined: May 1999
Posts: 3,039
Guru
Guru
Offline
Joined: May 1999
Posts: 3,039
Dunno what it is, but that dancing banana just freaks me out!


UBB.threads Developer
Sally #229581 04/13/2003 3:24 PM
Joined: Apr 2001
Posts: 3,266
Member
Member
Offline
Joined: Apr 2001
Posts: 3,266
ExcelsiorDDZ the first post on page 9 has the attached file that has the updated instructions you posted and yes it does work on your site as well as mine

Joined: Feb 2002
Posts: 950
Hacker
Hacker
Offline
Joined: Feb 2002
Posts: 950
I only have 6 pages.....

gailg #229583 04/13/2003 5:30 PM
Joined: Apr 2001
Posts: 3,266
Member
Member
Offline
Joined: Apr 2001
Posts: 3,266
6 pages there are 11 pages to this thread. LOL

You have your thread view set to a higher number. Okay lets try this one Michael it should be the 81st post.

I do beleive top of page 5 if you have yours set to 20 posts per page. I have mine set to 10.

Sally #229584 04/16/2003 1:45 PM
Joined: Oct 1999
Posts: 282
Enthusiast
Enthusiast
Offline
Joined: Oct 1999
Posts: 282
This is too much! Two great news on one day.

Subforums and calendar. I still can't believe it

Sally #229585 04/16/2003 2:45 PM
Joined: Mar 2000
Posts: 21,079
Likes: 3
I type Like navaho
I type Like navaho
Joined: Mar 2000
Posts: 21,079
Likes: 3
[]Scream said:
Dunno what it is, but that dancing banana just freaks me out! [/]

He's my favorite


- Allen wavey
- What Drives You?
Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
I won't tell you what my users say about the little bananna man.

Sally #229587 04/16/2003 10:34 PM
Joined: Jul 2001
Posts: 442
Enthusiast
Enthusiast
Offline
Joined: Jul 2001
Posts: 442
Awesome, any time frame for 6.4? mid summer maybe?

Sally #229588 04/17/2003 9:49 PM
Joined: Jun 2002
Posts: 15
Newbie
Newbie
Offline
Joined: Jun 2002
Posts: 15
[]Scream said:
There will be a calendar system in 6.4.[/]

Great news! Looking forward to all the details as well as 6.4b

Rob

Joined: Feb 2002
Posts: 950
Hacker
Hacker
Offline
Joined: Feb 2002
Posts: 950
I had to make one mod for it to print hte time properly:

$tm += ($user['U_TimeOffset']*3600);
$h = strtolower(strftime ("%I", $tm));
$m = strtolower(strftime ("%M", $tm));
$mer = strtolower(strftime ("%p", $tm));

in postlist_event (in two places). The convert_time was returning -1.

Joined: Aug 2002
Posts: 218
Member
Member
Offline
Joined: Aug 2002
Posts: 218
[]AllenAyres said:
hmmm... might be best to start a new thread with the most current code in the first post - even I am a bit lost about which version to use, lots of changes on many pages <img src="/threads/php/images/graemlins/tongue.gif" alt="" /> [/]

Hi,

can someone please paste a link here to a working calendar for 6.2.3

There are so many comments and differents ways described here that I am confused and don't know what to use.

Allens idea to make this a little bit clearer again is welcome

edr #229591 05/14/2003 9:09 AM
Joined: Feb 2002
Posts: 950
Hacker
Hacker
Offline
Joined: Feb 2002
Posts: 950
http://www.viperalley.com

I have it working under Calendar of Events...

Download the original file in the first post. That should mostly work. I think that download includes the changes found in a later upload as when I reviewed them, I didnt have to make any changes.

If your dates are messed up - then apply my fix above.

Shouldnt take more than an hour.

gailg #229592 05/15/2003 9:01 AM
Joined: Mar 2000
Posts: 21,079
Likes: 3
I type Like navaho
I type Like navaho
Joined: Mar 2000
Posts: 21,079
Likes: 3
Would converting/importing the events here to the new calendar in 6.4 be relatively painless?


- Allen wavey
- What Drives You?
Joined: Feb 2002
Posts: 950
Hacker
Hacker
Offline
Joined: Feb 2002
Posts: 950
Depends on how they do calendars in 6.4 - but if the uses the Posts tables, shouldnt be too hard. If they make a new table, then would probably just be a metter of mapping fields to fields.

Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
6.4 does not use the posts table. I think it uses it's own table for events etc... so I'm not sure til I see the actual code.

Let's hope someone can come up with a solution to do so. In the meantime - I've been putting the brakes on doing this calendar install.

Joined: Dec 2000
Posts: 1,471
Addict
Addict
Offline
Joined: Dec 2000
Posts: 1,471
I'll tell you if you send my the table structure of the calendar that will be in 6.4

-Fusion- #229596 05/15/2003 4:00 PM
Joined: Mar 2000
Posts: 21,079
Likes: 3
I type Like navaho
I type Like navaho
Joined: Mar 2000
Posts: 21,079
Likes: 3
if only I had it


- Allen wavey
- What Drives You?
Joined: Aug 2003
Posts: 8
Junior Member
Junior Member
Offline
Joined: Aug 2003
Posts: 8
ive got this working on my 6.3.2 forum

ni6htm4r3 #229598 12/23/2003 11:59 PM
Joined: Oct 2002
Posts: 165
Member
Member
Offline
Joined: Oct 2002
Posts: 165
Wondering if there is any conversion for this to version 6.4?

I have this installed and it has a decent amount of future info.... didn't want to loose it. Has anyone else upgraded to 6.4 and found any solutions?

Joined: Jun 2002
Posts: 670
Code Monkey
Code Monkey
Offline
Joined: Jun 2002
Posts: 670
6.4 already has a calendar.

luan #229600 01/01/2004 10:43 AM
Joined: Apr 2001
Posts: 3,266
Member
Member
Offline
Joined: Apr 2001
Posts: 3,266
Nope the format is entirely different and as this mod was merely a mix match of various versions put together by many people without no-one supporting it an import script is not around.

Page 1 of 4 1 2 3 4

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
Gizmo
Gizmo
Portland, OR, USA
Posts: 5,833
Joined: January 2000
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)