UPDATE: "Just as I was about to post this... Google did some update of some kind.. the gui of gadgets changed and out of NO WHERE the gadget suddenly worked!!!! ARGH! You are kidding me.. I have been at this gadget for over 6 horus and then suddenly to find out that it was Google all along???!!!! COME ON!"
I am writing a gadget to display a business card... it is published here: http://hosting.gmodules.com/ig/gadgets/file/107142568060666278807/SimpleHTMLBusinessCard.xml I have been trying for over 6 hours to get this to work in Google Sites... but no luck. So this is my code... can someone please tell my why it is not working??? <?xml version="1.0" encoding="UTF-8"?> <Module> <ModulePrefs title="Simple BusinessCard" description="Displays a simple HTML Business Card" author="Lisa-Marie Thompson" author_affiliation="None" author_email="[email protected]" screenshot="" height="148" width="350"> <Require feature="dynamic-height"/> </ModulePrefs> <UserPref name="fullName" display_name="Full Name" required="false" default_value="John Smith"/> <UserPref name="jobTitle" display_name="Job Title" required="false" default_value="Job titel"/> <UserPref name="mobNr" display_name="Mobile Nr" required="false" default_value="555 555 5555"/> <UserPref name="emailAddress" display_name="Email Address" required="false" default_value="[email protected]" /> <UserPref name="myphoto" display_name="Photo" default_value="http:// doc.examples.googlepages.com/rowan-headshot.jpg"/> <Content type="html"><![CDATA[ <div id="content_div"></div> <div id="debug_div" style="font-size:9pt; padding:5px; color: red;"></ div> <script type="text/javascript"> // Get userprefs var prefs = new gadgets.Prefs(); // debug flag. When its value is non-zero, debugging messages are displayed var debug = 1; // The string containing debugging messages var debug_html = ""; function init(){ // DEBUG: is the function getting called? print("In displayDate function<br>"); var htmlFirst = '<table width="350" cellspacing="0" cellpadding="0"><tbody><tr>'; var htmlTD1 = '<td width="270" valign="top" style="border: 1px solid rgb(199, 199, 199); padding: 5px; background-color: rgb(255, 255, 255);"> '; var htmlContactInfo = ''; var htmlTD2 = '</td><td id="ContactPhoto" width="80" valign="top" style="border: 1px solid rgb(199, 199, 199); padding: 5px; background- color: rgb(237, 237, 237);">'; var htmlPhoto = ''; var htmlEnd = '</td></tr></tbody></table>'; // Get element by id var element = document.getElementById('content_div'); htmlContactInfo = "<h2 style='color: rgb(180, 95, 6);'>" + prefs.getString("fullName") + "</h2><strong>" + prefs.getString("jobTitle") + "</strong><br /><i>" + prefs.getString("mobNr") + "</i><br /><a href='http://a' rel='nofollow'>" + prefs.getString("emailAddress") + "</a><br />"; htmlPhoto = '<a href="' + prefs.getString("myphoto") + '" imageanchor="1"><img height="135" border="0" alt="" src="' + prefs.getString("myphoto") + '"/></a>'; // Display HTML element.innerHTML = htmlFirst + htmlTD1 + htmlContactInfo + htmlTD2 + htmlPhoto + htmlEnd; } // Outputs debug messages if debug flag has a non-zero value function print(msg) { if (debug) { debug_html += msg; // Write debug HTML to div document.getElementById('debug_div').innerHTML = debug_html; } } _IG_RegisterOnloadHandler(init); </script> ]]> </Content> </Module> --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "iGoogle Developer Forum" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/Google-Gadgets-API?hl=en -~----------~----~----~----~------~----~------~--~---
