Tagged: Air Compressor Parts Supplier
- 2016-02-20 at 07:18 #7080kforerParticipant
I tried using a custom template but apparently they’re not available for the filebrowser (?). Now I’m trying to put an IF/ELSE clause in the default filebrowser template it’s not working.
I have one pdf that needs to appear listed in two parent categories. The main category, inside parent cat_id=6, is primary and file_display_name is its default Name.
In the second listing, based on secondary categories which are children of parent cat_id=5, it should use the file_custom_cf1 for Title. (in the code below, 9, 1 and 7 are subcategories I tried in case it can’t query for parent categories.)
I’m trying the code below in the Default filebrowser template and it’s not working.
%file_small_icon% <br /> <!– IF %cat_id% == (5,9,1,7) –><a href="%file_url%" title="Download %file_custom_cf1%">%file_custom_cf1%</a><br /><!-- ELSE --> <a href="%file_url%" title="Télécharger %file_display_name%">%file_display_name%</a> (%file_size%)<!– ENDIF –>
It ignores the IF/ELSE and results in both the file_custom_cf1 and the file_display_name.
How can I fix this? Thank you!
2016-02-20 at 07:49 #7082kforerParticipant
- This topic was modified 7 years, 7 months ago by kforer. Reason: clarity
I tried turning it around, IF %cat_id% != 6, and I see that Of course, the file itself is still 6, only the Secondary Category’s parent is 5 (or 9,1,7… for the file). It works fine in lists but not as a query. I’m now trying
<!– IF %file_sec_cats% == 'North America' –>
but that’s not a good query as All the files have secondary categories whether they’re being called from it or not. The only way would be to make a custom template and apply it to cat_id=6 but that’s not possible with the file browser. Any help is most appreciated!
2020-08-25 at 10:45 #14479usaiaspartsParticipant
- This reply was modified 7 years, 7 months ago by kforer.
Searching for the best air compressor parts supplier online? Buy Industrial Air Supplies at the best online prices. Shop the right parts at the best value.
- You must be logged in to reply to this topic.