var RS = RS || function() {
	var questions = { "pro": "Michael A. Persky, MD, FACS", "questions": [ { "title": "Fractional Carbon Dioxide Lasers, The New Wave of Facial Cosmetic Surgery", "nid": "45865", "url": "/answer/fractional-carbon-dioxide-lasers-the-new-wave-facial-cosmetic-surgery" }, { "title": "What is VelaShape?", "nid": "41134", "url": "/question/what-velashape#tip-45716" }, { "title": "What\'s the best lip augmentation treatment?", "nid": "8620", "url": "/question/whats-best-lip-augmentation-treatment#tip-44692" }, { "title": "How do I find a good reconstructive surgeon to fix bad plastic surgery mistakes?", "nid": "44432", "url": "/question/fix-bad-plastic-surgery-reconstructive-surgeon#tip-44472" }, { "title": "How long should I wait between laser treatments?", "nid": "44438", "url": "/question/how-long-should-wait-between-laser-treatments#tip-44471" } ], "link": "/pro/Michael-Persky-MD/Encino-CA-91436/Plastic-surgeon" };
	
	function parse_questions() {
		var domain = 'http://www.realself.com';
		var img_src = domain + '/widget_logo.png';
		var img_alt = 'RealSelf.com - Answers, tips, reviews for beauty, anti-aging skin care, cosmetic plastic surgery';
		
		
		var content = '<div>';
		var q;
		for (var i = 0; q = questions.questions[i]; i++) {
			content += '<p><a href="' + domain + q.url + '" target="_blank">' + q.title + '</a></p>';
		}
		content += '<div>';
		content += '<p><a href="' + domain + questions.link + '" target="_blank">All answers from ' + questions.pro + '</a></p>';
		content += '<a href="' + domain + '" target="_blank"><img src="' + img_src + '" alt="' + img_alt + '" style="border: none" /></a>';
		
		var cont = document.getElementById('rs_questions');
		cont.innerHTML = content;
		
		if (navigator.userAgent.match(/MSIE [5|6]/)) {
			var img = cont.getElementsByTagName('IMG')[0];
			img.style.filter = "progid:DXImageTransform.Microsoft.AlphaImageLoader(src='" + img.src + "', sizingMethod='image')";
			img.src = domain + '/themes/renewal/img/ie_fix.gif';
			img.parentNode.style.width = '121px';
			img.parentNode.style.height = '31px';
		}
	}
	
	function add_event(el, type, listener) {
		if (document.addEventListener) {
			el.addEventListener(type, listener, true);
		}
		else {
			el.attachEvent('on' + type, listener);
		}
	}
	
	add_event(window, 'load', parse_questions);
}();
