New Calendar Mod: QCalendar with Ajax [Updated v1.0.8]

Post custom hacks and enhancements for phpwcms here only. Maybe some of these things will be included in official release later.
daniel.grant
Posts: 97
Joined: Thu 2. Nov 2006, 15:42
Location: London

Re: New Calendar Mod: QCalendar with Ajax [Updated v1.0.7]

Post by daniel.grant »

Sorted. Didn't have qcal.php in the root dir - how did I not notice that!? Oh well, all's well that ends well.
culda_a
Posts: 521
Joined: Tue 28. Feb 2006, 01:39
Contact:

Re: New Calendar Mod: QCalendar with Ajax [Updated v1.0.7]

Post by culda_a »

Hy daniel, I have qcall file on the root I will post a image to see how it looks the backend:


You see the functions is missing any sugestions? I use shapshot of the version 1.3.5 phpwcms
Last edited by culda_a on Thu 14. May 2009, 16:18, edited 2 times in total.
ImagePackging design,labels, catalogs,postcards,
JensZ
Posts: 136
Joined: Wed 16. Feb 2005, 12:18
Location: Stockholm, Sweden
Contact:

Re: New Calendar Mod: QCalendar with Ajax [Updated v1.0.7]

Post by JensZ »

What language is your user using? Try by setting your user language to english.

If it works, try creating a new directory with your user language iso code, for example 'es' for Spain, and copy lang.inc.php from another language dir into the new dir.

Jens
culda_a
Posts: 521
Joined: Tue 28. Feb 2006, 01:39
Contact:

Re: New Calendar Mod: QCalendar with Ajax [Updated v1.0.7]

Post by culda_a »

is set to english
ImagePackging design,labels, catalogs,postcards,
JensZ
Posts: 136
Joined: Wed 16. Feb 2005, 12:18
Location: Stockholm, Sweden
Contact:

Re: New Calendar Mod: QCalendar with Ajax [Updated v1.0.7]

Post by JensZ »

Ok, try this:

Replace in backend.inc.php AND default.tmpl.php:

Code: Select all

echo renderQCal($GLOBALS["qcal"]["defaults"]["calendar"], $_SESSION["wcs_user_lang"]);
With this:

Code: Select all

$userLang = (isset($_SESSION["wcs_user_lang"]) && !empty($_SESSION["wcs_user_lang"])) ? $_SESSION["wcs_user_lang"] : "en"; 
echo renderQCal($GLOBALS["qcal"]["defaults"]["calendar"], $userLang);
If it doesn't work, try:

Code: Select all

$userLang = "en"; 
echo renderQCal($GLOBALS["qcal"]["defaults"]["calendar"], $userLang);
culda_a
Posts: 521
Joined: Tue 28. Feb 2006, 01:39
Contact:

Re: New Calendar Mod: QCalendar with Ajax [Updated v1.0.7]

Post by culda_a »

thanks a lot, that have solved my problem
ImagePackging design,labels, catalogs,postcards,
headless
Posts: 15
Joined: Wed 12. Apr 2006, 04:27
Contact:

Re: New Calendar Mod: QCalendar with Ajax [Updated v1.0.7]

Post by headless »

Can somebody help me.

How can I create these buttons, to jump between the month?
Image
THX!

Wie kann ich diese Buttons erstellen, um zwischen den Monaten hin- und herzuspringen

Danke
JensZ
Posts: 136
Joined: Wed 16. Feb 2005, 12:18
Location: Stockholm, Sweden
Contact:

Re: New Calendar Mod: QCalendar with Ajax [Updated v1.0.7]

Post by JensZ »

New version 1.0.8 with the month navigation above.

Download here

//Jens
Hoskissonite
Posts: 7
Joined: Thu 7. Feb 2008, 16:55

Re: New Calendar Mod: QCalendar with Ajax [Updated v1.0.8]

Post by Hoskissonite »

Thanks for a great module, Jens!

I have one question, however: The calender I've implemented is supposed to be in Swedish. I've set the language settings in the module's conf.inc.php to "se". But in the backend and frontend, the Swedish characters, åäö, are replaced by a question-mark, "?".

My conf.inc.php for phpwCMS is set to:
$phpwcms['db_charset'] = 'utf8';
$phpwcms['db_collation'] = 'utf8_swedish_ci';
Could this be part of the problem?
JensZ
Posts: 136
Joined: Wed 16. Feb 2005, 12:18
Location: Stockholm, Sweden
Contact:

