We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 29076
    • 615 Posts
    I’m sorry that I ask as a total newbee (absolutely not a bad thing in it self), but I’ve tried to get the tvExplorer to work, with no result yet. Could some of you who allready got it working, please set up a detailed step by step guide on how to set up tvExplorer and get it to work on the front end? Please. smiley

    I’ve seen the examples and the explanations, but my mind doesn’t seem to work in the same way, so I have to admit I just don’t understand how to use it. cool
      I think, thererfor I am! But what I am, and why...?
      • 27749
      • 53 Posts
      Hi,
      I am getting constantly this error:

      PHP error debug
      Error: Invalid argument supplied for foreach()
      Error type/ Nr.: Warning - 2
      File: /www/doc/www.bdl-cee.com/www/2.0/assets/modules/tvEditor/class/tveditor.class.php
      Line: 785
      Line 785 source: foreach($tvFormElements as $name => $element){

      after I installed tvEditor module, the extenders, the ditto hack.. The editor runs quite fine (sometimes there is an error) but calling [!tvExplorer? &dittoName=`Ditto` dittoSnippetParameters=`parents:1`!] ends up with the code above..
        • 11975
        • 2,542 Posts
        Hi,

        @ sylvaticus:
        the basic requirements are explained in this thread (I guess) but basically you need:
        1/ create a form containing tveTags which describes ths tvs to search
        Tags have the following syntaxes [+tve.tvName:param->value+]
        2/ add a tvExplorer call with required params(&dittoName &formTPL) followed by two placeholders [+tve.searchForm+] and tve.dittoList

        @smiley &formTPL is mandatory

        I’m almost done with the new version which fixed a lot of bugs and improves performance with a cache system.

        :-)
          Made with MODx : [url=http://www.copadel.com]copadel, fruits et l
          • 29076
          • 615 Posts
          Quote from: heliotrope at Jul 28, 2008, 04:18 AM

          I’m almost done with the new version which fixed a lot of bugs and improves performance with a cache system.
          I really look foreward to the new version, and I do appreciate your hard work on this. I just have to get it to work first.  smiley
          Quote from: heliotrope at Jul 28, 2008, 04:18 AM

          the basic requirements are explained in this thread (I guess) but basically you need:
          1/ create a form containing tveTags which describes ths tvs to search
          Tags have the following syntaxes [+tve.tvName:param->value+]
          2/ add a tvExplorer call with required params(&dittoName &formTPL) followed by two placeholders [+tve.searchForm+] and tve.dittoList

          I guess this is a little like a carengine. Tell the guy who invented and constructed the engine to take it apart and put it together again, and he will do without a blink, beacuse he knows exactly how it’s built and he has everything in his mind.

          Then ask another person to do the same. One who has not seen the engine other than the outer parts. He will have a problem, because he doesn’t have the hole thing in his mind. Well, he can make it by learning how the engine is constructed and maybe by taking it apart and put it toghether again. But it would be allot more easier with a good manual. smiley

          I will, for my part, try to learn how an engine is buildt, how it works and how to take it apart and put it together again.  I will definitely try. wink
            I think, thererfor I am! But what I am, and why...?
            • 27749
            • 53 Posts
            Quote from: heliotrope at Jul 28, 2008, 04:18 AM

            @smiley &formTPL is mandatory

            thanks for reminder smiley

            I did this:

            [[tvExplorer? &dittoName=`Ditto` &dittoSnippetParameters=`parents:1` &formTPL=`form` ]]
            [+tve.searchForm+]
            [+tve.dittoList+]

            and:

            <form action="[~[*id*]~]" method="get" >
            <input type="hidden" name="id" value="[*id*]" />

            <fieldset>
            [+tve.tags:filter->9:label->Tags:tvtype->select+]
            </fieldset>

            <fieldset class="sendForm">
            <input type="submit" name="search" value="Search" />
            </fieldset>
            </form>

            And - there is no error - but also nothing shows up. I am trying to display anything. Just to figure out how it works.
            What I need is a check box array where you can check which documents to show. The "tags" for the checkboxes are stored in a tv called "tags" and it is a multi-select box.
              • 11975
              • 2,542 Posts
              If you don’ t hae PHx plugin running set the call uncached [! or uncache the page.
              If PHx is on, call the snippet [[ and uncache the page.

              :-)
                Made with MODx : [url=http://www.copadel.com]copadel, fruits et l
                • 27749
                • 53 Posts
                thx - silly me - that helped and now it displays something.
                other problem (yeah yeah.. I know..): drop down list and select box work fine, but not the checkboxes.
                if I set the tv to multiselect and a delimiter with , it generates:
                <input class="checkbox" type="checkbox" id="tags_1"  name="[b]tags[][/b]" value="kina" checked="checked" />

                and either nothing happens or modx escapes with:

                Error: 	urlencode() expects parameter 1 to be string, array given	 
                  Error type/ Nr.: 	Warning - 2	 
                  File: 	/www/doc/www.bdl-cee.com/www/2.0/assets/snippets/jot/jot.class.inc.php	 
                  Line: 	897	 
                  Line 897 source: 	$urlstring[] = $name . '=' . urlencode($value); 

                Which might be caused by the [] in the URL (x.html?id=133&tags[]=kina&search=Search)

                But sometimes when using select it is ok... wiered
                  • 11975
                  • 2,542 Posts
                  If the form is on line please post your url smiley

                  I you’re not under the rush, you should wait for the next version.

                  :-)
                    Made with MODx : [url=http://www.copadel.com]copadel, fruits et l
                    • 27749
                    • 53 Posts
                    :-) here is the URL (its kind of a sandbox for texting..) (the stuff on the right side is plain html)
                    http://bdl-cee.com/2.0/x.html

                    I kept this functions of the web for the end as I knew this will be a little pain.. Of course I am looking forward the new version smiley
                      • 11975
                      • 2,542 Posts
                      Could you remove the Jot Call ?
                      It seems that the error comes from it

                      :-)
                        Made with MODx : [url=http://www.copadel.com]copadel, fruits et l