Page 1 of 1

Transferring Data into a Sun Java Calendar Server via WCAP

Posted: Fri Jul 08, 2005 9:18 am
by bluenote
Hi there,

i am in some serious trouble :roll:

The last three days, we have installed a Sun Java System Calendar Server. One of the aims was / is to send data from our PHP/MySQL based announcement system - using PHP - via the calendar's WCAP interface to the calendar.

Therefore, the folowing code was written:

Code: Select all

<?php
$user='wkaiser';
$pass='************';
$connection = fopen ("https://calendar.local.de:4433/login.wcap?refresh=1&amp;user=$user&amp;password=$pass&quote;,&quote;r+&quote;);

    if (!$connection) {
       print &quote;&lt;p&gt;Unable to connect to calendar server&lt;p&gt;&quote;;
       exit;
    }
    else {
       print &quote;&lt;p&gt;Connection o.k.&lt;p&gt;&quote;;
    }

    $id = &quote;&quote;;
    while (!feof($connection))
       {
         $currentLine = fgets ($connection, 4096); 
         print &quote;&lt;p&gt;Line: $currentLine&lt;p>";
         if ( ereg("^X-NSCP-WCAP-SESSION-ID:([a-z0-9]*)", $currentLine, $regs) ) {
              $id = $regs[1];
              $socket=fopen (&quote;https://calendar.local.de:4433/storeevents.wcap?id=$id&amp;calid=semA&amp;dtstart=20050708T103000&amp;dtend=20050708T113000&amp;summary=KickOff&quote;,&quote;r+&quote;);
              fclose($socket);
         }
       }
    fclose($connection);

    if ($id == &quote;&quote;) {
       print &quote;Login failed&lt;p&gt;&quote;;
       exit;
    }
    else {
       print &quote;&lt;p&gt;SessionID: $id&lt;p&gt;&quote;;
    }
?&gt;
The connection works, and i also can retrieve data:

Code: Select all

# /usr/local/bin/php connectSSL.php
&lt;p&gt;Connection o.k.&lt;p&gt;<p>Zeile: BEGIN:VCALENDAR
<p><p>Line: PRODID:-//Sun/Calendar Server//EN
<p>&lt;p&gt;Line: METHOD:PUBLISH
<p><p>Line: VERSION:2.0
<p><p>Line: X-NSCP-WCAP-SESSION-ID:be2ow9e5uh2n8ut6
<p><p>Line: X-NSCP-WCAP-USER-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-CALENDAR-ID:wkaiser
<p><p>Line: X-NSCP-WCAP-ERRNO:0
<p><p>Line: END:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: &lt;p&gt;&lt;p&gt;SessionID: be2ow9e5uh2n8ut6&lt;p&gt;
But i just can't write! It should be no rights problem because i am the admin of the calendar server as well as the owner of the calendar i want to write in.

Pastings the URL

https://calendar.local.de:4433/storeeve ... ry=KickOff

into any Web Browsers Address Bar works, the event gets written to the calendar....

Tanks in Advance,
- bluenotepass='************';
$connection = fopen (&quote;https://calendar.local.de:4433/login.wc ... e;r+&quote;);

if (!$connection) {
print &quote;&lt;p&gt;Unable to connect to calendar server&lt;p&gt;&quote;;
exit;
}
else {
print &quote;&lt;p&gt;Connection o.k.&lt;p&gt;&quote;;
}

$id = &quote;&quote;;
while (!feof($connection))
{
$currentLine = fgets ($connection, 4096);
print &quote;&lt;p>Line: $currentLine&lt;p&gt;&quote;;
if ( ereg(&quote;^X-NSCP-WCAP-SESSION-ID:(їa-z0-9]*)&quote;, $currentLine, $regs) ) {
$id = $regsї1];
$socket=fopen (&quote;https://calendar.local.de:4433/storeeve ... e;r+&quote;);
fclose($socket);
}
}
fclose($connection);

if ($id == &quote;&quote;) {
print &quote;Login failed&lt;p&gt;&quote;;
exit;
}
else {
print &quote;&lt;p&gt;SessionID: $id&lt;p&gt;&quote;;
}
?&gt;


The connection works, and i also can retrieve data:

Code: Select all

# /usr/local/bin/php connectSSL.php
&lt;p&gt;Connection o.k.<p><p&gt;Zeile: BEGIN:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: PRODID:-//Sun/Calendar Server//EN
&lt;p&gt;&lt;p&gt;Line: METHOD:PUBLISH
&lt;p&gt;&lt;p&gt;Line: VERSION:2.0
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-SESSION-ID:be2ow9e5uh2n8ut6
<p&gt;&lt;p&gt;Line: X-NSCP-WCAP-USER-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-CALENDAR-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-ERRNO:0
&lt;p&gt;&lt;p&gt;Line: END:VCALENDAR
&lt;p&gt;<p>Line: &lt;p&gt;&lt;p&gt;SessionID: be2ow9e5uh2n8ut6&lt;p&gt;
But i just can't write! It should be no rights problem because i am the admin of the calendar server as well as the owner of the calendar i want to write in.

Pastings the URL

https://calendar.local.de:4433/storeeve ... ry=KickOff

into any Web Browsers Address Bar works, the event gets written to the calendar....

Tanks in Advance,
- bluenotestoreevents.wcap?id=$id&calid=semA&dtstart=20050708T103000&dtend=20050708T113000&summary=KickOff","r+");
fclose($socket);
}
}
fclose($connection);

if ($id == "") {
print "Login failed<p>";
exit;
}
else {
print &quote;&lt;p&gt;SessionID: $id&lt;p&gt;&quote;;
}
?&gt;


The connection works, and i also can retrieve data:

Code: Select all

# /usr/local/bin/php connectSSL.php
&lt;p&gt;Connection o.k.&lt;p&gt;&lt;p&gt;Zeile: BEGIN:VCALENDAR
<p><p>Line: PRODID:-//Sun/Calendar Server//EN
<p><p>Line: METHOD:PUBLISH
<p><p>Line: VERSION:2.0
<p><p>Line: X-NSCP-WCAP-SESSION-ID:be2ow9e5uh2n8ut6
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-USER-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-CALENDAR-ID:wkaiser
&lt;p&gt;<p>Line: X-NSCP-WCAP-ERRNO:0
<p><p>Line: END:VCALENDAR
<p><p>Line: <p><p>SessionID: be2ow9e5uh2n8ut6<p>
But i just can't write! It should be no rights problem because i am the admin of the calendar server as well as the owner of the calendar i want to write in.

