Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Snitz Forums 2000 MOD-Group
 MOD Add-On Forum (W/Code)
 MOD: New Events Calendar for 3.4.03 beta
 New Topic  Reply to Topic
 Printer Friendly
Previous Page | Next Page
Author Previous Topic Topic Next Topic
Page: of 32

Francodepaw
Junior Member

USA
111 Posts

Posted - 18 November 2002 :  17:48:23  Show Profile  Reply with Quote
Ne one have a cal.asp that works with MySql I can grab. I have tried a clean on mine many times. Isn't any one else with MySql having these problems:

Click on:

Weekly view and all events for that week are on Sunday (1st day of week).

Click on Events List and "Display: Future Events" Drop down draws fine. Topic area solid black with Title and Date on bottom.

???



<
Go to Top of Page

Francodepaw
Junior Member

USA
111 Posts

Posted - 19 November 2002 :  21:57:52  Show Profile  Reply with Quote
One down...
After doing a bunch of response.writes I found that the filter was not setting for me.

In cal.asp under the sub view weekly if commented out the if/end for the filter and now the events appear on proper day of the week. This does appear to be a MySql issue.

What I found is to get a rs.recordcount to work properly (MySql)we need to add a rs.cursorlocation = adUseClient just before the rs.Open StrSql, adOpenStatic

But this just gave me a different error when it got to a day that had an event so I removed the rs.cursorlocation = adUseClient and commented the If/End If, that sets up the day of week filter, and weekly view works fine with MySql.

'### Determine if there are any events to display ###
dim intEventsforWeek
intEventsforWeek = rs.RecordCount


