We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 26016
    • 561 Posts
    Quote from: charless at May 25, 2011, 02:01 PM

    Quote from: samba at May 24, 2011, 10:46 AM


    Error: 	Invalid argument supplied for foreach()	 
      Error type/ Nr.: 	Warning - 2	 
      File: 	/blahblahblah/assets/modules/mxCalendar/includes/calendar.inc.php	 
      Line: 	454	 
      Line 454 source: 	foreach($dyn_config_opts AS $cft){ 
    



    Ok, can you provide me with a little more detail. Do you have any existing events in the system? What is your snippet call?

    It should be a quick fix, but I just want to get to root cause first.

    Cheers
    Hi Charles,
    Thanks for asking. As per above, I was able to display the empty calendar. I didn’t get this error until I added 1, count ’em 1, event. smiley I called it "Event 1"... gee, could that have killed it with a reserved word or something? (he asked rhetorically)

    My snippet call was just the plain old
    [!mxCalendar?!]


    As to the files you mentioned, I already tried getting them from that exact spot. No dice. Now, these are listed in "helpful" Google screens. I carefully copied the code and replaced the original files. So I’m loathe to try the same thing again, actually for the third time.

    Thanks, Dave

    PS - I had also earlier tried some calls using an Ajax document. I didn’t get any output, but maybe that was due to no events. I also tried making a call using a chunk, but that did not yield my chunk, it appeared to ignore it. In any case, I figured I should get the thing working at a minimal level before trying anything even slightly more complex.
      MODx and Wordpress development
      Linux, PHP 5.2, MySQL 5.0, Evo 1.05, Revo 2.08-pl, Firefox 4
      • 34084 ☆ A M B ☆
      • 756 Posts
      ok, anyway you could send me a personal message with FTP and management access.... as you should even reach that point with the latest version of the file

      thanks for your patience.

      cheers
        Evo Revo // Ubuntu, CentOS, Win // Apache 2x, Lighttp (Lighty)
        Visit CharlesMx.com for latest news and status updates.
        • 26016
        • 561 Posts
        Quote from: charless at May 25, 2011, 09:00 PM

        ok, anyway you could send me a personal message with FTP and management access.... as you should even reach that point with the latest version of the file

        thanks for your patience.

        cheers
        Charles,
        Thanks very much for that generous offer. As it happens, there’s time pressure, and I have to move on to do the rest of the site. I have given up on the calendar for now (they will probably just outsource it), and I may take you up on that another time, or wait a few more versions down the road to try it. I am very resistant to using brand new software, as I like others to fix the bugs, but your thing looked so interesting I made an exception. I’m glad it’s working for many.

        Thanks again, Dave
          MODx and Wordpress development
          Linux, PHP 5.2, MySQL 5.0, Evo 1.05, Revo 2.08-pl, Firefox 4
          • 34084 ☆ A M B ☆
          • 756 Posts
          sorry that it didn’t work for you the first go around, and the offer will remain open ....

          good luck
            Evo Revo // Ubuntu, CentOS, Win // Apache 2x, Lighttp (Lighty)
            Visit CharlesMx.com for latest news and status updates.
            • 36624
            • 535 Posts
            is it possible to use two call [!mxcalendar!] on the same page ?

            on my details view (not ajax mode) i wanted to have the calendar in list mode in a sidebar..
            but actually the list mode change to details view too.. ?!

            sidebar call (in my template) :
            [!mxcalendar? &mxcType=`list` &mxcFullCalendarPgId=`73`!]

            doc id 73 (same template but in content i put simply):
            [!mxcalendar!]

            and second question : i didn’t find a documentation with all parameters and all placeholders available? Is this planned ?

            @charless : thank you for this module, the manager part is very cool and friendly, keep up the good work !
              CTRL+SHIFT+U - Clear Cache
              CTRL+SHIFT+H - Hiding Heft Panel
              CTRL+SHIFT+N - Fast Create Resource
              CTRL+ALT+P - Preview Recource (in edit resorce window)
              CTRL+ALT+S - Save
              • 34084 ☆ A M B ☆
              • 756 Posts
              Quote from: manu at May 26, 2011, 12:46 PM

              is it possible to use two call [!mxcalendar!] on the same page ?

              on my details view (not ajax mode) i wanted to have the calendar in list mode in a sidebar..
              but actually the list mode change to details view too.. ?!

              sidebar call (in my template) :
              [!mxcalendar? &mxcType=`list` &mxcFullCalendarPgId=`73`!]

              doc id 73 (same template but in content i put simply):
              [!mxcalendar!]

              and second question : i didn’t find a documentation with all parameters and all placeholders available? Is this planned ?

              @charless : thank you for this module, the manager part is very cool and friendly, keep up the good work !

              yes, it does support two but you need to add one more parameter to the call that you want locked in the list view

              [!mxcalendar? &mxcType=`list` &mxcTypeLocked=`true` &mxcFullCalendarPgId=`73` !]


              the second question to the parameter and placeholders.... well umm eerrr not current, but yes I certainly want to get these all documented. Part of that documentation is being included in the Revolution version so that will be consistent and re-purposed for the Evo side as well.

              hope that helps, let me know if you have any further issues or questions and thanks for the support.

              cheers
                Evo Revo // Ubuntu, CentOS, Win // Apache 2x, Lighttp (Lighty)
                Visit CharlesMx.com for latest news and status updates.
                • 26016
                • 561 Posts
                Hi Charles,
                I got another chance to look at this, and got a bit further. Just as a completely random thought, I looked at the Configuration page, changed nothing, and did a Save. Remarkably, the calendar started working. smiley I actually got a couple events to work, and even display (...applause...)

                I thought I’d push my luck by trying the Ajax thing. I eventually realized that I needed to change settings in the Config. I set it to load the Google Ajax library. Tested it, no Ajax - just the blank Ajax page.

                I realized that the library autoload did not work. I hard-coded the include to the Google library in my template. OMG, I got an Ajax page to come up!?! But completely blank.

                Then I thought, well, the Ajax page has "nothing" in it, maybe try the snippet call there. I’m stunned to see that the non-parmed snippet call actually made the event code appear.

                Clearly my psychic faculties are working today. Whoa, at this rate, maybe I can get templates working (oh, I shouldn’t have said that, now I’ve put a hex on myself).

                PS: Maybe it’s on someone’s list somewhere, but I was hoping to be able to set the 24 hour time off for data entry. I tried that in the config, but still have 24 hour time.
                  MODx and Wordpress development
                  Linux, PHP 5.2, MySQL 5.0, Evo 1.05, Revo 2.08-pl, Firefox 4
                  • 34084 ☆ A M B ☆
                  • 756 Posts
                  @samba

                  Sorry that you had to do trial and error to get that going, did you see the wiki instructions
                    Evo Revo // Ubuntu, CentOS, Win // Apache 2x, Lighttp (Lighty)
                    Visit CharlesMx.com for latest news and status updates.
                    • 34084 ☆ A M B ☆
                    • 756 Posts
                    @samba

                    Sorry that you had to do trial and error to get that going, did you see the wiki instructions on how to setup the AJAX page? The config option for the 24 hour I just realized that the last update to the datepicker broke that, I’ll add it to the list to fix or adjust.

                    cheers
                      Evo Revo // Ubuntu, CentOS, Win // Apache 2x, Lighttp (Lighty)
                      Visit CharlesMx.com for latest news and status updates.
                      • 26016
                      • 561 Posts
                      Quote from: charless at Jun 01, 2011, 11:41 AM

                      @samba

                      Sorry that you had to do trial and error to get that going, did you see the wiki instructions on how to setup the AJAX page? The config option for the 24 hour I just realized that the last update to the datepicker broke that, I’ll add it to the list to fix or adjust.

                      cheers
                      Hi Charles,
                      No worries, I know that constant fiddling is the price for free software! Yes, I did read the Wiki. It’s helpful to a point, but as with any almost any documentation by coders, there are little things they just know instinctively that they need to do that us mere mortals do not.

                      That being said, guessing that I’d need to do a non-save save is not even slightly intuitive, and would be hard for you to guess. Or that the automatic include of a Javascript library in the config would simply not work at all.

                      Good thing I was thinking in a non-linear fashion, or I’d never have solved it. I’m just glad I have it working. My latest thing is that I may try to get styling happening in the Iframe, which throws out very bare HTML. If I have time, I’ll play with that, otherwise I’ll just enjoy the regular display.

                      Thanks, Dave
                        MODx and Wordpress development
                        Linux, PHP 5.2, MySQL 5.0, Evo 1.05, Revo 2.08-pl, Firefox 4