Pastings the URL

https://calendar.local.de:4433/storeeve ... ry=KickOff

into any Web Browsers Address Bar works, the event gets written to the calendar....

Tanks in Advance,
- bluenoterom our PHP/MySQL based announcement system - using PHP - via the calendar's WCAP interface to the calendar.

Therefore, the folowing code was written:

Code: Select all

<?php
$user='wkaiser';
$pass='************';
$connection = fopen ("https://calendar.local.de:4433/login.wcap?refresh=1&user=$user&password=$pass","r+");

    if (!$connection) {
       print "<p>Unable to connect to calendar server<p>";
       exit;
    }
    else {
       print "<p>Connection o.k.<p>";
    }

    $id = "";
    while (!feof($connection))
       {
         $currentLine = fgets ($connection, 4096); 
         print "<p>Line: $currentLine<p>";
         if ( ereg("^X-NSCP-WCAP-SESSION-ID:([a-z0-9]*)", $currentLine, $regs) ) {
              $id = $regs[1];
              $socket=fopen ("https://calendar.local.de:4433/storeevents.wcap?id=$id&calid=semA&dtstart=20050708T103000&dtend=20050708T113000&summary=KickOff","r+");
              fclose($socket);
         }
       }
    fclose($connection);

    if ($id == "") {
       print "Login failed<p>";
       exit;
    }
    else {
       print "<p>SessionID: $id<p>";
    }
?>
The connection works, and i also can retrieve data:

Code: Select all

# /usr/local/bin/php connectSSL.php
&lt;p&gt;Connection o.k.&lt;p&gt;&lt;p&gt;Zeile: BEGIN:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: PRODID:-//Sun/Calendar Server//EN
&lt;p&gt;&lt;p&gt;Line: METHOD:PUBLISH
&lt;p&gt;&lt;p&gt;Line: VERSION:2.0
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-SESSION-ID:be2ow9e5uh2n8ut6
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-USER-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-CALENDAR-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-ERRNO:0
&lt;p&gt;&lt;p&gt;Line: END:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: &lt;p&gt;&lt;p&gt;SessionID: be2ow9e5uh2n8ut6&lt;p&gt;
But i just can't write! It should be no rights problem because i am the admin of the calendar server as well as the owner of the calendar i want to write in.

Pastings the URL

https://calendar.local.de:4433/storeeve ... ry=KickOff

into any Web Browsers Address Bar works, the event gets written to the calendar....mp;amp;lt;?php
$user='wkaiser';
$pass='************';
$connection = fopen ("https://calendar.local.de:4433/login.wc ... =$pass","r+");

if (!$connection) {
print "<p>Unable to connect to calendar server<p>";
exit;
}
else {
print "&lt;p&gt;Connection o.k.&lt;p&gt;&quote;;
}

$id = &quote;&quote;;
while (!feof($connection))
{
$currentLine = fgets ($connection, 4096);
print &quote;&lt;p&gt;Line: $currentLine&lt;p&gt;&quote;;
if ( ereg(&quote;^X-NSCP-WCAP-SESSION-ID:(їa-z0-9]*)&quote;, $currentLine, $regs) ) {
$id = $regsї1];
$socket=fopen (&quote;https://calendar.local.de:4433/storeeve ... e;r+&quote;);
fclose($socket);
}
}
fclose($connection);

if ($id == &quote;&quote;) {
print &quote;Login failed&lt;p&gt;&quote;;
exit;
}
else {
print &quote;&lt;p&gt;SessionID: $id&lt;p&gt;&quote;;
}
?&gt;


The connection works, and i also can retrieve data:

Code: Select all

# /usr/local/bin/php connectSSL.php
&lt;p&gt;Connection o.k.&lt;p&gt;&lt;p&gt;Zeile: BEGIN:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: PRODID:-//Sun/Calendar Server//EN
&lt;p&gt;&lt;p&gt;Line: METHOD:PUBLISH
&lt;p&gt;&lt;p&gt;Line: VERSION:2.0
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-SESSION-ID:be2ow9e5uh2n8ut6
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-USER-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-CALENDAR-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-ERRNO:0
&lt;p&gt;&lt;p&gt;Line: END:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: &lt;p&gt;&lt;p&gt;SessionID: be2ow9e5uh2n8ut6&lt;p&gt;
But i just can't write! It should be no rights problem because i am the admin of the calendar server as well as the owner of the endar.local.de:4433/login.wcap?refresh=1&user=$user&password=$pass","r+");

if (!$connection) {
print "<p>Unable to connect to calendar server<p>";
exit;
}
else {
print "<p>Connection o.k.<p>";
}

$id = "";
while (!feof($connection))
{
$currentLine = fgets ($connection, 4096);
print &quote;&lt;p&gt;Line: $currentLine&lt;p&gt;&quote;;
if ( ereg(&quote;^X-NSCP-WCAP-SESSION-ID:(їa-z0-9]*)&quote;, $currentLine, $regs) ) {
$id = $regsї1];
$socket=fopen (&quote;https://calendar.local.de:4433/storeeve ... e;r+&quote;);
fclose($socket);
}
}
fclose($connection);

if ($id == &quote;&quote;) {
print &quote;Login failed&lt;p&gt;&quote;;
exit;
}
else {
print &quote;&lt;p&gt;SessionID: $id&lt;p&gt;&quote;;
}
?&gt;


The connection works, and i also can retrieve data:

Code: Select all

# /usr/local/bin/php connectSSL.php
&lt;p&gt;Connection o.k.&lt;p&gt;&lt;p&gt;Zeile: BEGIN:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: PRODID:-//Sun/Calendar Server//EN
&lt;p&gt;&lt;p&gt;Line: METHOD:PUBLISH
&lt;p&gt;&lt;p&gt;Line: VERSION:2.0
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-SESSION-ID:be2ow9e5uh2n8ut6
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-USER-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-CALENDAR-ID:wstalled a Sun Java System Calendar Server. One of the aims was / is to send data from our PHP/MySQL based announcement system - using PHP - via the calendar's WCAP interface to the calendar.

