Home · Links · Contact Us
Home arrow Forums
Home
Features
FAQ
Screen Shots
Modules
Themes
Demos
Documentation
Forums
Contact Us
Download
Purchase
Quotes

" ... I want to tell you that your thyme product is functional and valuable beyond words. I cannot imagine why any portal would be without it. It is the cornerstone of our new project ..."

" ... Thanks for such a complete project, its making my job much easier. ..."

" ... I have now deployed 4 different calendars and our users love them ... "

" ... Easy to install and use and a great look/design. ..."

" ... This has to be the easiest to use program I think I've had to deal with at all this year. ..."


  FAQFAQ    SearchSearch  RegisterRegister   Log inLog in 
How to copy calendars or categories

 
Post new topic   Reply to topic     Forum Index -> Hacking Thyme
View previous topic :: View next topic  
Author Message
DonH



Joined: 04 Nov 2008
Posts: 8

PostPosted: Mon Dec 08, 2008 2:03 pm    Post subject: How to copy calendars or categories Reply with quote

Can I copy a calendar after setting up categories so I don't have to recreate everything every time? How about just copying a set of categories that can be used for future calendars? Must I make all these changes to the default calendar in order to get this kind of functionality?

Thanks,

Don
Back to top
View user's profile Send private message
esoft_ian



Joined: 12 Sep 2005
Posts: 5275

PostPosted: Mon Dec 08, 2008 5:40 pm    Post subject: Reply with quote

Hi Don,

Please

*) download this file: http://www.extrosoft.com/products/thyme/copycat.txt

*) rename it to copycat.php

*) upload it to Thyme's folder on your web server.

*) navigate to http://your.site.com/thyme/copycat.php

This script will allow you to copy categories from one calendar to another.
Back to top
View user's profile Send private message Visit poster's website
Cave_Dweller



Joined: 27 Oct 2008
Posts: 40

PostPosted: Tue Dec 16, 2008 6:45 pm    Post subject: Reply with quote

Are all of the settings (except categories) for a calendar in the thyme_Calendars table of MySQL or are there some settings hidden elsewhere?

Looks like it would be faster to duplicate a line and change ID and name using phpMyAdmin than going through the dialog boxes. (I have at least 50 to create)

Might not be too hard to make a copycat type file to do this same thing, with a space for to change the new calendar name. I'll do that when I get the time.

UPDATE: Yes, using phpMyAdmin, you can click on the pencil to edit your last row (calendar) in the table. In the ensuing page, add one to the ID and change the name under both name (and description, if needed).
Then under the popup box at the bottom of the page, select save as new row and click go. There you have it, instant new calendar, with all the settings done.
Now run copycat.php to add the categories.
Perfect!
Back to top
View user's profile Send private message
DonH



Joined: 04 Nov 2008
Posts: 8

PostPosted: Fri Dec 19, 2008 1:38 pm    Post subject: Reply with quote

I put copycat.php in the same directory as login.php. Is that correct?

When I put in the URL to copycat.php it flashes briefly but then I go back to login.

Don
Back to top
View user's profile Send private message
Cave_Dweller



Joined: 27 Oct 2008
Posts: 40

PostPosted: Fri Dec 19, 2008 2:43 pm    Post subject: Reply with quote

Yes, therefore it should be in same directory as index.php. Do you have a calendar set up with with categories installed to copy from?
Back to top
View user's profile Send private message
DonH



Joined: 04 Nov 2008
Posts: 8

PostPosted: Fri Dec 19, 2008 3:16 pm    Post subject: Reply with quote

Yes, it's in the same directory as index.php, login.php, phpinfo.php, etc.

I do have some calendars with categories that I could use to test it at least.

Don
Back to top
View user's profile Send private message
esoft_ian



Joined: 12 Sep 2005
Posts: 5275

PostPosted: Fri Dec 19, 2008 5:20 pm    Post subject: Reply with quote

Hi,

You have to be logged in as admin to be able to copy categories. Navigate to the copycat script as you did before. At the login screen, login. It should then redirect you back to the copycat script.

Let me know if you have any questions / trouble.
Back to top
View user's profile Send private message Visit poster's website
DonH



Joined: 04 Nov 2008
Posts: 8

PostPosted: Fri Dec 19, 2008 6:37 pm    Post subject: Reply with quote

Ah, now I see. Thanks for the info Ian. And thanks for the table copy info Cave Dweller. Now I need to get phpMyAdmin installed.

Don
Back to top
View user's profile Send private message
Cave_Dweller



Joined: 27 Oct 2008
Posts: 40

PostPosted: Sun Dec 21, 2008 12:00 am    Post subject: Reply with quote

When using phpmyadmin to create a bunch of new calendars, they only show up for admin when admin is logged in. The don't show for the public nor do they show for normal registered users who are logged in.

So copying the calendars is only part of it. Next is to add the users. This can be done through the Thyme admin screen, Calendars.

- OR -

If you have a lot of them, a faster way is by using phpMyAdmin.

In phpMyAdmin, view the Calendars table. Make note of the calendar numbers. The ones that you added using the previous post will need users assigned.

Now in phpMyAdmin, select the CalendarMembers table. If you have two users in your calendars, a registered user and public user for each calendar, you will see in the CalendarMembers table that there are two cid (Calendar ID) lines for each calendar, one for each user level.

Depending on how many new calendars you have added, click the box at the front of each line to select a existing calendar members. Multiple selections are fine, but be sure to select them in pairs,using the cid as reference. Note the cid number of the last ones on the list.

Click the pencil at the bottom to edit all. Then starting from the top, change the cid field (only) on each pair to correspond to the new calendar id of the calendars you created using the copy method described earlier in this thread.

Select add as a new row from the drop down menu and click go at the very bottom of the edit screen in phpMyAdmin. You will have added users to your new calendars. Verify that they match those set up in the Thyme Admin screen.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic     Forum Index -> Hacking Thyme All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
© 2005 eXtrovert software unless otherwise noted. All rights reserved.
Portions © 2004 Ben Brown. All rights reserved.
Trademarks are property of their respective owners.