Browse by Tags
All Tags »
HTML (
RSS)
There is a (not so) particular kind of shape in Orchard: zones. Functionally, zones are places where other shapes can render. There are top-level zones, the ones defined on Layout, where widgets typically go, and there are local zones that can be defined anywhere. These local zones are what you target in placement.info . Creating a zone is easy because it really is just an empty shape. Most themes include a helper for it: Func<dynamic, dynamic> Zone = x => Display(x); .csharpcode, .csharpcode pre { font-size: small; color: black; font-family: consolas, "Courier New", courier, monospace; background-color: #ffffff; /*white-space: pre;*/ } .csharpcode pre { margin: 0em; } .csharpcode .rem { color: #008000; } .csharpcode .kwrd...
One of our goals in Orchard is to make it possible and simple to change and customize the markup and style for everything that gets rendered by the application and its modules. Of course, this is made a lot trickier by our other big requirement of making everything a composition of atomic parts. Yesterday, we brought on site a web developer who is a fan of Drupal and is occasionally using Joomla! and WordPress to get some good feedback after her using Orchard on a project. And that we got. One of the many interesting things she told us had one essential quality though: it was immediately actionable. Here is the idea. This is the generated markup for an HTML widget in Orchard: < article class ="widget-html-widget widget" > <...
A task that is likely to pop-up oftentimes when customizing an Orchard theme for a project is list rendering. Two types of shapes will typically be at work when rendering a list in Orchard: the summary shape and the list shape. The list shape itself will rarely vary as the semantics of a list pretty much mandate the use of a simple UL/LI decorated with CSS classes. It's so simple in fact that it's not even rendered by a template but by a C# shape method in CoreShapes.cs. The summary shapes can be rendered by templates that are specialized by content type and by display type. That covers most cases of list customization. In a few rare cases though, you'll want to simply take over the rendering of a specific list completely. In my...
These last few weeks I’ve been refraining from starting any deep work on my new Orchard-powered blog because most of what I had in mind involved widgets, which are being built right now. Version 0.8 is just around the corner: the team is just putting the final touches to the new theme engine and to the widget system. In the meantime, there is still some work I could do that I knew would not be throw-away, and that is CSS. My objectives with this new blog is to reflect in design what the content is about and what it is not about. VuLu is about knowledge, science, art and philosophy. It’s not about shiny gadgets, technology or engineering. That of course means I want nothing web 2.0 in here. Good thing as I don’t have much love for rounded corners...
In the previous post , I installed Orchard onto my hosted IIS7 instance and created the “about” page. This time, I’m going to show how I imported existing contents into Orchard. For my new blog, I didn’t want to start with a completely empty site and a lame “first post” entry. I did already have quite a few posts here and on Facebook that fit the spirit I wanted for the new blog so I decided to use that to seed it. The science and opinion posts on Tales of the Evil Empire always seemed a little out of place (which some of my readers told me quite plainly), and the Facebook posts were blocked behind Facebook’s silo walls even though they were public. You still need a Facebook account to read those posts and search engine can’t go there as far...
Too many people don’t realize that there are other options than <!-- --> comments to annotate HTML. These comments are harmful because they are sent to the client and thus make your page heavier than it needs to be. When doing ASP.NET, a simple drop-in replacement is server comments, which are delimited by <%-- --%> instead of <!-- -->. Those server comments are visible in your source code, but will never be rendered to the client. Here’s a simple way to sanitize a web site. From Visual Studio, hit CTRL+H to bring the search and replace dialog. Choose “Replace in Files” from the second menu on top of the dialog. Open the find options, check “use” and make sure “Regular expressions” are selected. Use “*.aspx;*.ascx;” as the...
I recently got a question on one of my client template posts asking me how to bind a select tag’s value to data in client templates . I was surprised not to find anything on the web addressing the problem, so I thought I’d write a short post about it. It really is very simple once you know where to look. You just need to bind the value property of the select tag, like this: < select sys : value ="{binding color}" > If you do it from markup like here, you just need to use the sys: prefix. It just works. Here’s the full source code for my sample page: <! DOCTYPE html > < html > < head > < title > Binding a select tag </ title > < script src = http://ajax.microsoft.com/ajax/beta/0911/Start.js type...
I apologize for the neologism. What I’m going to demonstrate in this post is a technique I prototyped a few months ago to make it very easy to embed an ASP.NET page’s content in another page, even if it’s using another server technology. This of course works cross-domain. The reason why you would do that is to enable people to embed badges with your contents on their own sites. Examples of such badges can be found in the margin of this blog: there’s the ad badge, a Twitter badge, a Facebook badge, an Xbox Live badge, a Zune badge, and there used to be a Flickr badge. There are even full commenting systems that you can include on your blog this way. All those are Flash or JavaScript, and in both cases there’s a short JavaScript stub that includes...
My team is looking for a new full-time developer. The project is to build a completely new open-source CMS based on ASP.NET MVC 2. It’s a lot of fun :) https://careers.microsoft.com/JobDetails.aspx?ss=&pg=0&so=&rw=1&jid=9434&jlang=EN Read More...
More Posts
Next page »