From the horses mouth...

Tuesday January 15, 2008

Some users of the ajax calendar and survey are having problems with the admin tools and authentication. Well, I've figured out what's causing that problem. Straight from php.net documentation...

"The HTTP Authentication hooks in PHP are only available when it is running as an Apache module and is hence not available in the CGI version."

So having php installed as an Apache module is the only way the basic auth built into those tools is going to work.

UPDATE: I have put together a workaround for this problem. Here's the links to download the new admin files.

http://www.bmgadg.com/download.php?file=super_ajax_calendar_cgi.zip http://www.bmgadg.com/download.php?file=ajax_survey_cgi.zip

Please let me know if you have any problems with it.

comments Comments

Can't Get With WordPress

by johny

hi

i cannot get ajax_survey to work with WordPress. i cannot figure out where to put the header and footer codes.

j


I don't know WordPress

by Marty

I've gotten several inquiries about how to install into WordPress. I have never used WordPress and I know nothing at all about it. Sorry guys! Anyone that has a suggestion, please post here.


Calendar admin page works, calender itself does not

by Alexander Kriegisch

I tried AJAX super calendar and can edit events on the admin page, but do not see the calendar control itself in my page Firefox shows an empty space, Konqueror nothing at all.

I should mention that I had to change the DB name from "calendar" into what my provider uses as an auto-name for MySQL DBs. As the admin page works, this seems to be correct.


Missing file in distribution?

by Alexander Kriegisch

It is me again. I just noticed that super_calendar.js contains the URL

/calendar/super_calendar.php?blah

But the corresponding PHP file is nowhere to be found in the download archive. Is that the reason for my problem above?


Problem solved

by Alexander Kriegisch

I am an idiot, I somehow forgot to upload the missing file and then looked into the wrong download archive (CGI workaround). Please delete this and the other two postings and pardon me, please.


black page

by darran

admin area works fine, xhtml page is blank!!


blank! not black

by darran

blank! not black


work like a charm

by mediablitz

after some minor path issues, it works great also it is not very big (400 x 200).

Drawing out a file hierarchy helped enormously.


Logout Function

by Jori

For security and the cgi work around it'd be optimal to add a log out feature/function.


Logged Out

by Marty

You're automatically logged out when you close the browser.


Survey works only after running admin

by Paul

I installed the survey and thought all was fine, until I tried to access it from another machine. I didn't get past the waiting gif. I ran admin from that machine, only opening & closing admin, then the script worked.

Does that make any sense, or suggest anything obvious I missed?


I love this calendar

by John Everden

I love this calendar, it's perfect for what I need it for! I did a few modifications, to suite it to my needs. I really like it because the code is clean enough to add the control panel into my existing control panel without much hassle. By far the easiest to modify and best calendar on the net. I also had some problems with the path varibles in the javascript file , but it's all fixed now! Thank you so much


question/comment

by James

I love this calendar, and it works (almost) great for me...just a couple of things:

1. I've added it to a pre-made theme page with its own style sheet etc, and somehow the calendar event when clicked on only has room for a single word. So I have a paragraph written with one word per line going down the screen. If I take it out of the theme page it works fine. I suspect conflicting css code, but I can't find any common tags. Any idea where to look? I realize you have no reference point as far as what I've done, let me know if you want to see the code.

2. When you use the month/year selector I had an issue of the month and year names being cut off. I added ' ' to the code so it doesn't do that anymore. Also with the selector, just personal preference here: Clicking the down arrow for the jump, then deciding to use the left/right navigate arrows instead, it should auto-close the jump selector.


question/comment again

by James

For point #1, nevermind, I figured it out. In super_calendar.php, there's a div tag with a class that has no CSS info for it: <div class='line'>

I removed the class, and it works fine :)


#lin in css

by Ivan Gutovic

James, look near line 140, there is #event .line class


Internet Explorer 7

by AJ Smith

Hi, I got this working in Firefox fine, no problem. But it won't display in IE7... just get a white box, short height correct width. Is like none of the images for it will load in IE7


Love it by the way.

by AJ Smith

By the way, I forgot to add its a brilliant calendar! I love it, looks great!


Thanks Guys!

by Marty

Thanks for the comments guys, please post any fixes that you have for others to benefit from.

I haven't had a lot of time lately to work on bugs and improvements, so any help you can provide is greatly appreciated!!


Can't access Admin to add event

by Meghan