Therefore, the folowing code was written:

[php]
<?php
$user='wkaiser';
$pass='************';
$connection = fopen ("https://calendar.local.de:4433/login.wcap?refresh=1&user=$user&password=$pass","r+");

    if (!$connection) {
       print "<p>Unable to connect to calendar server<p>";
       exit;
    }
    else {
       print "<p>Connection o.k.<p>";
    }

    $id = "";
    while (!feof($connection))
       {
         $currentLine = fgets ($connection, 4096); 
         print "<p>Line: $currentLine<p>";
         if ( ereg("^X-NSCP-WCAP-SESSION-ID:([a-z0-9]*)", $currentLine, $regs) ) {
              $id = $regs[1];
              $socket=fopen ("https://calendar.local.de:4433/storeevents.wcap?id=$id&calid=semA&dtstart=20050708T103000&dtend=20050708T113000&summary=KickOff","r+");
              fclose($socket);
         }
       }
    fclose($connection);

    if ($id == "") {
       print "Login failed<p>";
       exit;
    }
    else {
       print "<p>SessionID: $id<p>";
    }
?>
[/php]

The connection works, and i also can retrieve data:

[code]
# /usr/local/bin/php connectSSL.php
&lt;p&gt;Connection o.k.&lt;p&gt;&lt;p&gt;Zeile: BEGIN:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: PRODID:-//Sun/Calendar Server//EN
&lt;p&gt;&lt;p&gt;Line: METHOD:PUBLISH
&lt;p&gt;&lt;p&gt;Line: VERSION:2.0
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-SESSION-ID:be2ow9e5uh2n8ut6
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-USER-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-CALENDAR-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-ERRNO:0
&lt;p&gt;&lt;p&gt;Line: END:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: &lt;p&gt;&lt;p&gt;SessionID: be2ow9e5uh2n8ut6&lt;p&gt;
[/code]

But i just can't write! It should be no rights problem because i am the admin of the calendar server as well as the owner of the calendar i want to write in.

Pastin some serious trouble  :roll: 

The last three days, we have installed a Sun Java System Calendar Server. One of the aims was / is to send data from our PHP/MySQL based announcement system - using PHP - via the calendar's WCAP interface to the calendar.

Therefore, the folowing code was written:

[php]
<?php
$user='wkaiser';
$pass='************';
$connection = fopen ("https://calendar.local.de:4433/login.wcap?refresh=1&user=$user&password=$pass","r+");

    if (!$connection) {
       print "<p>Unable to connect to calendar server<p>";
       exit;
    }
    else {
       print "<p>Connection o.k.<p>";
    }

    $id = "";
    while (!feof($connection))
       {
         $currentLine = fgets ($connection, 4096); 
         print "<p>Line: $currentLine<p>";
         if ( ereg("^X-NSCP-WCAP-SESSION-ID:([a-z0-9]*)", $currentLine, $regs) ) {
              $id = $regs[1];
              $socket=fopen ("https://calendar.local.de:4433/storeevents.wcap?id=$id&calid=semA&dtstart=20050708T103000&dtend=20050708T113000&summary=KickOff","r+");
              fclose($socket);
         }
       }
    fclose($connection);

    if ($id == "") {
       print "Login failed<p>";
       exit;
    }
    else {
       print "<p>SessionID: $id<p>";
    }
?>
[/php]

The connection works, and i also can retrieve data:

[code]
# /usr/local/bin/php connectSSL.php
&lt;p&gt;Connection o.k.&lt;p&gt;&lt;p&gt;Zeile: BEGIN:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: PRODID:-//Sun/Calendar Server//EN
&lt;p&gt;&lt;p&gt;Line: METHOD:PUBLISH
&lt;p&gt;&lt;p&gt;Line: VERSION:2.0
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-SESSIONms was / is to send data from our PHP/MySQL based announcement system - using PHP - via the calendar's WCAP interface to the calendar.

Therefore, the folowing code was written:

[php]
<?php
$user='wkaiser';
$pass='************';
$connection = fopen ("https://calendar.local.de:4433/login.wcap?refresh=1&user=$user&password=$pass","r+");

    if (!$connection) {
       print "<p>Unable to connect to calendar server<p>";
       exit;
    }
    else {
       print "<p>Connection o.k.<p>";
    }

    $id = "";
    while (!feof($connection))
       {
         $currentLine = fgets ($connection, 4096); 
         print "<p>Line: $currentLine<p>";
         if ( ereg("^X-NSCP-WCAP-SESSION-ID:([a-z0-9]*)", $currentLine, $regs) ) {
              $id = $regs[1];
              $socket=fopen ("https://calendar.local.de:4433/storeevents.wcap?id=$id&calid=semA&dtstart=20050708T103000&dtend=20050708T113000&summary=KickOff","r+");
              fclose($socket);
         }
       }
    fclose($connection);

    if ($id == "") {
       print "Login failed<p>";
       exit;
    }
    else {
       print "<p>SessionID: $id<p>";
    }
?>
[/php]

The connection works, and i also can retrieve data:

[code]
# /usr/local/bin/php connectSSL.php
&lt;p&gt;Connection o.k.&lt;p&gt;&lt;p&gt;Zeile: BEGIN:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: PRODID:-//Sun/Calendar Server//EN
&lt;p&gt;&lt;p&gt;Line: METHOD:PUBLISH
&lt;p&gt;&lt;p&gt;Line: VERSION:2.0
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-SESSION-ID:be2ow9e5uh2n8ut6
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-USER-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-CALENDAR-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-ERRNO:0
&lt;p&gt;&lt;p&gt;Line: END:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: &lt;p&gt;&lt;p&gt;SessionID: be2ow9e5uh2n8ut6&lt;p&gt;
[/code]

But i just can't write! It should be no rights problem because i am the admin of the calendar server as well as the owner of the calendar i want to write in.

Pastings the URL 

[url]he calendar's WCAP interface to the calendar.

Therefore, the folowing code was written:

