I finally got the grasp of Ditto, but I’m getting some odd results. I’m getting the results I want, but I’m also getting unwanted information. It seems Ditto is pulling in double the information - populating my template with the default TV information doubling the amount of results I get. Anyone know why this would be happening?
Thanks!
-
MODX Staff
- 12,272 Posts
Without seeing your call, document tree structure, ditto and modx versions and ditto templates, that’s really hard to deduce.
Ryan Thrash, MODX Co-Founder
Follow me on Twitter at @rthrash or catch my occasional unofficial thoughts at thrash.me
Sorry about that.
[[Ditto?parents=`0`&depth=`0`&tpl=`preview`&display=`all`]]
ModX 0.9.6
Ditto 2.0.2
HOME
+PROPERTIES
-Property 1
-Property 2
-Property 3
-Property 4
ABOUT US
CONTACT
-
MODX Staff
- 12,272 Posts
Try first to upgrade to the latest SVN version of Ditto found by visiting the ditto support site at ditto.modxcms.com. If that doesn’t work, show us the contents of your {{preview}} template. Good luck!
Ryan Thrash, MODX Co-Founder
Follow me on Twitter at @rthrash or catch my occasional unofficial thoughts at thrash.me
OK, I replaced the code and this is what I got from Ditto 2.1 SVN:
Fatal error: Call to undefined function: parseorderby() in /public_html/property/manager/includes/document.parser.class.inc.php(766) : eval()’d code on line 779
Here is the {{preview}} chunk:
<div class="prop_summary">
<span class="prev_img">
<a href="[~[+id+]~]">[+propImage+]</a>
</span>
<span class="prev_info">
<h1>[+address+]</h1>
<p>Rent: [+rentPrice+]
Available: [+vacancy+]
Bedrooms: [+beds+]
Bathrooms: [+baths+]
Square Feet: [+sqfoot+] sq/ft
</p>
</span>
<span class="view_prop">
<a href="[~[+id+]~]"><img src="assets/templates/mja1/images/button.gif" alt="button" /></a>
</span>
</div>
Ryan,
I updated everything and I double checked, updated again. Finally, got rid of the error, but the same issue persists. It’s weird because it is displaying some of these bogus properties amongst valid ones. Strange.
Thanks
Please provide the debug output of the call by completing the following steps:
* Append &debug=`1` to the call
* Click "Save Debug Console"
* Rename the extension to .txt
* Attach to your post
Indeed it is unwanted. I am having the same issue. I upgraded the core earlier today, but the issue has remained. I have checked my Ditto snippet and it is current. I ran the debug and have attached it. I was curious after seeing the debug, so I looked at the source of my other page using ditto and it has information from other pages in the page source, but the info is not visible.