Invision Community 4: SEO, prepare for v5 and dormant account notifications By Matt Monday at 02:04 PM
Gauravk Posted July 10, 2015 Posted July 10, 2015 I made a car review page with IP Content with Title, description and image field and sadly images are displaying so weird, instead of neat thumbnails in end or in top. Please help in advising how to add images correctly in IP Content 4.0.9 Thanks. http://carnity.org/car-reviews/records/2016-audi-q7-r1/
Gauravk Posted July 12, 2015 Author Posted July 12, 2015 Gentle reminder guys, am I asking so impossible thing or is it known bug and everyone here is quite and patiently waiting for the full moon....?
Ralf Herrmann Posted July 12, 2015 Posted July 12, 2015 It isn’t a bug. By default, additional database fields will be shown as inline list above the body field. For other positions and layouts you would need a customized article template. But to offer a simpler solution: Go to your image field settings. Go to the display options tab and scroll down to the Display View Format of the Display Template. Select “Custom” there and put this in the text field. <div class="ipsClearfix"> {{foreach $value as $image}} <a href='{file="$image" extension="cms_Records"}' class='ipsAttachLink ipsAttachLink_image' rel='external nofollow' target='_blank' data-ipslightbox='' data-ipslightbox-group="g1"> <img style="height:100px" src='{file="$image" extension="cms_Records"}'> </a> {{endforeach}} </div> Your images will then be shown like this:
Gauravk Posted July 12, 2015 Author Posted July 12, 2015 Thanks Ralf,I will send this editing possibility to the programmer. On a separate note see the last frustrating comment from a programmer who worked in previous version, Is there is any he can edit different templates for different IP Content pages: Classified, Business Listing etc in carnity.org? And how he can get hold of all individual fields? (see below comment from him).The main problem is that I cannot access the values one by one.In the last version it was like:{$r['price']}{$r['trim_option']}...In this version it is just:{{foreach $record->customFieldsForDisplay('listing') as $fieldId => $fieldValue}}{{if $fieldValue}}{$fieldValue|raw}{{endif}}{{endforeach}}--> I cannot style the values individually
Ralf Herrmann Posted July 12, 2015 Posted July 12, 2015 Is there is any he can edit different templates for different IP Content pages: Classified, Business Listing etc Certainly. And how he can get hold of all individual fields? (see below comment from him). The new field calls are all explained in the field settings.
Gauravk Posted July 12, 2015 Author Posted July 12, 2015 Thanks Ralf,For prompt reply, can you please explain how he can edit different template for different pages...?
Ralf Herrmann Posted July 12, 2015 Posted July 12, 2015 One just creates a new template, which then can be assigned to any database one wants in the database settings. That was no different in 3.4.
Gauravk Posted July 12, 2015 Author Posted July 12, 2015 Thanks Ralf, your code brought some immediate relief in images display and I shared same with my programmer for more details. Hope he should be able to fix things with your help now. Really appreciate your help.
Gauravk Posted August 4, 2015 Author Posted August 4, 2015 Hi Ralf, Im using your suggest codes for images in few areas and seeing some images broken icon or images are not loading at all. Can you please help. http://carnity.com/business_listing/car-care-services/car-wash-polishing/test-company-llc-r641/ http://carnity.com/business_listing/car-care-services/car-wash-polishing/zabeel-car-cleaning-r61/ http://carnity.com/business_listing/car-care-services/car-wash-polishing/my-car-polish-r256/ http://carnity.com/classifieds And every time any of the broken image page load it logs the attached error. <br><br><div class="ipsClearfix"> {{foreach $value as $image}} <a href='{file="$image" extension="cms_Records"}' class='ipsAttachLink ipsAttachLink_image' rel='external nofollow' target='_blank' data-ipslightbox='' data-ipslightbox-group="g1"> <img style="height:100px" src='{file="$image" extension="cms_Records"}'> </a> {{endforeach}} </div><br>
Recommended Posts
Archived
This topic is now archived and is closed to further replies.