[php]
<?php
$user='wkaiser';
$pass='************';
$connection = fopen ("https://calendar.local.de:4433/login.wcap?refresh=1&user=$user&password=$pass","r+");

    if (!$connection) {
       print "<p>Unable to connect to calendar server<p>";
       exit;
    }
    else {
       print "<p>Connection o.k.<p>";
    }

    $id = "";
    while (!feof($connection))
       {
         $currentLine = fgets ($connection, 4096); 
         print "<p>Line: $currentLine<p>";
         if ( ereg("^X-NSCP-WCAP-SESSION-ID:([a-z0-9]*)", $currentLine, $regs) ) {
              $id = $regs[1];
              $socket=fopen ("https://calendar.local.de:4433/storeevents.wcap?id=$id&calid=semA&dtstart=20050708T103000&dtend=20050708T113000&summary=KickOff","r+");
              fclose($socket);
         }
       }
    fclose($connection);

    if ($id == "") {
       print "Login failed<p>";
       exit;
    }
    else {
       print "<p>SessionID: $id<p>";
    }
?>
[/php]

The connection works, and i also can retrieve data:

[code]
# /usr/local/bin/php connectSSL.php
&lt;p&gt;Connection o.k.&lt;p&gt;&lt;p&gt;Zeile: BEGIN:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: PRODID:-//Sun/Calendar Server//EN
&lt;p&gt;&lt;p&gt;Line: METHOD:PUBLISH
&lt;p&gt;&lt;p&gt;Line: VERSION:2.0
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-SESSION-ID:be2ow9e5uh2n8ut6
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-USER-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-CALENDAR-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-ERRNO:0
&lt;p&gt;&lt;p&gt;Line: END:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: &lt;p&gt;&lt;p&gt;SessionID: be2ow9e5uh2n8ut6&lt;p&gt;
[/code]

But i just can't write! It should be no rights problem because i am the admin of the calendar server as well as the owner of the calendar i want to write in.

Pastings the URL 

[url]https://calendar.local.de:4433/storeevents.wcap?id=$id& the aims was / is to send data from our PHP/MySQL based announcement system - using PHP - via the calendar's WCAP interface to the calendar.

Therefore, the folowing code was written:

[php]
<?php
$user='wkaiser';
$pass='************';
$connection = fopen ("https://calendar.local.de:4433/login.wcap?refresh=1&user=$user&password=$pass","r+");

    if (!$connection) {
       print "<p>Unable to connect to calendar server<p>";
       exit;
    }
    else {
       print "<p>Connection o.k.<p>";
    }

    $id = "";
    while (!feof($connection))
       {
         $currentLine = fgets ($connection, 4096); 
         print "<p>Line: $currentLine<p>";
         if ( ereg("^X-NSCP-WCAP-SESSION-ID:([a-z0-9]*)", $currentLine, $regs) ) {
              $id = $regs[1];
              $socket=fopen ("https://calendar.local.de:4433/storeevents.wcap?id=$id&calid=semA&dtstart=20050708T103000&dtend=20050708T113000&summary=KickOff","r+");
              fclose($socket);
         }
       }
    fclose($connection);

    if ($id == "") {
       print "Login failed<p>";
       exit;
    }
    else {
       print "<p>SessionID: $id<p>";
    }
?>
[/php]

The connection works, and i also can retrieve data:

[code]
# /usr/local/bin/php connectSSL.php
&lt;p&gt;Connection o.k.&lt;p&gt;&lt;p&gt;Zeile: BEGIN:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: PRODID:-//Sun/Calendar Server//EN
&lt;p&gt;&lt;p&gt;Line: METHOD:PUBLISH
&lt;p&gt;&lt;p&gt;Line: VERSION:2.0
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-SESSION-ID:be2ow9e5uh2n8ut6
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-USER-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-CALENDAR-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-ERRNO:0
&lt;p&gt;&lt;p&gaims was / is to send data from our PHP/MySQL based announcement system - using PHP - via the calendar's WCAP interface to the calendar.

Therefore, the folowing code was written:

[php]
<?php
$user='wkaiser';
$pass='************';
$connection = fopen ("https://calendar.local.de:4433/login.wcap?refresh=1&user=$user&password=$pass","r+");

    if (!$connection) {
       print "<p>Unable to connect to calendar server<p>";
       exit;
    }
    else {
       print "<p>Connection o.k.<p>";
    }

    $id = "";
    while (!feof($connection))
       {
         $currentLine = fgets ($connection, 4096); 
         print "<p>Line: $currentLine<p>";
         if ( ereg("^X-NSCP-WCAP-SESSION-ID:([a-z0-9]*)", $currentLine, $regs) ) {
              $id = $regs[1];
              $socket=fopen ("https://calendar.local.de:4433/storeevents.wcap?id=$id&calid=semA&dtstart=20050708T103000&dtend=20050708T113000&summary=KickOff","r+");
              fclose($socket);
         }
       }
    fclose($connection);

    if ($id == "") {
       print "Login failed<p>";
       exit;
    }
    else {
       print "<p>SessionID: $id<p>";
    }
?>
[/php]

The connection works, and i also can retrieve data:

[code]
# /usr/local/bin/php connectSSL.php
&lt;p&gt;Connection o.k.&lt;p&gt;&lt;p&gt;Zeile: BEGIN:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: PRODID:-//Sun/Calendar Server//EN
&lt;p&gt;&lt;p&gt;Line: METHOD:PUBLISH
&lt;p&gt;&lt;p&gt;Line: VERSION:2.0
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-SESSION-ID:be2ow9e5uh2n8ut6
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-USER-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-CALENDAR-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-ERRNO:0
&lt;p&gt;&lt;p&gt;Line: END:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: &lt;p&gt;&lt;p&gt;SessionID: be2ow9e5uh2n8ut6&lt;p&gt;
[/code]

But i just can't write! It should be no rights problem because i am the admin of the calendar server as well as the owner of the calendar i want to write in.

Pastings the URL 

