Extension talk:SimpleCalendar

Source code displaying on page
This extension is not working for me. When enabled, all code from the script starting from "setFunctionHook" to the end is displayed at the top of my Main Page. Any ideas? Thanks. --Joshuaholland 20:57, 30 April 2007 (UTC)
 * The script being displayed in the output page usually means that the php opening delimeter (&lt;?) is missing. --Nad 22:23, 30 April 2007 (UTC)
 * I have the opening delimiter (&lt;?) there, and it is interesting that the code desplayed on the Main Page starts at setFunctionHook and not at the beginning of the script, which is what you think would happen if the &lt;? was missing. Josh 00:45, 1 May 2007 (UTC)
 * Hmmm that's pretty weird alright, what's the way you've included it into localsettings? is it pasted directly in, or included as a file? are other extensions working? --Nad 01:47, 1 May 2007 (UTC)
 * That character before setFunctionHook is a "&gt;", so my guess is that you've pasted the code directly into LocalSettings rather than including from file, and therefore there should be no delimeters since it's already in php context (it would make the opening delimeter a tag which would close when it got to the &gt; before the setFunctionHook) - just a guess tho ;-) --Nad 01:50, 1 May 2007 (UTC)
 * Okay, I just made it <?php and then it worked... Josh 02:43, 1 May 2007 (UTC)
 * Cool, ok I guess I should really make the tags like that for everything. --Nad 02:55, 1 May 2007 (UTC)

Could I create tasks whose title have some variables

 * I want to create some tasks with titles like "Michael's log 2007_05_01" instead of ""Michael's log 2007_05_01_01_MAY_2007" by using ( and "&preload=Template:Michael's log", any ideas? Thinks!--Roc michael 12:59, 1 May 2007 (UTC)
 * I'm not sure completely what you mean, but the query-string bit is a good idea which I've just added. I've changed to named parameters now instead of an ordered list, and added a new query parameter which allows query-string items to be added to the newly created dates. --Nad 23:45, 1 May 2007 (UTC)
 * Hi, Thank you very much! How wonderful it is that we can use peload parameter on the Calendar. I am Chinese in Taiwan and I want to use this extension and DPL in my wiki located in a intranet. So the people here would more like to use the date form of task title like "2007/05/02" than "02/May/2007" or "2007/May/02". I guess that Japanese people may think so. So if we can choose which date form we can use that will be a nice thing. Thank you!--Roc michael 15:00, 2 May 2007 (UTC)
 * I added another parameter called format, you can change to the format you asked for of 2007/05/02 with the following,
 *  
 * Thank you, Nad. I appreciate you for what you did.--Roc michael 13:35, 3 May 2007 (UTC)

Adding a prefix to day links?
$table .= "|$t|$day\n";" and mostly it works, but it seems there should be a more elegant way. Also, this makes the subpage have a colon instead of a slash before it, which is what I want. Thanks. Josh 14:15, 2 May 2007 (UTC)
 * Can the variable $prefix be used like this? I'd like the days to link to a page in the current namespace and subpage.  I tried giving it a value to $prefix but that didn't work.  I was able to code it into this line
 * Actually, I got the formatting to work right, but still wondering if there is a better way for me to code it. Thanks.  Josh 17:00, 2 May 2007 (UTC)
 * I think putting mediawiki-variables in the code like that would just hardwire them into the code when its saved, they wouldn't be dynamic. You can add dynamic prefixes like this:
 *  