By the way, I first have to say, what an awesome calendar! I'm able to display the calendar just fine on my webpage. However, I replaced the CGI fix admin file, but I'm not able to get into the admin. The login page comes up, I enter the user name/password and press enter, but the page refreshes back to the login. Any suggestions?


RE: Can't access Admin to add event

by Marty

I'm not sure, but that sounds like the problem that occurs when you try to use the original admin file on a system where PHP is installed as a CGI instead of an Apache module. Make sure you have deleted the original file and replaced it with the CGI workaround.


Workaround gets stuck on the login screen.

by Paul Bunker

what it says on the tin.

gah, and i cant test it on my space either because i cant create databases, only tables. :(

please help! :)


tried anf failed both ways on my webspace

by paulbunker

I cant get past the security. it looks so pretty i just cant give up


I have the same problem White page

by Julien Fontaine

Please read :

Calendar admin page works, calender itself does not by Alexander Kriegisch

I Must be missing something julienmassillia[@]gmail[.]com


Won't connect to database

by Jimbo

I've tested my database ok, but when I try to add event I get "Sorry, a database error occured. 1046: No database selected" I triple checked all my database info and its right. Also calendar wont show up, just a blank page. any help would be great, I like the looks of this calendar.


Won't connect to database

by Julien Fontaine

Hey Jimbo,

I am using this script the database doe connect, but when Im running super_calendar.php I get :

This XML file does not appear to have any style information associated with it. The document tree is shown below.

Any tricks ? julienmassillia[at]gmail[.]com


Thanks Julien, I got it

by Jimbo

I didn't realize I had to change the name from the default 'calendar' database to the name of my database in the XML on both super_calendar.php (line 16) and super_calendar_admin.php (line 148). That is something that should be in the directions. Awesome Calendar!


Can't get survey to connect.

by Logan

I've put up the survey and can use the admin no problem. However the survey won't appear on page. I couldn't name my db 'survey'. Is there somewhere else in the admin.php code that I have to change the db name.


Change first day !!

by Siddus

The calendar works just fine, but I have a problem with trying to make the calendar begin with monday instead of sunday.. Any help with this issue is appreciated.


no go

by no

It Simply Does Not Work, Please fix. I spent hours trying to get this to display, but nothing.


Individual Problems

by Marty

The calendar has been installed hundreds of times by different users without issue, so I'm sorry if it's not working for you.

I try my best to make things as easy as possible and error free. Occasionally there will be installation issues on some setups, but I can't help diagnose everyone's individual problems.

Hope you understand!


Replace "Event" with event title

by Bill

Is it possible to replace the Event on the main calendar with title of the actual event?

Where can you adjust the height of the days?

Thanks


pls help me fix this

by adaeze

I saw someone with a similar problem, I get this error when I want to add a new event Sorry, a database error occured. 1046: No database selected my database name is 'calender' and I dont know the changes to come


sorry

by ada

changes to make,sorry anwokedi@quanteq.com


i fixed it

by ada

i fixed the error, great calender


Change first day !!

by Siddus

The calendar works just fine, but I have a problem when I try to make the calendar begin with monday instead of sunday.. Is there a way to fix this ??


calendar is blank

by Michael

The admin page pops just fine, no issues, however the calendar does not show and that's kinda irritating. Darin, did you ever figure your issue out regarding this?


New Fix

by Marty

Hey guys, thanks for all the feedback, I greatly appreciate it!

A bug has been brought to my attention. The calendar marks the current day in red for every year, not just the current year.

I uploaded a new zip file that has this fix already done, but here are the steps to fix it, it's really simple...

On line 118 you should see

if(($cur==$today[mday]) && ($name==$today[month])) $xml.=" style='color:#C00'";

Change that to this

if(($cur==$today[mday]) && ($name==$today[month]) && ($year2==$today[year])) $xml.=" style='color:#C00'";

All that's added is the check for the year. That should fix it.

For those who are having trouble with the calendar for other reasons, I think I've mentioned this before, but I can't help diagnose every little issue that comes up.

Everyone's setup is different, so I try to make things work with the most common setup. I really wish I could help, but I don't have time to help everyone.

I will make this offer though, I am available for hire at $75/hr to install the calendar (or any of my other scripts) on your site, so contact me if you want this level of service.

Thanks again!! :)


Still No Fix?

by Dante

A lot of people are posting problems on admin working but calender not showing on site. Then they say they get it fixed, can you guys that got it fix please post the solution? All my mysql information is correct and still can't get it to function right. Thanks!


