We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 20289
    • 958 Posts
    thanks, but any idea about what causes the error?
      [img]http://i10.tinypic.com/52c4eir.gif[/img][/td]
      [td][Wiki] [Persian support forum]
      [SVN] [RTL SVN Branch] [bugs] [FishEye+Crucible] [Learn MODx!] | [My Google Code]
      [font=tahoma][برای دسترسی به راهنمای فارسی به [url=http://www.modxcms.ir]
      • 17412
      • 270 Posts
      Parse error: syntax error, unexpected T_VARIABLE, expecting '(' in /var/www/html/diocese/assets/snippets/modcast/js/category.php on line 14


      I’m also getting this. Anyone found a solution?
        • 7923
        • 4,213 Posts
        In /assets/snippets/modcast/js/category.php,

        try changing line 14 from this:

        switch $pirate['topCategoryTAG'] {


        to this:

        switch ($pirate['topCategoryTAG']) {


          "He can have a lollipop any time he wants to. That's what it means to be a programmer."
          • 17412
          • 270 Posts
          Thanks Doze. That clears up the error message but now results to a blank page :0
          I guess this snippet needs some love.
            • 7923
            • 4,213 Posts
            Yeah, I guess so.. Maybe it’s server environment related though because there have been quite many downloads and not many bug reports for this.. Would be nice if someone with problematic environment could debug it.


              "He can have a lollipop any time he wants to. That's what it means to be a programmer."
              • 6180
              • 31 Posts
              I too had the parse error issue. I googled around and found the solution.

              First, the response from Doze worked to get me past the first problem in the category.php file:
              unexpected T_VARIABLE, expected "(".

              Enclosing the "switch" parameter at line 14 with perenthesis got me rolling there.
              switch ($pirate['topCategoryTAG']) {


              The next issue I saw threw the following error:
              parse error, unexpected T_CONSTANT_ENCAPSED_STRING, expecting ’,’ or ’;’

              This I resolved by editing lines 50-101 to ensure all array items were properly syntaxed.
              new Array("'.$jsBlank.'");


              The original file often left off the trailing period.

              With those items set, and making sure the document had Cacheable turned off, I was successful in walking through the configuration of a podcast.
                • 33982 ☆ A M B ☆
                • 476 Posts
                Hey CwnAnnwn...thanks a million for catching that error and explaining the fix. Unfortunately I haven’t yet learned PHP and your solution fixed my problem. I was pulling my hair out trying to find the problem.

                I’ve installed Modcast on 3 different servers with 3 different results. It’s definitely particular to the server you put it on.

                Thanks!
                  Precision Web Development ... SmashStack.com
                  • 26190
                  • 1 Posts
                  Hey, all. I recently installed the snippet successfully (thanks to the solutions in this forum!) but when I tried to access the feed, it says:

                  XML Parsing Error: junk after document element


                  and

                  [font=Verdana]<b>Fatal error</b>:  Cannot redeclare stripjunk() (previously declared in C:\xampp\htdocs\victory\manager\includes\document.parser.class.inc.php(769) : eval()'d code:193) in <b>C:\xampp\htdocs\victory\manager\includes\document.parser.class.inc.php(769) : eval()'d code</b> on line <b>200</b><br />[/font]


                  Help!
                    • 21778
                    • 223 Posts
                    Can someone upload the category.php page updated?
                      • 23849
                      • 223 Posts
                      I’ve gotten all the way to the point of calling the MODcast snippet, but when I do (in a blank page set to xml) I get the following error in firefox:

                      XML Parsing Error: must not undeclare prefix
                      Location: http://dwellchurch.com/dwell-podcasts
                      Line Number 2, Column 1:<rss xmlns:itunes="" version="2.0">
                      ^

                      When viewing the source I get none of the information that is now in the .php file created by the admin. The page is definitely set to un-cached... any ideas?

                      http://dwellchurch.com/dwell-podcasts
                        Nick Hoag
                        Creative Partner
                        The FutureForward

                        http://thefutureforward.com