Re: New Calendar Mod: QCalendar with Ajax [Updated v1.0.8]

Post by JensZ »

I don't think it has to do with the db collation, however, check your $phpwcms["charset"]. Mine is set to "UTF-8". Hopefully it doesn't screw up the rest of the website. Best practice is to have the same encoding as your DB.

If that doesn't work, try changing your browser's encoding setting. In FF, View > Character Encoding.

Cheers
User avatar
santscho
Posts: 1442
Joined: Mon 2. Apr 2007, 08:56
Location: Schweiz

Re: New Calendar Mod: QCalendar with Ajax [Updated v1.0.8]

Post by santscho »

After upgrading the FCKeditor (Last Snapshot), I get this message when I want to mod./create a new calendar entry:

Code: Select all

Fatal error: Call to undefined function: fckeditor_iscompatiblebrowser() in /home/redcross/htdocs/include/inc_ext/fckeditor/fckeditor_php4.php on line 110
And the other problem: In Frontend, the Pop-Up for the Events is not in English: (Datum: Tid: Plats:). Where can I change this?

Thanks for helping! Ralph
Schon Konfuzius sagte: "Sei kein YAML-Lappen". YAML-phpwcms-Integration auf http://www.yaml.phpwcms.org
User avatar
Dan-G
Posts: 50
Joined: Fri 11. Apr 2008, 12:14

Re: New Calendar Mod: QCalendar with Ajax [Updated v1.0.8]

Post by Dan-G »

I implemented this calendar on one of my sites a while ago (using {EVENTS} listing) but since then the client has complained that at the end of the month the calendar only show events from the month they're currently in.

So for example on 29th April there are no events listed for the first week of May.

Hmmm... good point - that's a pretty useless calendar if it only shows events for the next 2 days. They're not keen on the year calendar so...

Does anyone have any idea how I make this display 2 months rather than just one?
User avatar
Dan-G
Posts: 50
Joined: Fri 11. Apr 2008, 12:14

Re: New Calendar Mod: QCalendar with Ajax [Updated v1.0.8]

Post by Dan-G »

:oops: just noticed changes in v1.08 to solve my issue

but - I click the link {PREVMONTH} or {NEXTMONTH} and the calendar totally dissappears
User avatar
Dan-G
Posts: 50
Joined: Fri 11. Apr 2008, 12:14

Re: New Calendar Mod: QCalendar with Ajax [Updated v1.0.8]

Post by Dan-G »

okay so having a look at this new release. aside from the initial problem of an error in the backend which goes away by editing inc_module/mod_qcal/inc_lib/QCalendarAdmin.php line 114

<th class='qheader'><a href=\"javascript:;\" onclick=\"displayQCalendar('$nextMonth','$lYear','".$GLOBALS['qcal']['ajaxAdminPath']."',".$this->category.", true,'".$this->langId."','".$this->css."')\" class='qheaderNav' title='".htmlentities(substr($this->monthNames[$nextMonth-1]), 0, 3)."'>></a>&nbsp;</th>

change to:

Code: Select all

<th class='qheader'><a href=\"javascript:;\" onclick=\"displayQCalendar('$nextMonth','$lYear','".$GLOBALS['qcal']['ajaxAdminPath']."',".$this->category.", true,'".$this->langId."','".$this->css."')\" class='qheaderNav' title='".htmlentities(substr($this->monthNames[$nextMonth-1], 0, 3))."'>></a>&nbsp;</th>
But I still can't get this pesky next/previous month function to work! A fresh install and still the same issue - click on the < or > links and the event list is replaced with Nothing!

So for now I have put the following in default.cal.tmpl

Code: Select all

<div style="display:none">{MONTH}</div> 
         {EVENTS} 
as the presence of the month calendar seems to allow the {prevmonth} {nextmonth} functions to work.

Maybe I misunderstood some simple thing but this will certainly do...
User avatar
hjb
Posts: 39
Joined: Tue 6. Apr 2004, 13:41
Location: Hamburg/Germany
Contact:

You Cannot Access This Script Directly,

Post by hjb »

Did I miss something, I couldnt find any solution to the eror above?

:mrgreen:

Regards
Man sieht sich immer zweimal im Leben....
Post Reply