Forum Replies Created

Viewing 1 replies (of 1 total)
  • To add more to the conversation and possibly help debug the larger issue, I’ve noticed that perfectly usable Javascript with no dependencies on relative URLs somehow “break” when placed inside a post.

    For example, I’ve been experimenting with both alexa widgets (for graphs) and statsaholic widgets (also for graphs) and neither will work when placed in a post as per the instructions of both sites.

    Sticking with the statsaholic example for the moment (because I can’t get the Alexa version to work no matter what I do), if you take the following code and stick it in an HTML file on your desktop and just open it, it will display some stats for digg, fark and slashdot.

    <!-- start Statsaholic Chartlet code - from http://www.statsaholic.com/widgets -->
    
    <a href="http://www.statsaholic.com/"
    	style="text-decoration:none;color:#999;font-family:sans-serif;font-size:11px"
    	target="_blank" title="website traffic and statistics...">
    	alexa website statistics by statsaholic
    
    <script language="JavaScript1.2" type="text/javascript"><!--
    
    	// USER-EDITABLE VARIABLES
    	// enter up to 3 domains, separated by commas
    	ah_DomainList = "slashdot.org,digg.com,fark.com";
    	ah_Width      = 400;  // width in pixels (min 325, max 400)
    	ah_Height     = 250;  // height in pixels (max 250)
    	ah_Type       = "r";  // "r" = Reach, "n" = Rank, "p" = Page Views
    	ah_Range      = "6m"; // "14d", "1m", "3m" , "6m", "1y", etc.
    	ah_BGcolor    = "eeeeee"; // hex value without "#" char (usually "ffffff")
    	// END USER-EDITABLE VARIABLES	
    
    //--></script>
    
    <script language="JavaScript1.2" type="text/javascript"
    	src="http://www.statsaholic.com/chartlet.js"></script>
    
    <!-- end Statsaholic Chartlet code block -->

    Now, if you take the same exact code and stick it in a post, it will not work. I don’t understand why since it’s the same exact code.

Viewing 1 replies (of 1 total)