[url]https://calendar.local.de:4433/storeevents.wcap?id=$id&calid=semA&dtstart=20050708T103000&dtend=20050708T113000&https://calendar.local.de:4433/login.wcap?refresh=1&user=$user&password=$pass","r+");

    if (!$connection) {
       print "<p>Unable to connect to calendar server<p>";
       exit;
    }
    else {
       print "<p>Connection o.k.<p>";
    }

    $id = "";
    while (!feof($connection))
       {
         $currentLine = fgets ($connection, 4096); 
         print "<p>Line: $currentLine<p>";
         if ( ereg("^X-NSCP-WCAP-SESSION-ID:([a-z0-9]*)", $currentLine, $regs) ) {
              $id = $regs[1];
              $socket=fopen ("https://calendar.local.de:4433/storeevents.wcap?id=$id&calid=semA&dtstart=20050708T103000&dtend=20050708T113000&summary=KickOff","r+");
              fclose($socket);
         }
       }
    fclose($connection);

    if ($id == "") {
       print "Login failed<p>";
       exit;
    }
    else {
       print "<p>SessionID: $id<p>";
    }
?>
[/php]

The connection works, and i also can retrieve data:

[code]
# /usr/local/bin/php connectSSL.php
<p>Connection o.k.<p><p>Zeile: BEGIN:VCALENDAR
<p><p>Line: PRODID:-//Sun/Calendar Server//EN
<p><p>Line: METHOD:PUBLISH
<p><p>Line: VERSION:2.0
<p><p>Line: X-NSCP-WCAP-SESSION-ID:be2ow9e5uh2n8ut6
<p><p>Line: X-NSCP-WCAP-USER-ID:wkaiser
<p><p>Line: X-NSCP-WCAP-CALENDAR-ID:wkaiser
<p><p>Line: X-NSCP-WCAP-ERRNO:0
<p><p>Line: END:VCALENDAR
<p><p>Line: <p><p>SessionID: be2ow9e5uh2n8ut6<p>
[/code]

But i just can't write! It should be no rights problem because i am the admin of the calendar server as well as the owner of the calendar i want to write in.

Pastings the URL 

[url]https://calendar.local.de:4433/storeevents.wcap?id=$id&calid=semA&dtstart=20050708T103000&dtend=20050708T113000&summary=KickOff[/url]

into any Web Browsers Address Bar works, the event gets written to the calendar....

