|
|
 Rank: Fanatic
Joined: 7/25/2006 Posts: 433 Location: Silkeborg, Denmark
|
When creating a macro you have the choice of using either a) An XSLT file b) a .NET User Control c) a .NET Custom Control d) a Python file I've made plenty of a's and b's so far, but what is Custom Controls used for? Can anyone give me an example/scenario? /SoerenS Brug for råd til hvordan du driver en god webshop? / Need advice on how to run an effective webshop?
|
|
Rank: Enthusiast
Joined: 8/21/2007 Posts: 13
|
There are plenty of situations where a custom control is to prefer. Here are two examples:
1. You want to create a calendar that shows all holidays with a red background color. You then create a new control called "HolidayCalendar", inherit from "Calendar" and use directly in umbraco.
2. You wan't to insert a login form on a page. You can then create a Macro that points to System.Web.UI.WebControls.Login and there you have it.
Basically whenever you want to use a control from an assembly or a specialization of an existing control. UserControl's are mainly for when you have a number of controls you want to display, with some specific markup to separate them.
I use the Custom Controls whenever I need a control without, or whith minimal, markup or when using a control from my personal WebControl library.
Hope that helped...
I don't really mean what I just said...
|
|
 Rank: Devotee
Joined: 7/20/2006 Posts: 76 Location: Italy
|
Has anyone got some samples of using python inside of umbraco? I was looking into the google calendar api and I noticed the python library and I remember this post so I thought maybe this could be a good way of accessing google calendar from inside of umbraco. What do you guys think? Anyone tried this? http://code.google.com/apis/calendar/developers_guide_python.html
"We come from the land of the ice and snow, From the midnight sun where the hot springs blow"
|
|
Rank: Enthusiast
Joined: 8/21/2007 Posts: 13
|
I haven't tried any of the API's, but I know there is a .NET API as well: http://code.google.com/apis/calendar/developers_guide_dotnet.html
I don't really mean what I just said...
|
|
 Rank: Devotee
Joined: 7/20/2006 Posts: 76 Location: Italy
|
Yes later I noticed the .net api. However I'm still interested in seeing pythin in action. I havent seen why this was included yet.
"We come from the land of the ice and snow, From the midnight sun where the hot springs blow"
|
|
|
Guest |