« Back

My Wedding Website

Company Blogs January 21, 2010 By David Truong Staff

Hey guys,

So I promised I would put up a link and so here it is: www.winnieanddavid.com

Here were a few things I learned...

1) Weddings are really expensive... I should create a donate to my wedding portlet and let anyone send money to my paypal =P

2) Props to you if you are good at photoshop.  The pictures took me a long time to do and they don't even look great.

3) My site doesn't work in IE and I don't care

4) MP3 player's don't really work well for websites unless it's flash.

First a lot of people don't like them but my soon to be wife does so sucks to be them... 

Next reloading a page causes a song to start over each time... I spent seriously 2 weeks trying to figure out a good solution.  If you have a flash site, this isn't a problem but unfortunately I don't know how to code in flash/action script.  I didn't really want to use frames and in all honesty... I wasn't sure how to do frames in Liferay...  I tried a flash mp3 player with autoresume but it didn't seem to work in Firefox and I do care about that... so I decided on making the whole content part (everything under then nav and above the footer) refresh with ajax.

AJAXNav = {
	init: function(params) {	
		var layouts = jQuery(params.className);
	changeNavURLs: function(layouts) {
		var layout;
			function() {
				layout = jQuery(this);
				var friendlyURL = layout.attr("url").replace("/", "#");
				layout.attr("href", friendlyURL);
					function() {
						var a = jQuery(this);
						var p = a.parent();
						var plid = a.attr("plid");
						var friendlyURL = a.attr("url").replace("/", "");
						//var url = document.location.hash;
						 window.location.hash = friendlyURL;//url;
							"/c/portal/url?p_l_id=" + plid,
							function(html) {
								var layouts = jQuery(".sub-nav-item");
								if (layouts.length > 0) {
									console.log("processing .sub-nav-item");

That was the code I wrote in javascript.  If you noticed the url was /c/portal/url which basically hit a custom action I made that spit back portlet.jsp.  It worked actually fairly well actually but I had some other issues. 

The back button stopped working so I had to do some funny things with the url adding anchors (i.e. #home) to signal the page changed.

I couldn't get the AJAXNav to play nice with the twitter widget... and unfortunately that was just cut and paste from Twitter so I can't modify that code.  I actually wrote my own twitter portlet that parsed my rss feed so I could still switch to that but I'm not sure all that work I did was worth the effort anyways.

In the end I think I will just make the mp3 player into a popup so you can leave it running if you like or close it if it bugs you.

4) Now that you all discovered I am not a cartoon ninja, I have decided I must put up a real image of myself soon for my avatar (which I liked as a movie).


Threaded Replies Author Date
You're too funny Dave. I'll even use Firefox... Brian Chan January 21, 2010 8:42 PM

You're too funny Dave. I'll even use Firefox for your website. emoticon
Posted on 1/21/10 8:42 PM.