Tanks in Advance,
- bluenote");

    if (!$connection) {
       print "<p>Unable to connect to calendar server<p>";
       exit;
    }
    else {
       print "<p>Connection o.k.<p>";
    }

    $id = "";
    while (!feof($connection))
       {
         $currentLine = fgets ($connection, 4096); 
         print "<p>Line: $currentLine&lt;p&gt;&quote;;
         if ( ereg(&quote;^X-NSCP-WCAP-SESSION-ID:(&#1111;a-z0-9]*)&quote;, $currentLine, $regs) ) {
              $id = $regs[1];
              $socket=fopen ("https://calendar.local.de:4433/storeevents.wcap?id=$id&calid=semA&dtstart=20050708T103000&dtend=20050708T113000&summary=KickOff","r+");
              fclose($socket);
         }
       }
    fclose($connection);

    if ($id == "") {
       print "Login failed&lt;p&gt;&quote;;
       exit;
    }
    else {
       print &quote;&lt;p&gt;SessionID: $id&lt;p&gt;&quote;;
    }
?&gt;
[/php]

The connection works, and i also can retrieve alendar Server. One of the aims was / is to send data from our PHP/MySQL based announcement system - using PHP - via the calendar's WCAP interface to the calendar.

Therefore, the folowing code was written:

[php]
<?php
$user='wkaiser';
$pass='************';
$connection = fopen ("https://calendar.local.de:4433/login.wcap?refresh=1&user=$user&password=$pass","r+");

    if (!$connection) {
       print "<p>Unable to connect to calendar server<p>";
       exit;
    }
    else {
       print "<p>Connection o.k.<p>";
    }

    $id = "";
    while (!feof($connection))
       {
         $currentLine = fgets ($connection, 4096); 
         print "<p>Line: $currentLine<p>";
         if ( ereg("^X-NSCP-WCAP-SESSION-ID:([a-z0-9]*)", $currentLine, $regs) ) {
              $id = $regs[1];
              $socket=fopen ("https://calendar.local.de:4433/storeevents.wcap?id=$id&calid=semA&dtstart=20050708T103000&dtend=20050708T113000&summary=KickOff","r+");
              fclose($socket);
         }
       }
    fclose($connection);

    if ($id == "") {
       print "Login failed<p>";
       exit;
    }
    else {
       print "<p>SessionID: $id<p>";
    }
?>
[/php]

The connection works, and i also can retrieve data:

[code]
# /usr/local/bin/php connectSSL.php
&lt;p&gt;Connection o.k.&lt;p&gt;&lt;p&gt;Zeile: BEGIN:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: PRODID:-//Sun/Calendar Server//EN
&lt;p&gt;&lt;p&gt;Line: METHOD:PUBLISH
&lt;p&gt;&lt;p&gt;Line: VERSION:2.0
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-SESSION-ID:be2ow9e5uh2n8ut6
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-USER-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-CALENDAR-ID:wkaiser
&lt;p&gt;&lt; three days, we have installed a Sun Java System Calendar Server. One of the aims was / is to send data from our PHP/MySQL based announcement system - using PHP - via the calendar's WCAP interface to the calendar.

Therefore, the folowing code was written:

[php]
<?php
$user='wkaiser';
$pass='************';
$connection = fopen ("https://calendar.local.de:4433/login.wcap?refresh=1&user=$user&password=$pass","r+");

    if (!$connection) {
       print "<p>Unable to connect to calendar server<p>";
       exit;
    }
    else {
       print "<p>Connection o.k.<p>";
    }

    $id = "";
    while (!feof($connection))
       {
         $currentLine = fgets ($connection, 4096); 
         print "<p>Line: $currentLine<p>";
         if ( ereg("^X-NSCP-WCAP-SESSION-ID:([a-z0-9]*)", $currentLine, $regs) ) {
              $id = $regs[1];
              $socket=fopen ("https://calendar.local.de:4433/storeevents.wcap?id=$id&calid=semA&dtstart=20050708T103000&dtend=20050708T113000&summary=KickOff","r+");
              fclose($socket);
         }
       }
    fclose($connection);

    if ($id == "") {
       print "Login failed<p>";
       exit;
    }
    else {
       print "<p>SessionID: $id<p>";
    }
?>
[/php]

The connection works, and i also can retrieve data:

[code]
# /usr/local/bin/php connectSSL.php
&lt;p&gt;Connection o.k.&lt;p&gt;&lt;p&gt;Zeile: BEGIN:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: PRODID:-//Sun/Calendar Server//EN
&lt;p&gt;&lt;p&gt;Line: METHOD:PUBLISH
&lt;p&gt;&lt;p&gt;Line: VERSION:2.0
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-SESSION-ID:be2ow9e5uh2n8ut6
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-USER-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-CALENDAR-ID:wkaiser
&lt;p&gt;&amp/MySQL based announcement system - using PHP - via the calendar's WCAP interface to the calendar.

Therefore, the folowing code was written:

[php]
<?php
$user='wkaiser';
$pass='************';
$connection = fopen ("https://calendar.local.de:4433/login.wcap?refresh=1&user=$user&password=$pass","r+");

    if (!$connection) {
       print "<p>Unable to connect to calendar server<p>";
       exit;
    }
    else {
       print "<p>Connection o.k.<p>";
    }

    $id = "";
    while (!feof($connection))
       {
         $currentLine = fgets ($connection, 4096); 
         print "<p>Line: $currentLine<p>";
         if ( ereg("^X-NSCP-WCAP-SESSION-ID:([a-z0-9]*)", $currentLine, $regs) ) {
              $id = $regs[1];
              $socket=fopen ("https://calendar.local.de:4433/storeevents.wcap?id=$id&calid=semA&dtstart=20050708T103000&dtend=20050708T113000&summary=KickOff","r+");
              fclose($socket);
         }
       }
    fclose($connection);

    if ($id == "") {
       print "Login failed<p>";
       exit;
    }
    else {
       print "<p>SessionID: $id<p>";
    }
?>
[/php]

The connection works, and i also can retrieve data:

[code]
# /usr/local/bin/php connectSSL.php
&lt;p&gt;Connection o.k.&lt;p&gt;&lt;p&gt;Zeile: BEGIN:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: PRODID:-//Sun/Calendar Server//EN
&lt;p&gt;&lt;p&gt;Line: METHOD:PUBLISH
&lt;p&gt;&lt;p&gt;Line: VERSION:2.0
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-SESSION-ID:be2ow9e5uh2n8ut6
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-USER-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-CALENDAR-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-ERRNO:0
&lt;p&gt;&lt;p&gt;Line: END:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: &lt;p&gt;&lt;p&gt;SessionID: be2ow9e5uh2n8ut6&lt;p&gt;
[/code]

But i just can't write! It should be no rights problem because i am the admin of the calendar server as well as the owner of the calendar i want to write in.

Pastings the URL 

[url]https://calendar.local.de:4433/storeevents.wcap?id=$id&calid=semA&dtstart=20050708T103000&dtend=20050708T113000&summary=KickOff[/url]

into any Web Browsers Address Bar works, the event gets writtenfolowing code was written:

[php]
<?php
$user='wkaiser';
$pass='************';
$connection = fopen ("https://calendar.local.de:4433/login.wcap?refresh=1&user=$user&password=$pass","r+");

    if (!$connection) {
       print "<p>Unable to connect to calendar server<p>";
       exit;
    }
    else {
       print "<p>Connection o.k.<p>";
    }

    $id = "";
    while (!feof($connection))
       {
         $currentLine = fgets ($connection, 4096); 
         print "<p>Line: $currentLine<p>";
         if ( ereg("^X-NSCP-WCAP-SESSION-ID:([a-z0-9]*)", $currentLine, $regs) ) {
              $id = $regs[1];
              $socket=fopen ("https://calendar.local.de:4433/storeevents.wcap?id=$id&calid=semA&dtstart=20050708T103000&dtend=20050708T113000&summary=KickOff","r+");
              fclose($socket);
         }
       }
    fclose($connection);

    if ($id == "") {
       print "Login failed<p>";
       exit;
    }
    else {
       print "<p>SessionID: $id<p>";
    }
?>
[/php]

The connection works, and i also can retrieve data:

[code]
# /usr/local/bin/php connectSSL.php
&lt;p&gt;Connection o.k.&lt;p&gt;&lt;p&gt;Zeile: BEGIN:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: PRODID:-//Sun/Calendar Server//EN
&lt;p&gt;&lt;p&gt;Line: METHOD:PUBLISH
&lt;p&gt;&lt;p&gt;Line: VERSION:2.0
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-SESSION-ID:be2ow9e5uh2n8ut6
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-USER-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-CALENDAR-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-ERRNO:0
&lt;p&gt;&lt;p&gt;Line: END:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: &lt;p&gt;&lt;p&gt;SessionID: be2ow9e5uh2n8ut6&lt;p&gt;
[/code]

But i just can't write! It should be no rights problem because i am the admin of the calendar server as well as the owner of the calendar i want to write in.

Pastings the URL 

[url]https://calendar.local.de:4433/storeevents.wcap?id=$id&calid=semA&dtstart=20050708T103000&dtend=20050708T113000&summary=KickOff[/url]

into any Web Browsers ;amp;gt;";
       exit;
    }
    else {
       print "<p>Connection o.k.<p>";
    }

    $id = &quote;&quote;;
    while (!feof($connection))
       {
         $currentLine = fgets ($connection, 4096); 
         print &quote;&lt;p&gt;Line: $currentLine&lt;p&gt;&quote;;
         if ( ereg(&quote;^X-NSCP-WCAP-SESSION-ID:(&#1111;a-z0-9]*)&quote;, $currentLine, $regs) ) {
              $id = $regs&#1111;1];
              $socket=fopen (&quote;https://calendar.local.de:4433/storeevents.wcap?id=$id&amp;calid=semA&amp;dtstart=20050708T103000&amp;dtend=20050708T113000&amp;summary=KickOff&quote;,&quote;r+&quote;);
              fclose($socket);
         }
       }
    fclose($connection);

    if ($id == &quote;&quote;) {
       print &quote;Login failed&lt;p&gt;&quote;;
       exit;
    }
    else {
       print &quote;&lt;p&gt;SessionID: $id&lt;p&gt;&quote;;
    }
?&gt;
[/php]

The connection works, and i also can retrieve data:

[code]
# /usr/local/bin/php connectSSL.php
&lt;p&gt;Connection o.k.&lt;p&gt;&lt;p&gt;Zeile: BEGIN:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: PRODID:-//Sun/Calendar Server//EN
&lt;p&gt;&lt;p&gt;Line: METHOD:PUBLISH
&lt;p&gt;&lt;p&gt;Line: VERSION:2.0
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-SESSION-ID:be2ow9e5uh2n8ut6
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-USER-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-CALENDAR-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-ERRNO:0
&lt;p&gt;&lt;p&gt;Line: END:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: &lt;p&gt;&lt;p&gt;SessionID&&#93;
<?php
$user='wkaiser';
$pass='************';
$connection = fopen ("https://calendar.local.de:4433/login.wcap?refresh=1&user=$user&amp;password=$pass&quote;,&quote;r+&quote;);

    if (!$connection) {
       print &quote;&lt;p&gt;Unable to connect to calendar server&lt;p&gt;&quote;;
       exit;
    }
    else {
       print &quote;&lt;p&gt;Connection o.k.&lt;p&gt;&quote;;
    }

    $id = &quote;&quote;;
    while (!feof($connection))
       {
         $currentLine = fgets ($connection, 4096); 
         print &quote;&lt;p&gt;Line: $currentLine&lt;p&gt;&quote;;
         if ( ereg(&quote;^X-NSCP-WCAP-SESSION-ID:(&#1111;a-z0-9]*)&quote;, $currentLine, $regs) ) {
              $id = $regs&#1111;1];
              $socket=fopen (&quote;https://calendar.local.de:4433/storeevents.wcap?id=$id&amp;calid=semA&amp;dtstart=20050708T103000&amp;dtend=20050708T113000&amp;summary=KickOff&quote;,&quote;r+&quote;);
              fclose($socket);
         }
       }
    fclose($connection);

    if ($id == &quote;&quote;) {
       print &quote;Login failed&lt;p&gt;&quote;;
       exit;
    }
    else {
       print &quote;&lt;p&gt;SessionID: $id&lt;p&gt;&quote;;
    }
?&gt;
[/php]

The connection works, and i also can retrieve data:

[code]
# /usr/local/bin/php connectSSL.php
&lt;p&gt;Connection o.k.&lt;p&gt;&lt;p&gt;Zeile: BEGIN:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: PRODID:-//Sun/Calendar Server//EN
&lt;p&gt;&lt;p&gt;Line: METHOD:PUBLISH
&lt;p&gt;&lt;p&gt;Line: VERSION:2.0
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-SESSION-ID:be2ow9e5uh2n8ut6
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-USER-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-CALENDAR-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-ERRNO:0
&lt;p&gt;&lt;p&gt;Line: END:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: &lt;p&gt;&lt;p&gt;SessionID: be2ow9e5uh2n8ut6&lt;p&gt;
[/code]

But i just can't writ last three days, we have installed a Sun Java System Calendar Server. One of the aims was / is to send data from our PHP/MySQL based announcement system - using PHP - via the calendar's WCAP interface to the calendar.

Therefore, the folowing code was written:

[php]
<?php
$user='wkaiser';
$pass='************';
$connection = fopen ("https://calendar.local.de:4433/login.wcap?refresh=1&user=$user&password=$pass","r+");

    if (!$connection) {
       print "<p>Unable to connect to calendar server<p>";
       exit;
    }
    else {
       print "<p>Connection o.k.<p>";
    }

    $id = "";
    while (!feof($connection))
       {
         $currentLine = fgets ($connection, 4096); 
         print "<p>Line: $currentLine<p>";
         if ( ereg("^X-NSCP-WCAP-SESSION-ID:([a-z0-9]*)", $currentLine, $regs) ) {
              $id = $regs[1];
              $socket=fopen ("https://calendar.local.de:4433/storeevents.wcap?id=$id&calid=semA&dtstart=20050708T103000&dtend=20050708T113000&summary=KickOff","r+");
              fclose($socket);
         }
       }
    fclose($connection);

    if ($id == "") {
       print "Login failed<p>";
       exit;
    }
    else {
       print "<p>SessionID: $id<p>";
    }
?>
[/php]

The connection works, and i also can retrieve data:

[code]
# /usr/local/bin/php connectSSL.php
&lt;p&gt;Connection o.k.&lt;p&gt;&lt;p&gt;Zeile: BEGIN:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: PRODID:-//Sun/Calendar Server//EN
&lt;p&gt;&lt;p&gt;Line: METHOD:PUBLISH
&lt;p&gt;&lt;p&gt;Line: VERSION:2.0
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-SESSION-ID:be2ow9e5uh2n8ut6
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-USER-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-CALENDAR-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-ERRNO:0
&lt;p&gt;&lt;p&gt;Line: END:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: &lt;p&gt;&lt;p&gt;SessionID: be2ow9e5uh2n8ut6&lt;p&gt;
[/code]

But i just can't write! It should be no rights problem because i am the admin of the calendar server as well as the owner of the calendar i want to write in.

Pastings the URL 

[url]https://calendar.local.de:4433/storeevents.wcap?id=$id&calid=semA&dtstart=20050708T103000&ame to the calendar.

Therefore, the folowing code was written:

[php]
<?php
$user='wkaiser';
$pass='************';
$connection = fopen ("https://calendar.local.de:4433/login.wcap?refresh=1&user=$user&password=$pass","r+");

    if (!$connection) {
       print "<p>Unable to connect to calendar server<p>";
       exit;
    }
    else {
       print "<p>Connection o.k.<p>";
    }

    $id = "";
    while (!feof($connection))
       {
         $currentLine = fgets ($connection, 4096); 
         print "<p>Line: $currentLine<p>";
         if ( ereg("^X-NSCP-WCAP-SESSION-ID:([a-z0-9]*)", $currentLine, $regs) ) {
              $id = $regs[1];
              $socket=fopen ("https://calendar.local.de:4433/storeevents.wcap?id=$id&calid=semA&dtstart=20050708T103000&dtend=20050708T113000&summary=KickOff","r+");
              fclose($socket);
         }
       }
    fclose($connection);

    if ($id == "") {
       print "Login failed<p>";
       exit;
    }
    else {
       print "<p>SessionID: $id<p>";
    }
?>
[/php]

The connection works, and i also can retrieve data:

[code]
# /usr/local/bin/php connectSSL.php
&lt;p&gt;Connection o.k.&lt;p&gt;&lt;p&gt;Zeile: BEGIN:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: PRODID:-//Sun/Calendar Server//EN
&lt;p&gt;&lt;p&gt;Line: METHOD:PUBLISH
&lt;p&gt;&lt;p&gt;Line: VERSION:2.0
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-SESSION-ID:be2ow9e5uh2n8ut6
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-USER-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-CALENDAR-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-ERRNO:0
&lt;p&gt;&lt;p&gt;Line: END:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: &lt;p&gt;&lt;p&gt;SessionID: be2ow9e5uh2n8ut6&lt;p&gt;
[/code]

But i just can't write! It should be no rights problem because i am the admin of the calendar server as well as the owner of the calendar i want to write in.

Pastings the URL 

[url]https://calendar.local.de:4433/storeevents.calendar's WCAP interface to the calendar.

Therefore, the folowing code was written:

[php]
<?php
$user='wkaiser';
$pass='************';
$connection = fopen ("https://calendar.local.de:4433/login.wcap?refresh=1&user=$user&password=$pass","r+");

    if (!$connection) {
       print "<p>Unable to connect to calendar server<p>";
       exit;
    }
    else {
       print "<p>Connection o.k.<p>";
    }

    $id = "";
    while (!feof($connection))
       {
         $currentLine = fgets ($connection, 4096); 
         print "<p>Line: $currentLine<p>";
         if ( ereg("^X-NSCP-WCAP-SESSION-ID:([a-z0-9]*)", $currentLine, $regs) ) {
              $id = $regs[1];
              $socket=fopen ("https://calendar.local.de:4433/storeevents.wcap?id=$id&calid=semA&dtstart=20050708T103000&dtend=20050708T113000&summary=KickOff","r+");
              fclose($socket);
         }
       }
    fclose($connection);

    if ($id == "") {
       print "Login failed<p>";
       exit;
    }
    else {
       print "<p>SessionID: $id<p>";
    }
?>
[/php]

The connection works, and i also can retrieve data:

[code]
# /usr/local/bin/php connectSSL.php
&lt;p&gt;Connection o.k.&lt;p&gt;&lt;p&gt;Zeile: BEGIN:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: PRODID:-//Sun/Calendar Server//EN
&lt;p&gt;&lt;p&gt;Line: METHOD:PUBLISH
&lt;p&gt;&lt;p&gt;Line: VERSION:2.0
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-SESSION-ID:be2ow9e5uh2n8ut6
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-USER-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-CALENDAR-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-ERRNO:0
&lt;p&gt;&lt;p&gt;Line: END:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: &lt;p&gt;&lt;p&gt;SessionID: be2ow9e5uh2n8ut6&lt;p&gt;
But i just can't write! It should be no rights problem because i am the admin of the calendar server as well as the owner of the calendar i want to write in.

Pastings the URL

https://calendar.local.de:4433/storeeve ... ry=KickOff

exit;
}
else {
print "<p>Connection o.k.<p>";
}

$id = "";
while (!feof($connection))
{
$currentLine = fgets ($connection, 4096);
print "<p>Line: $currentLine<p>";
if ( ereg("^X-NSCP-WCAP-SESSION-ID:([a-z0-9]*)", $currentLine, $regs) ) {
$id = $regs[1];
$socket=fopen (&quote;https://calendar.local.de:4433/storeeve ... e;r+&quote;);
fclose($socket);
}
}
fclose($connection);

if ($id == &quote;&quote;) {
print &quote;Login failed&lt;p&gt;&quote;;
exit;
}
else {
print &quote;&lt;p&gt;SessionID: $id&lt;p&gt;&quote;;
}
?&gt;


The connection works, and i also can retrieve data:

Code: Select all

# /usr/local/bin/php connectSSL.php
&lt;p&gt;Connection o.k.&lt;p&gt;&lt;p&gt;Zeile: BEGIN:VCALENDAR
&lt;p&gt;&lt;p&gt;Line: PRODID:-//Sun/Calendar Server//EN
&lt;p&gt;&lt;p&gt;Line: METHOD:PUBLISH
&lt;p&gt;&lt;p&gt;Line: VERSION:2.0
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-SESSION-ID:be2ow9e5uh2n8ut6
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-USER-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-CALENDAR-ID:wkaiser
&lt;p&gt;&lt;p&gt;Line: X-NSCP-WCAP-ERRNO:0
&lt;p&gt;&lt;p&gt;Line&#58on) {
       print "<p>Unable to connect to calendar server<p>";
       exit;
    }
    else {
       print "<p>Connection o.k.<p&gt;&quote;;
    }

    $id = &quote;&quote;;
    while (!feof($connection))
       {
         $currentLine = fgets ($connection, 4096); 
         print "<p>Line: $currentLine<p>";
         if ( ereg(&quote;^X-NSCP-WCAP-SESSION-ID:(&#1111;a-z0-9]*)", $currentLine, $regs) ) {
              $id = $regs[1];
              $socket=fopen ("https://calendar.local.de:4433/storeevents.wcap?id=$id&calid=semA&dtstart=20050708T103000&dtend=20050708T113000&summary=KickOff","r+");
              fclose($socket);
         }
       }
    fclose($connection);

    if ($id == "") {
       print "Login failed<p>";
       exit;
    }
    else {
       print "<p>SessionID: $id<p>";
    }
?>
The connection works, and i also can retrieve data:

Code: Select all

# /usr/local/bin/php connectSSL.php
&lt;p&gt;Connection o.k.&lt;p&gt;&lt;p>Zeile: BEGIN:VCALENDAR
<pfrom our PHP/MySQL based announcement system - using PHP - via the calendar's WCAP interface to the calendar.

Therefore, the folowing code was written:

Code: Select all

&lt;?php
$user='wkaiser';
$pass='************';
$connection = fopen (&quote;https://calendar.local.de:4433/login.wcap?refresh=1&amp;user=$user&amp;password=$pass&quote;,&quote;r+&quote;);

    if (!$connection) {
       print &quote;&lt;p&gt;Unab