Folks that work with me know that I’m not a super-awesome programmer; I’m a front-end guy who dables with programs. I’m way more comfortable telling you what went wrong with your CSS in Internet Explorer 8 than what happened with your Razor template in Tridion 2011. Razor Mediator for Tridion is a blend of C# and .NET that just operates about two levels higher than where I am most of the time. As a result, I often spend time trying to figure out what information there is on a component and how to grab it. So a few weeks ago, I went from knowing that Razor could access TOM.NET to actually understanding it, and as a result I wrote a little debugging TBB to help other front-end guys looking to figure this thing out.
document, and started browsing through the available properties. Well, Google is faster than scrolling through a console, so the right answer turns out to be
document.referrer. But I stumbled upon something else which kind of blew my mind:
document.styleSheets. Yeah, your style sheets are in the DOM, and that’s not all…
I’m written in the past on how cool
contenteditable is, and what the potential usages are. Especially once you mix it with the
scoped attribute, you can turn
contenteditable into a pretty powerful component of an editing application of some sort. In fact, I have a few applications that I’ve been working on which called for exactly such a thing. But there’s no jQuery plugin for making stuff editable! And if you don’t have a plugin for making stuff editable, you surely don’t have one that makes utilizes the scoped attribute. Even worse, you certainly couldn’t have one that had a fallback for those browsers that didn’t support
scoped just yet. Well, we do now.
Not too long ago, I worked with Alex Klock on creating a Tridion GUI extension for a client. The GUI extension was for a document embedding service provided by Crocodoc1. Once I finished, I had to provide a training document for it. Soon after, the client wanted documentation on some other things. And then more things. Being one for
efficiency and optimization creative laziness, I found a way to make sure everyone gets the latest version of the same document. So I’d like to share a super nifty trick for embedding training documents into your Tridion implementation.
1 If you don’t know who Crocodoc is, you should rapidly become acquainted. Their API definitely is not one that sucks; it converts PDFs, PowerPoints, Excel documents, and Word documents into HTML (and soon to be HTML5) so that you can read the same document on any device with a screen, without nasty platform-based plugins.
I’ve said before and I’ll say again that
This time, I want to combine what we’ve learned about CSS and
contenteditable with another HTML5 attribute called
scoped, and show you a fun little jQuery plugin that’s sure to make your day more interesting.
I’m a child of the 80′s. Every Saturday morning, between Teenage Mutant Ninja Turtles, X-Men, and GI-Joe I’d catch at least two or three Public Service Announcements from NBC where they’d teach me about bullying or doing my homework, and end it with, “The More You Know.”
The last few Tridion 2011 projects I’ve had have used Categories and Keywords pretty extensively. The Keyword class is relatively simple, but quirky. After discovering another extremely odd quirk a few days ago when I was debugging something for a client, I had to explain the craziness of the issue in our next status call. After I explained the issue and a few folks’ mouths were agape and they were scratching their heads, it was one of those moments where you just have to quote NBC: “Yep. The more you know”.
It’s probably not the most exciting thing that you could read about, but it’s definitely one of the cooler ones. If you haven’t heard of Crocodoc, you really should check it out. Crocodoc is an API that converts PDF and Microsoft Office Documents to HTML5. If that still doesn’t quite ring clear, allow me to rephrase; Crocodoc converts documents from something that requires another application (like a PDF reader or Microsoft Word) to read, into something that a web page can read. And it does a really stinking good job at it.
In a current project, we have a website that’s in both French and English which we’re transferring into Tridion 2011, using Razor Mediator. This is not my first bilingual website, and it definitely isn’t my first Razor project, either. However, it’s the first time I’ve had both at the same time. So what I’d like to share is how to solve a specific problem where you have content that could be hard-coded in your Template Building Block (TBB), but can’t, because it needs to be translated.
So, yesterday while I was on a call, demoing something to a client, there was a Skype conversation going on in the other window. And though I explained I wouldn’t be able to respond to what was going on in that group chat, a certain coworker decides to get a little snarky.
So here we have a conversation:
[1/30/13 12:21:47 PM] C W: anyone have a comment on my question?
[1/30/13 12:21:52 PM] C W: lol
[1/30/13 12:22:04 PM] D K: You’re fine no need to answer C W
[1/30/13 12:22:07 PM] Frank M. Taylor: ugh
[1/30/13 12:22:09 PM] Frank M. Taylor: what
[1/30/13 12:22:11 PM] Frank M. Taylor: now
[1/30/13 12:22:12 PM] C W: LOL frank!!!
[1/30/13 12:22:27 PM] Frank M. Taylor: sorry… doing a screen share w/ [CLIENT] on the other screen
[1/30/13 12:22:48 PM] C W: Frank, I need you to code all the html/css and js for www.microsoft.com
[1/30/13 12:23:12 PM] Frank M. Taylor: requirements, bro, requirements
[1/30/13 12:23:47 PM] C W: Requirements:
1. Make it pretty
2. Make it fast
3. Make me feel like im flying in space
4. Do it in a week
[1/30/13 12:24:01 PM] C W: oh, and i want kittens
[1/30/13 12:24:09 PM] C W: because EVERYONE likes kittens
[1/30/13 12:24:25 PM] C W: oh! and clip art! MUST have clip art
[1/30/13 12:24:39 PM] C W: and can you do that using only tables?
So guess what?
Project SpaceKittens.org begins Friday night.
Will you fly in space?
Will it be pretty
As pretty as Tanya Harding and Nadya Suleimann’s love child.
Will it be in a week?
Nay, sir. It will be in a weekend
And the kittens?
Dude, it’s spacekittens.org. Of course
And the clip art?
is there any other kind?
But…will you really do it in tables?
Tables inside of tables inside of iframes.
Will it feature [XXXX] super-gross HTML?
Marquee, blink, <b>, <i>, and every other bastardized corruption of the HypterText Markup Language.
Got a suggestion?
Post it in the comments.
I just want to publicly say, “congratulations” to my fellow coworker and code-monkey, and Coded Weapon, Alex Klock. Alex was recently given the SDL Tridion MVP Award. This is a well-earned award and Alex should be very proud to have it.
The thing is, Alex is what you’d call a digital inventor.
Some people go to school, or develop a skill in programming so they can earn a paycheck. Those guys earns their paychecks writing code. Alex doesn’t code for money, he does it for fun. He develops for the challenge of it, and shares his work with the world. And it just so happens that he stumbled upon a company like Tahzoo that was willing to pay him for what he was going to do, anyway. Alex has a passion for programming – which is what makes this award so well earned.