RE: Still No Fix?

by Marty

I think they fixed their issues by changing the mysql_connect() function to reflect the name of their database.

By default the database name is calendar, but you may or may not have named your database calendar.

There is a line in both the calendar and admin files where you need to change the database name.

Hope this helps!!


XML error

by Bob

I'm kind of new to webpages so this may be a rookie mistake but I would be grateful if someone could point me in the right direction. I've double-checked my database name and logins. The I put the javascripts in never renders but loads continuously. When I try to run the super_calendar.php page I get the error below. Is there some sort of formatting error on my part?

The XML page cannot be displayed Cannot view XML input using XSL style sheet. Please correct the error and then click the Refresh button, or try again later.

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

Only one top level element is allowed in an XML document. Error processing resource '.../ajaxcal...

<b>Notice</b>: Undefined index: event in <b>...\ajaxcalendar\super_calendar.php</b> on line &l...


If it shows a Blank page!!!

by NickInZim

Well!

I too had problems with the calendar page showing nothing, it's all to do with paths! Our site is hosted on Linux so if yours is windows I can't guarantee it'll work for sure, but try this anyway. (Note: Linux is definitely Case sensitive, so be careful about changing file names)

Open the Calendar Page (e.g. MyCal.htm), PHP, CSS and JS files and change all instances of "/calendar" to "calendar" e.g. "calendar/images/calSuccess.gif". In the CSS and Admin files, I found some pics still wouldn't show after that, so I removed the "calendar" altogether e.g. "images/calSuccess.gif"

I then faced the problem that I kept entering the correct password for the admin page but it kept refusing, this is because of the Apache Module/CGI problem. Simply download the fix and change the paths for the pics as shown above.

Note to the author: Is it possible to fix this and provide an update. Also when using the CGI fix for the calendar, when you are offered the login page it says Survey not Calendar.


WHAT IS THE PROBLEM????

by kramdraw85

I've tried everything i can get the ajax calender to work but I can't get the super calendar to show up. The admin works just fine....what am I doing wrong?

Here is my HTML

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <link rel="stylesheet" type="text/css" href="/calendar/super_calendar_style.css" />

<script type="text/javascript" src="/calendar/super_calendar.js"></script>

<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <title>Calendar</title> <style type="text/css"> <!-- --> </style> </head>

<body>

<div id="calback" style="background-color:#00FF66;">

<div id="calendar" style="background-color:#00FF66;"></div>

</div> [p]super calendar

<script type="text/javascript">navigate('','','');</script> </body> </html> [/p]

WHAT IS PROBLEM II

by kramdraw85

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <link rel="stylesheet" type="text/css" href="/calendar/super_calendar_style.css" />

<script type="text/javascript" src="/calendar/super_calendar.js"></script>

<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <title>Calendar</title> <style type="text/css"> <!-- --> </style> </head>

<body>

<div id="calback" style="background-color:#00FF66;">

<div id="calendar" style="background-color:#00FF66;"></div>

</div> [p]super calendar

<script type="text/javascript">navigate('','','');</script> </body> </html>[/p]

?

by KRAM

\" <script type=\"text/javascript\">navigate(\'\',\'\',\'\');</script> </body> </html>\"


Multiple Admin users

by Bowman

WHat is the correct format for adding to the array for adding multiple admin users on super_ajax_calendar;

Right now it's

////////////////////////////////////// // add and remove users here $vu = array('user' => 'password'); //////////////////////////////////////


RE: Multiple Admin users

by Marty
$vu = array('user' => 'password','user2' => 'password','user3' => 'password');

Super Calendar Did Not Show Up

by Gene

I was having similar problems with the calendar not showing up. I figured out that when I updated my super_calendar.js file I changed the URL variable to include the full path. This caused the calendar to not show up if I typed my domain with the www in front of the domain name.

I went back and fixed the URL variable to use the following: var url = "/calendar/super_calendar.php?month="+month+"&year="+year+"&event="+evt;


answer for what is the problem

by SLY

I found that instead of this

<link rel="stylesheet" type="text/css" href="/calendar/super_calendar_style.css" />

<script type="text/javascript" src="/calendar/super_calendar.js"></script>

I had to change it to

<link rel="stylesheet" type="text/css" href="calendar/super_calendar_style.css" />

<script type="text/javascript" src="calendar/super_calendar.js"></script>

removing the / in the link.

Hope that fixes it for you