'### 7 days in a week ###
dim iWeek
'### Draw Events for Date and left and right arrows ###
for iWeek = 1 to 7
Response.Write "<TABLE cellspacing=""0"" cellpadding=""0"" width=""95%""><TR><TD bgColor=""" & strTableBorderColor & """>" & vbnewline & _
"<TABLE cellspacing=""1"" cellpadding=""2"" width=""100%""><TR><TD bgColor=""" & strCategoryCellColor & """ vAlign=top>" & vbnewline & _
getCurrentIcon(strIconEvent,"","align=""absmiddle""") & " <A href=""cal.asp?view=daily&date=" & dateCursor & """><FONT face=" & strDefaultFontFace & " size=" & strDefaultFontSize & " color=" & strCategoryFontColor & "><B>" & _
FormatDateTime(dateCursor, vbLongDate) & vbnewline & _
"</B></FONT></A>" & vbnewline & _
"</TD></TR>" & vbnewline & _
"<TR><TD bgColor=""" & strAltForumCellColor & """>" & vbnewline

'### Get the Events for this day only ###


'if intEventsforWeek > 0 then
rs.filter = ""
rs.filter = "T_EVENT_DATE = '" & DateToStr(dateCursor) & "'"
'end if

Note: I also found this intEventsforMonth filter combination in cal_function.asp that caused Days with events on small calendar to not highlite. Commenting the IF/END IF cleared that problem as well. Again this must be a MySql issue.
<

Edited by - Francodepaw on 19 November 2002 23:15:13
Go to Top of Page

Francodepaw
Junior Member

USA
111 Posts

Posted - 19 November 2002 :  22:39:20  Show Profile  Reply with Quote
Ok got my final MySql issue fixed. Event Listing View would display, Events Text box would be solid black and Title and date would be at the bottom of that box.

Around line 967 cal.asp
I commented out the rs.cursorlocation and a few lines down the rs.absolute page and all seem to be working fine now.

dim rs
set rs = Server.CreateObject("ADODB.Recordset")
' rs.CursorLocation = adUseClient
rs.PageSize = intEventsPageSize ' maximum numbers that can be displayed on page
rs.open StrSql, My_conn

dim intTotalPages
intTotalPages = rs.PageCount


'### Added for paging ###
if intCurrentPage < 1 then intCurrentPage = 1
if intCurrentPage > intTotalPages then intCurrentPage = intTotalPages
' if intCurrentPage <> 0 then rs.AbsolutePage = intCurrentPage

<

Edited by - Francodepaw on 19 November 2002 23:21:33
Go to Top of Page

red1
Junior Member

355 Posts

Posted - 20 November 2002 :  06:38:40  Show Profile  Reply with Quote
Thanks for all this, Francodepaw. Maybe I'll finally install MySql so I can find these bugs and others.

quote:

What I found is to get a rs.recordcount to work properly (MySql)we need to add a rs.cursorlocation = adUseClientjust before the rs.Open StrSql, adOpenStatic
But this just gave me a different error when it got to a day that had an event so I removed the rs.cursorlocation = adUseClient and commented the If/End If, that sets up the day of week filter, and weekly view works fine with MySql.


I added this one as an optimization thing, so that it doesn't have to filter the recordset if it's empty. But I suppose it also works without it.

quote:

Around line 967 cal.asp
I commented out the rs.cursorlocation and a few lines down the rs.absolute page and all seem to be working fine now.



But that would make the paging not work. This would be a problem if you had 100+ events... all of them would display on the page. I'll change this part to something better, I just have a lot on my hands right now.<

My Mods:
New Events Calendar
New Non-database Active Users
Go to Top of Page

Francodepaw
Junior Member

USA
111 Posts

Posted - 20 November 2002 :  09:04:41  Show Profile  Reply with Quote
K, I will look to see If I can find how MySql uses the rs.absolutepage function and see if I can get that to work.<
Go to Top of Page

red1
Junior Member

355 Posts

Posted - 20 November 2002 :  20:39:48  Show Profile  Reply with Quote
I suppose recordset paging doesnt work with mysql, because even snitz has mysql-specific code to handle paging. I think I'll just implement that for the events list.<

My Mods:
New Events Calendar
New Non-database Active Users
Go to Top of Page

Francodepaw
Junior Member

USA
111 Posts

Posted - 20 November 2002 :  23:11:58  Show Profile  Reply with Quote
Cool and Thanx...

Love the mod. I use on intranet in a hidden forum for my group and we use as a planner. Then I have a public forum that the corporate spam group use to post events for the company.

Thanx for the effort you have put into this!<
Go to Top of Page

Zogor
Starting Member

2 Posts

Posted - 22 November 2002 :  18:23:40  Show Profile  Reply with Quote
Hi I want some extra field like "Local:" and some more... How can I add them?<
Go to Top of Page

red1
Junior Member

355 Posts

Posted - 24 November 2002 :  13:06:09  Show Profile  Reply with Quote
An easy way would be to just type it in your message.

If you really want a "locale" field, first you need to add it to the database, then add the html code for the textbox in post.asp, then put the form processing code in post_info.asp<

My Mods:
New Events Calendar
New Non-database Active Users
Go to Top of Page

jimlord
New Member

USA
57 Posts

Posted - 30 November 2002 :  19:47:23  Show Profile  Reply with Quote
In readme.wri you have:

quote:
FORUM.ASP - 7 changes
-------------------------------------------

* On line 238 find this:
strSql = strSql & "T.T_LAST_POST_REPLY_ID, M.M_NAME, MEMBERS_1.M_NAME AS LAST_POST_AUTHOR_NAME, "
* Create a blank line below it and insert this:
strSql = strSql & "T.T_LAST_POST_REPLY_ID, M.M_NAME, MEMBERS_1.M_NAME AS LAST_POST_AUTHOR_NAME, T.T_ISEVENT "

I believe that should be "Replace with this:" not create a blank line and insert.

So I figured that out on the fly, completed the changes and...


All was beautiful, until I clicked on "Events Calendar" from my forum page to get to "forum/cal.asp".
My site wrapper table got fubared. I've got the basic header, left menu, content section, right menu, footer layout. The content section went all the way to the right side, and what is supposed to be the right menu was underneath the content section.

So for fun, I clicked on the "Weekly" tab. Same thing.

Then on the "Monthly" tab. Viola! The wrapper was correct now, and the right side of my table was on the right, and not under the calendar!

Clicked on "Yearly" tab and it works as well.


Here's the problem.

In "cal.asp", the last line of the "Monthlyview" and "Yearlyview" subroutines (working fine) is:
quote:
"</TD></TR></TABLE>" & vbNewLine


The last line of the "Dailyview" and "Weeklyview" subroutines (breaking the table) is:
quote:
"</TD></TR></TABLE></TD></TR></TABLE>" & vbNewLine


Once I removed the extra "</TD></TR></TABLE>" from that last line in each subroutine (lines 257 and 486), it all worked like a charm.

Thanks for a great mod, and a saving grace for our website!
<

"That button did what?"
Go to Top of Page

red1
Junior Member

355 Posts

Posted - 01 December 2002 :  18:54:56  Show Profile  Reply with Quote
good catch, thanks <

My Mods:
New Events Calendar
New Non-database Active Users
Go to Top of Page

pknaz
Junior Member

USA
117 Posts

Posted - 02 December 2002 :  15:22:50  Show Profile  Visit pknaz's Homepage  Send pknaz an AOL message  Send pknaz an ICQ Message  Send pknaz a Yahoo! Message  Reply with Quote
Maybe i missed this somewhere, but is the ability to restrict events in a forum already built into the code? I'm assuming that it isn't. Just didn't want to duplicate efforts with someone else if it was already built into the code or if someone else was already working on this added functionality. I can't have people posting events in any forum that they please. If anyone else is working on this added functionality i would like to colaborate with you.<
Go to Top of Page

laser
Advanced Member

Australia
3859 Posts

Posted - 02 December 2002 :  15:47:37  Show Profile  Reply with Quote
red1 will add this feature before the proper release I think, he posted about it yesterday<
Go to Top of Page

hmmm
Starting Member

35 Posts

Posted - 10 December 2002 :  00:02:51  Show Profile  Reply with Quote
My cal_constants.asp doesn't seem to be opening. when I point to it in my browser it doesn't do anything. blank. nothing.

Any Ideas?

duh it doesn't ...does it. you just open and edit it.....<

Edited by - hmmm on 10 December 2002 00:10:05
Go to Top of Page

laser
Advanced Member

Australia
3859 Posts

Posted - 10 December 2002 :  03:48:35  Show Profile  Reply with Quote
yep, that's right, pure ASP, no HTML .... sounds like you got it now.<
Go to Top of Page
Page: of 32 Previous Topic Topic Next Topic  
Previous Page | Next Page
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.27 seconds. Powered By: Snitz Forums 2000 Version 3.4.07