I changed that and it looks like it works now! I guess that was the problem all along, This is good to know for future reference
It seems to me that the only thing left is that when $input is set from the passed parameter, it’s the wrong variable type.
You might try casting it:
return $xmlData->SONGHISTORY->SONG[(int)$input]->TITLE;
$input is passed in from the snippet call (not sure if thats POST or GET)
I’m not sure where your $input value comes from, but if it’s from POST or GET, those are always passed as strings.
Neither, but all snippet parameters are treated as string values when passed via a snippet tag (i.e. [[ ]] or [! !]), as well. When calling a snippet using $modx->runSnippet() however, the values will reflect the actual type that is passed in via the second parameter (an array of snippet parameters).
Quote from: sottwell at Sep 23, 2007, 11:32 AM$input is passed in from the snippet call (not sure if thats POST or GET)
I’m not sure where your $input value comes from, but if it’s from POST or GET, those are always passed as strings.
Neither, but all snippet parameters are treated as string values when passed via a snippet tag (i.e. [[ ]] or [! !]), as well. When calling a snippet using $modx->runSnippet() however, the values will reflect the actual type that is passed in via the second parameter (an array of snippet parameters).
Fatal error: Cannot redeclare get_xml_specify_ua() (previously declared in /home/fegul/public_html/modx/manager/includes/document.parser.class.inc.php(766) : eval()'d code:5) in /home/fegul/public_html/modx/manager/includes/document.parser.class.inc.php(766) : eval()'d code on line 18