Closing browser dose not log me out

by SLY

First off let me say thanks for the scripts, great work..

1 thing I have found is that I am not logged out of the admin section when I close my browser, i can open a new browser and im still logged in ?

Cheers SLY


Event name instead of event

by SLY

Someone has alreay posted it b4, I think it would be a good idea

Is it possible to replace the Event on the main calendar with title of the actual event?

Cheer SLY


begin week in Monday

by Manolo

Just use

$start = $date['wday'];

instead of

$start = $date['wday'] +1;

in super_calendar.php


xml has no properties

by Gordon

I installed survey as instructed, but all I get is the rotating timer. The error cousole in Firefox gives an error: xml has no properties.

The error occurs on the last line of the following code. I'm at a loss, any help is appreciated.

function receiveSurvey() { if(req.readyState == 4) { var output = ''; var xml = req.responseXML; var typ = xml.documentElement.getAttribute('type');


xml has no properties

by Gordon

Just wanted to add that the database connection is working fine. I can use the admin to create a question and view the question in the database via phpMyAdmin.


PHP Version

by Blon

What version of PHP has this been tested with? Cheers.


xml has no properties/PHP Version

by Gordon

php is 5.2.5, complete environment can be seen at http://www.time2scrapbook.com/info.php


Always Get error message : "0" is null or not an object

by Marvel

Hi, this calendar totally GREAT!, i like it so much.

It's just i still couldn't run it on my computer, i already follows the instruction carefully and also all the path details and MySQL information, but somehow i'm always get the Error Message:

Line : 21 Char : 3 Error: '0' is null or not an object

I'm totally desperate seeking for this problem, but i suspect the problems came from 'super_calendar.js' files, in the line 21 of this file ther's a code : "getObject("calendar").innerHTML = resp[0].getElementsByTagName("content")[0].childNodes[0].nodeValue;"

could anyone help me what's the problem, the result is my page shown a blank page with the status "Done, but with errors". Well, thank you very much, once again i'd like to say this calendar is GREAT! really god job!


Solved : Always Get error message : \

by Marvel

Hi there,

I finally found the problems why it always shown the error. It caused when the \'resp[0]\' variavble contains \"null\" or it means, the \'resp[0]\' variable doesn\'t get the ressult from database, in my case \"The connection is the Problem\" when the database connection failed, it will then return the \"Null\" value in the responseXML, and finally this responseXML are transfered into XML Nodes by this code <quote>var resp = response.getElementsByTagName(\"response\");</quote> Since the responseXML contains \"Null\" then this code : <quote>getObject(\"calendar\").innerHTML = resp[0].getElementsByTagName(\"content\")[0].childNodes[0].nodeValue;</quote> will generate error when the page loads.

Solution : Check the database connection in the \"super_calendar.php\" line 8-10, make sure you have all the details as in your database. (host, username, password, and also database name). And just make sure about all directory and files placing always update the path in the place you put the files (php files, javascript files and also image). That is and you\'re to go! Nice Web Calendar!

Regards,


ajax survey

by karyurekli

SQL file database to add -Display error messages !!?


re: Solved : Always Get error message : \

by Stuart

Additional note: Depending on your server/PHP settings, you may need to add 'php' after <? to get the server to parse the PHP code. ie. <?php instead of <? for the opening PHP tag. Hope it helps.


Few questions

by Parcheval

Hi!

Thanks a lot for this great calendar!

Just a few questions:

- how to change the start of the week to Monday? The only result I get when modifying $start = $date['wday'] + 1; to $start = $date['wday']; as already posted is to shift the date within the calendar, eg. August 1 moves from Friday to Thursday. Any other possibility so that it starts on Monday?

- would it be possible to display something else instead of "Event" and/or to change the background colors of the day of the event?

Thanks in advance!


help

by earl

whats d username and pword of the admin? where can i see the calendar? theres no file stating that theres an html to view the calendar...msg me pls at kingdom_g123@yahoo.com


Database connection failed.

by Jeff

I keep getting this error when trying to use the calendar, the Admin section is working just fine, and I am able to post events. However when I try and load the calendar, I get a 'Database Connection Failed' error.

I have checked and re-checked ALL my settings and it is not working. The Admin section dbhost, dbuser, dbpass are the same, and my mySQL server is up and running. I have also given it the correct Database as well.


post comment Post a Comment
Name:
Heading:
Comments:
(BBCode OK)
Captcha Image:captcha
Characters: