Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • saif 68 posts 88 karma points
    Feb 06, 2012 @ 13:33
    saif
    0

    Displaying Charts Inside a Web Page

    Hi All,

    I have created a column chart using razor it is working fine If I display it using macro. When I try to display it on web page using img tag.

    <p> <img src="~/macroScripts/RealTimeColumnChart.cshtml" alt="" /></p>

    it just display the image place holder without the image

    I have also tried adding this to the mime types in IIS 6.0 (win server 2003 sp2 )

    Extension: .cshtml
    Mime Type: text/html

    Any help would be really appreciated.

    regards

    saif

     

     

     

     

  • Dan Diplo 1554 posts 6205 karma points MVP 5x c-trib
    Feb 06, 2012 @ 14:26
    Dan Diplo
    0

    Why not create your function as a global @Helper method and then create a macro that calls that and writes out the entire img tag? See http://joeriks.com/2011/03/11/better-structure-for-your-razor-scripts-with-renderpage-in-umbraco/

  • saif 68 posts 88 karma points
    Feb 07, 2012 @ 13:31
    saif
    0

    Thank you Dan,

    I followed the same pattern on given link. But the problem is still as it is. When I render 

    <div>
       @RenderPage("~/macroScripts/RealTimePieChart.cshtml") 
    </div>  

     

      on my web page.

    It displays the chart all over the page please could you tell me how to display it only in a fixed portion of the page or bottom of the page.

    kind regards

    saif

Please Sign in or register to post replies

Write your reply to:

Draft