phpgroupware-developers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Phpgroupware-developers] jsCalendar popup for phpGW


From: Ralf Becker
Subject: [Phpgroupware-developers] jsCalendar popup for phpGW
Date: Mon, 18 Aug 2003 23:13:53 +0200
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.4) Gecko/20030626

Hi all,

I imported the jsCalendar (http://dynarch.com/mishoo/calendar.epl) popup into the API. It allows to select a date from a small popup calendar (works in IE >= 5.0, Mozilla, Opera 7, other browser can use the normal input-field).

I imported the jsCalendar Version 0.9.3 unchanged into the API (for easier updateing later) and programmed a wrapper class to use it easily within phpGW:

$jscal = CreateObject('phpgwapi.jscalendar'); // before the phpgw_header call, as it inserts the necessary javascript and css-files into the page-header

echo $jscal->input('startdate',$starttime);

or

echo $jscal->input('startdate','',$year,$month,$day);

There a also a function to convert the date-string back into a timestamp or an array with year/month/day.

The wrapper-class loads the javascript file jscalendar-setup.php, which pulls the date-format and language out of the user prefs and loads the necessary translations from the db, no extra configuration and translation is needed.

You can test it (after updateing your .16 install) in calendar/edit. I will implement it soon in InfoLog (eTemplate) and other apps.

Ralf

PS.: From the same developer is HTMLarea (richtext editor) and a very nice menu-system, which might be interesting for the idots sidebox-menu.
--
----------------------------------------------------------------------
Ralf Becker
OUTDOOR UNLIMITED Training GmbH                Telefon 0631 / 31657-0
Leibnizstraße 17                               Telefax 0631 / 31657-26
D-67663 Kaiserslautern            EMail address@hidden





reply via email to

[Prev in Thread] Current Thread [Next in Thread]