Copied to clipboard

Flag this post as spam?

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


  • Brad Ford 34 posts 75 karma points
    Jul 22, 2013 @ 03:59
    Brad Ford
    0

    Contour - Prefix 'Poll' is not defined

    I am trying to follow Tim's example on how to use Contour to add a poll. That can be found on his 'nibble' blog here..

    http://www.nibble.be/?p=81

     

    My solution has a project called 'UserControls' for want of a better name that holds UserControls, forms and  WebServices that are copied to my Umbraco project when I compile.

    Using Tim's example I created this class

    namespace UserControls
    {
        [XsltExtension]
        public class Poll
        {
            public static XPathNodeIterator PossibleAnswers(string guid)
            {
                  . . .
            }

    Back in Umbraco I created a new XLST file and in it put the xslt code from Tim's page.

    Or course I had to fix this line to set to my Namespace and class...

    <xsl:for-each select="contourpoll:PossibleAnswers($formid)//question">

    So I clicked on the Insert xslt:valueof button and selected Get Extentions link. My UserControls.Poll class was there and in it the PossibleAnswers method. All looked good. It exists.

    I love it when stuff just works first go..  

    So I add that and use the select param that gets created to modify Tim's code.. So it looks like this.

    <xsl:for-each select="UserControls.Poll:PossibleAnswers($formid)//question">

    Then I try to Save.

    Not defined? But the Get Extension button FOUND IT. How can it be 'Not defined'?

    Even if I leave the code that the Get Extentions button dropped there, it also gets the same error.

    Huh?

    I'm using

    Umbraco version 6.1.1

    Contour version 3.0.12

     

     

     

     

     

     

     

     

     

  • Brad Ford 34 posts 75 karma points
    Jul 22, 2013 @ 04:02
    Brad Ford
    0

    As a test I copied the class code out and put it in the app_code folder of Umbraco.

    That worked the same way. The Get Exention button found it.

    But I got the same error as above when saving. Not Defined.

  • This forum is in read-only mode while we transition to the new forum.

    You can continue this topic on the new forum by tapping the "Continue discussion" link below.

Please Sign in or register to post replies