API:getDocumentChildren
API:getDocumentChildrenTVars
API:getDocumentChildrenTVarOutput
I have been trying to use print_r but it just shows me blank Array (). I have setup tv’s in the container also - like image or text.
Does anyone have some simple examples to help me get strated. The API documentation is great and tried to plug that into a snippet but I cant get anything.
something simple as:
1. <?php
2. echo ( ’<pre>’ );
3. print_r($modx->documentObject); //tried getDocumentChildrenTVars but nothing pops out of the container documents.
4. echo ( ’</pre>’ );
5. die;
6. ?>
thanks bunk58 that worked - duh! identify the parent (newbie over site) any simple examples for:
API:getDocumentChildrenTVars
API:getDocumentChildrenTVarOutput
Still get nothing - maybe I don’t understand what is supposed do to or what it supposed to show. I was hoping to get an array of childdocument tv variables and what they output. eg text - image.
Thank you again.