We use cookies to improve your experience. No personal information is gathered and we don't serve ads. Cookies Policy.

ExpressionEngine Logo ExpressionEngine
Features Pricing Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University
Log In or Sign Up
Log In Sign Up
ExpressionEngine Logo
Features Pro new Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University Blog
  • Home
  • Forums

Random String - solution found

How Do I?

IC360 (Oliver Cannell)'s avatar
IC360 (Oliver Cannell)
248 posts
10 years ago
IC360 (Oliver Cannell)'s avatar IC360 (Oliver Cannell)

One of my customer’s sites blew a fuse this week, and I’d like to share the solution with you all, in case you have a similar problem.

Some of the Product Category pages weren’t listing any products and the Product pages themselves were outputting a load of strings like:

M 0 0 o 9 3 H 7 p Q 0 9 L 8 X 1 t 4 9 c H Y 0 1 Z 5 j 4 T T 9 1 f G f r

(PS. I’m not able to paste the code in here without the spaces, as it just gets displayed a “1”. Weird!)

I tried upgrading EE from 2.8.1 to 2.9.3 and upgrading all the Plugins to the latest versions, but it made no difference.

I’m using the Segments of the URL to drive the content of the site pages, by using the Plugins below in the following way:

{exp:category_id category_group="1" category_url_title="{segment_4}" parse="inward"}
 {exp:child_categories parent="{category_id}" child_categories_sort_direction="asc" show_empty="yes"}

https://devot-ee.com/add-ons/category-id https://devot-ee.com/add-ons/child-categories

I discovered that there was another Entry (from a different channel) that had the same URL Title as one of the problem Products. By changing the URL Title of that Entry, the Product page loaded correctly again. So, I decided to add a channel=”products” variable to the code, like this, to force it look at only the Products Entries:

{exp:category_id category_group="1" category_url_title="{segment_4}" parse="inward"}
 {exp:child_categories parent="{category_id}" child_categories_sort_direction="asc" show_empty="yes" channel="products"}

Secondly, I found that by adding a dynamic=”no” variable when outputting Products to the Product Category pages, all the missing Products appeared again:

{exp:channel:entries channel="products" category="{embed:category_id}" dynamic="no"}
       

Reply

Sign In To Reply

ExpressionEngine Home Features Pro Contact Version Support
Learn Docs University Forums
Resources Support Add-Ons Partners Blog
Privacy Terms Trademark Use License

Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.