My Subscriptions

No active or expired subscriptions. View Available Subscriptions

News Feed

Receive our Newsletter

Advanced Search

Save $50 on your CMS Expo Registration

Receive $50 off the registration fee for the CMS Expo featuring Joomla! in Dever, Colorado (USA). Click here to register at the reduced rate.
Pages: 1 [2]
Print
Author Topic: Done : Plugin For CB Intergration  (Read 9483 times)
elemental
Guest
« Reply #15 on: November 19, 2007, 05:24:36 PM »

Crony,  I was having the same problem as you.  I added the ,'1' in and now my database updates with the user id.  (at the moment that me me, myself and I). thanks.   
(almost time for me to continuing my learning experience of trying to add in a country/region/state/city location hack which is working in it's own page)

Jay, my problem is that the 'my own events' tab isn't updating with any info. Any hints on what to look for?

Thanks.

Craig



notsonice did you ever get a reply/solution?

After half a day I just got this working!  Grin (i know nothing about .php programming!)
I had the same problem as you but it appears you DON'T add ,'1'

Examples of my code using Joomla! 1.0.13 Stable [ Sunglow ] 21 July 2007

I hope you find this useful, a BIG thanks to abhigudi!

admin_events.php

Code:
$query = "
INSERT INTO ".$CONFIG_EXT['TABLE_EVENTS']." (
title, description, contact, url, email, picture, cat, day, month, year, start_date, end_date, approved, recur_type, recur_val, recur_end_type, recur_count, recur_until, published, userid
) VALUES (
'$title','$description','$contact','$url','$email','$picture','$cat','$day','$month','$year','$start_date','$end_date','$approve','$recur_type','$recur_val','$recur_end_type','$recur_count','$recur_until', '1','$userid'
)";


jcalpro.php

Code:
$query = "
INSERT INTO ".$CONFIG_EXT['TABLE_EVENTS']." (
title, description, contact, url, email, picture, cat, day, month, year, start_date, end_date, approved, recur_type, recur_val, recur_end_type, recur_count, recur_until, userid
) VALUES (
'$title','$description','$contact','$url','$email','$picture','$cat','$day','$month','$year','$start_date','$end_date','$approve','$recur_type','$recur_val','$recur_end_type','$recur_count','$recur_until','$userid'
)";

theme.php

Code:
// HTML template to display an event form
$template_add_event_form = <<<EOT
<tr><td>
    <form name="eventform" action="{TARGET}" method="post" enctype="multipart/form-data">
<input name="extmode" type="hidden" value="{MODE}" />
<input name="extid" type="hidden" value="{EVENT_ID}" />
        <table cellspacing="0" cellpadding="0" border="0">
<!-- BEGIN errors_row -->
<tr>
<td class='tablec' colspan='2'>
<img src='{$CONFIG_EXT['calendar_url']}themes/default/images/errormessage.gif' style='vertical-align: middle' />&nbsp;<strong>{ERRORS}</strong>
</td>
</tr>
<tr>
<td class='tableb' colspan='2'>
<div class='atomic'>{ERROR_MSG}</div>
</td>
</tr>
<!-- END errors_row -->
<!-- BEGIN event_details_row -->
<tr>
<td class='tableh2' colspan='2'>{EVENT_DETAILS_CAPTION}</td>
</tr>
<tr>
<td class='tableb' width='160'>{TITLE_LABEL}</td>
<td class='tableb'><input type='text' name='title' class='textinput' value="{TITLE_VAL}" size='37' />
</td>
</tr>
<tr>
<td class='tableb' width='160'>{DESC_LABEL}</td>
<td class='tableb'>

{DESC_EDITOR}

</td>
</tr>
<tr>
<td class='tableb' width='160'>{SEL_CATS_LABEL}</td>
<td class='tableb'>
<select name='cat' class='listbox'>
<option value='0' style='color: #666666'>{SEL_CATS_DEF}</option>
{SEL_CATS_VAL}
</select>
</td>
</tr>
<tr>
<td rowspan='4' class='tableb' width='160'>{DATE_LABEL}</td>
<td class='tablec'>{START_DATE_LABEL}:</td>
</tr>
<tr>
<td class='tableb'>
<select name='day' class='listbox'>
<option value='0' style='color: #666666'>{DAY_LABEL}</option>
{START_DAY_VAL}
</select>&nbsp;
<select name='month' class='listbox'>
<option value='0' style='color: #666666'>{MONTH_LABEL}</option>
{START_MONTH_VAL}
</select>&nbsp;
<select name='year' class='listbox'>
<option value='0' style='color: #666666'>{YEAR_LABEL}</option>
{START_YEAR_VAL}
</select>&nbsp;&nbsp;
{START_TIME_LABEL}:
<select name='start_time_hour' class='listbox'>
{START_HOUR_VAL}
</select>
<select name='start_time_minute' class='listbox'>
{START_MINUTE_VAL}
</select>
<!-- BEGIN 12hour_mode_row -->
<select name='start_time_ampm' class='listbox'>
{START_AMPM_VAL}
</select>
<!-- END 12hour_mode_row -->
</td>
</tr>
<tr>
<td class='tablec'>{END_DATE_LABEL}:</td>
</tr>
<tr>
<td class='tableb'>
<input type='radio' name='duration_type' value='1' {DURATION_TYPE_NORMAL_CHECKED} />&nbsp;&nbsp;&nbsp;
<input type='text' name='end_days' class='textinput' value='{DAYS_VAL}' size='3' />&nbsp;{DAYS_LABEL}&nbsp;&nbsp;
<input type='text' name='end_hours' class='textinput' value='{HOURS_VAL}' size='3' />&nbsp;{HOURS_LABEL}&nbsp;&nbsp;
<input type='text' name='end_minutes' class='textinput' value='{MINUTES_VAL}' size='3' />&nbsp;{MINUTES_LABEL}&nbsp;&nbsp;
<br />
<input type='radio' name='duration_type' value='2' {DURATION_TYPE_ALLDAY_CHECKED} />&nbsp;&nbsp;&nbsp;{ALL_DAY_LABEL}
<br />
<input type='radio' name='duration_type' value='0' {DURATION_TYPE_NONE_CHECKED} />&nbsp;&nbsp;&nbsp;{NO_DURATION_LABEL}
</td>
</tr>
<!-- END event_details_row -->
<tr>
<td class='tableh2' colspan='2'>{CONTACT_CAPTION}</td>
</tr>
<!-- BEGIN contact_row -->
<tr>
<td class='tableb' width='160'>{CONTACT_LABEL}</td>
<td class='tableb'>
<textarea name='contact' cols='50' rows='5' class='textarea'>{CONTACT_VAL}</textarea>
</td>
</tr>
<!-- END contact_row -->
<!-- BEGIN email_row -->
<tr>
<td class='tableb' width='160'>{EMAIL_LABEL}</td>
<td class='tableb'><input type='text' name='email' class='textinput' value="{EMAIL_VAL}" size='25' /></td>
</tr>
<!-- END email_row -->
<!-- BEGIN url_row -->
<tr>
<td class='tableb' width='160'>{URL_LABEL}</td>
<td class='tableb'><input type='text' name='url' class='textinput' value="{URL_VAL}" size='25' />
</td>
</tr>
<!-- END url_row -->

<!-- BEGIN userid_hidden -->
<input type='hidden' name='userid' value="$my->id"/>
<!-- END userid_hidden -->
Logged
filterit
Newbie
*

Karma: +0/-0
Posts: 10


View Profile
« Reply #16 on: December 29, 2007, 05:06:18 PM »

I can not seem to get the event to add the user id to the table.
If I manually edit the table and put the user id in it shows up in the CB profile tab.
Joomla 1.0.12 & CB 1.1
Logged
tripod0502
Newbie
*

Karma: +0/-0
Posts: 1


View Profile Email
« Reply #17 on: January 14, 2008, 09:40:21 AM »

I am running Joomla! 1.0.13, Community Builder 1.1 and JCal Pro 1.5 and I have tried each different version of this hack to no avail.

Every time I modify the PHP, I can't get into JCal through either the my Admin panel or through the frontend. It renders a blank page- no code, no errors. Any pointers?
Logged
crony
Newbie
*

Karma: +0/-0
Posts: 15


View Profile
« Reply #18 on: January 14, 2008, 12:38:55 PM »

Hello,
What URL do you see ?
Did you make the changes into the database ?
You may have missed something...
Did you try on a clean install ?

That's all I can think at the moment...

Good luck !  Wink
Logged
MarkusK
Newbie
*

Karma: +0/-0
Posts: 6


View Profile
« Reply #19 on: August 08, 2008, 07:02:04 PM »

It doesn't work for the actual Version for J1.5, there are no similar rowas in jcalpro.php.
How do i realize this ?
Logged
starkheim
Newbie
*

Karma: +0/-0
Posts: 13


View Profile WWW
« Reply #20 on: September 01, 2008, 03:01:17 PM »

 

Hello

I heard of your Pulgin.

Unfortunately this does not function under 1.5 and the new CB.

The XML file is not evaluated correctly.

Have one perhaps tap for me.
best regards
Starkheim
Logged
DirtyMonkey
Newbie
*

Karma: +0/-0
Posts: 5



View Profile
« Reply #21 on: September 15, 2008, 03:13:13 AM »

I've just written a plugin for Community Builder integration where in the users profile, the events which he add are shown.. Three files need to be changed for this to work.. Along with one db change.. Sorry guys i cant point out the line numbers as my component files are heavily modified..

-----------------------------------------------------------
Filenames : admin_events.php , jcalpro.php
-----------------------------------------------------------

Two common changes in these files..
1. Find the INSERT query and add this field to be inserted..

$query = "INSERT INTO ".$CONFIG_EXT['TABLE_EVENTS']." (
   title, description, contact, url, email, picture, cat, day, month, year, start_date, end_date, approved, recur_type, recur_val, recur_end_type, recur_count, recur_until, published, userid) VALUES