Could it be possible that this great calendar could get a new face with a parameter?
When I displayed this great calendar with dpl some people marvel at the wonderful result of the two extensions. But since I've used another calendar (User:Hex2bit/Calendar), some body used to using it. If Simple Calendar could get a new face with a parameter, I think it will be a nice thing. Nad, I believe that you can make it be possible to find a way to Integrate them, right? :-) --Roc michael 01:21, 8 May 2007 (UTC)
 * Not sure about that, you'll need to explain in more detail what you're wanting to be done... do you mean a skin? It defines all its parts with CSS classes so you can change the look of it easily. --Nad 04:00, 8 May 2007 (UTC)


 * Yes, Some people like the interface of calendar (User:Hex2bit/Calendar). It can be used to show which members in a department on duty at each day. But unfortunately, It cannot generate articles with custom-made titles. Especially,something like "2007/05/07". Nowadays, it can only use like "2007/5/7" to be a title of an article and it disadvantage working with DPL to list all the events. On the other hand, Simple Calendar is a Parser function extension. So it well be more useful than other calendar extensions.
 * The skin of Simple Calendar is good for some of my coworkers, but others prefer the one which User:Hex2bit/Calendar used ,particularly, to be used for a public calendar.
 * Nad, sorry, I am not a programer, :-( I can only use a few CAD softwares and edit some simple web pages with Dreamweaver. I very like Mediawiki, because it is powerful, useful and has countless advanced programers 'like you' to improve itself. So please do me a favor, Nad.--Roc michael 13:01, 8 May 2007 (UTC)

Could I use the functions preload and format in the same time
Nad, if I use the preload function, it seems that I cannot use the format function which like the followed all together.

Could you give me a hand?--Roc michael 16:04, 8 May 2007 (UTC)
 * Use pipes to separate the parameters in a parser-function or template, eg:


 * Thank you! Nad.--Roc michael 11:27, 9 May 2007 (UTC)

Wrong link colouring
I've just installed the new version of the calendar and I have a problem... All the links (dates) are external links: http://img260.imageshack.us/img260/2333/sanstitrets6.png And I still have the problem of the language... I don't have access to the configuration server. YeTi 20:39, 3 May 2007 (NZST)
 * I'm experiencing this same issue. Anybody find a resolution? Jaofos 05:06, 30 May 2007 (NZST)
 * Did you add the CSS rule #bodyContent table.month a { background:none; padding:0 }? that makes the links plain --Nad 08:47, 30 May 2007 (NZST)
 * Yes, I figured out afterwards to add the styles for the calendar and everything works great. I have, however, run into another issue where after you add entries for a calendar day, the link will not change to indicate an existing entry for that day until after you edit and save the page with the  tag. Jaofos 02:59, 12 June 2007 (NZST)
 * I've tried adding a line into the code to disable the caching for calendar tables, but your problem doesn't happen on our wiki's, so I can't test it, give it a go now and see if it works any better --Nad 22:28, 11 June 2007 (UTC)

Other languages
Hi, a few questions:
 * How can I put the calendar in another language, for example french (january = janvier, etc...)?
 * I changed it slightly to work with locales, so download again from MW:Extension:Simple Calendar, and then set the PHP locale in LocalSettings.php with the following (the locale's must be configured on the server properly),
 * setlocale(LC_ALL,'fr_FR','fr','FR','french','fra','france','French','fr_FR.ISO8859-1');
 * if that doesn't work, use locale -a from your server's shell to see what local's are available.


 * In which file do I have to put the CSS code, knowing that I use the Monobook skin? --YeTi 19:58, 1 May 2007 (NZST)
 * You can add it to your MediaWiki:Monobook.css file, see our MediaWiki:Wikiskin.css for example. --Nad 21:08, 1 May 2007 (NZST)

Links showing up as external
I've just installed the new version of the calendar and I have a problem... All the links (dates) are external links: http://img260.imageshack.us/img260/2333/sanstitrets6.png And I still have the problem of the language... I don't have access to the configuration server. YeTi 20:39, 3 May 2007 (NZST)
 * I'm experiencing this same issue. Anybody find a resolution? Jaofos 05:06, 30 May 2007 (NZST)
 * Did you add the CSS rule #bodyContent table.month a { background:none; padding:0 }? that makes the links plain --Nad 08:47, 30 May 2007 (NZST)
 * Yes, I figured out afterwards to add the styles for the calendar and everything works great.

Link colour not changing to indicate newly created entry
I have, however, run into another issue where after you add entries for a calendar day, the link will not change to indicate an existing entry for that day until after you edit and save the page with the tag. Jaofos 02:59, 12 June 2007 (NZST)
 * I've tried adding a line into the code to disable the caching for calendar tables, but your problem doesn't happen on our wiki's, so I can't test it, give it a go now and see if it works any better --Nad 22:28, 11 June 2007 (UTC)
 * Seems to be working now, thanks! --Jaofos 02:37, 13 June 2007 (NZST)