('$title','$description','$contact','$url','$email','$picture','$cat','$day','$month','$year
','$start_date','$end_date','$approve','$recur_type','$recur_val','$recur_end_type','$recur_
count','$recur_until', '1','$userid')";

2. Find this line in the code..
if (isset($form['cat'])) $cat = $form['cat']; else $cat = '';
Add this on the next line..
if (isset($form['userid'])) $userid = $form['userid']; else $userid = '';

-----------------------------------------------------------
Filenames : /themes/default/theme.php
-----------------------------------------------------------

Two changes in this file..

1. Add global declaration $my at the top of the page..

global $my;

2. Find the template for adding an event

// HTML template to display an event form
$template_add_event_form = <<<EOT


Add the followning code

<!-- BEGIN userid_hidden -->
<input type='hidden' name='userid' value="$my->id"/>
<!-- END userid_hidden -->


after the <!-- END url_row -->

-----------------------------------------------------------
Database -> Tablename #__jcalpro_events
-----------------------------------------------------------

Alter the table and add a new field userid int(15)

If you have any question with integration please do email me at jay@yulop.com / jayanth@amonks.in


Hi abhigudi, firstly thanks for the plugin.

I'm trying to get this working under Joomla! 1.5.x and JCal Pro 1.5.3 but the original code found in admin_events.php is not in jcalpro.php

Any suggestions for a fix?

Thanks in advance, DM.  Grin
Logged
DirtyMonkey
Newbie
*

Karma: +0/-0
Posts: 5



View Profile
« Reply #22 on: September 15, 2008, 03:19:37 AM »

Wow! Thanks a bunch.

We'll compare this to our efforst for CB in the next release.

Users can also follow this topic on the CB forum:

http://www.joomlapolis.com/index.php?option=com_joomlaboard&Itemid=38&func=view&catid=41&id=43825#43825

Hi, V-man,

I'm trying to get this working under Joomla! 1.5.x and JCal Pro 1.5.3 but the original code found in admin_events.php is not in jcalpro.php

Any suggestions for a fix?

Cheers, DM.
Logged
crony
Newbie
*

Karma: +0/-0
Posts: 15


View Profile
« Reply #23 on: October 19, 2008, 09:28:58 AM »

Hello,

Looking for this too... Wink
Logged
Pages: 1 [2]
Print
Jump to:  

Powered by SMF 1.1.6 | SMF © 2006-2008, Simple Machines LLC
Joomla Bridge by JoomlaHacks.com

Original Joomla Template design by RocketTheme ( Conversion by Bloc)