Details
-
Type: Bug
-
Status: Done/Fixed
-
Priority: Major
-
Resolution: Fixed/Completed
-
Affects Version/s: 4.4.6
-
Fix Version/s: 4.5.3
-
Component/s: CiviCRM Profile
-
Labels:None
-
Documentation Required?:None
Description
This probably affects current versions (4.5.x) but I was not able to test in the demo.
To see the bug go to
https://new.thewordguild.com/find-a-writer/find-a-book-or-author/?page=CiviCRM&q=civicrm/profile&page=CiviCRM&force=1&gid=15&crmRowCount=25&reset=1
Go to the second page of results or filter on Last Name = Orchard. You see several books by Sandra Orchard with the correct book cover images. Click View on any except the first one. It always shows the image of the first one in the detail view.
For example, https://new.thewordguild.com/find-a-writer/find-a-book-or-author/?page=CiviCRM&q=civicrm/profile/view&reset=1&id=5962&gid=15&multiRecord=view&recordId=40&allFields=1 shows the book cover for Deadly Devotion instead of Identity Withheld.
Looking at the HTML, the file reference is always id=1 when it should be something else. In this example, the image URL is:
https://new.thewordguild.com/find-a-writer/find-a-book-or-author/?page=CiviCRM&q=civicrm/file&reset=1&id=1&eid=5962
but it should be
https://new.thewordguild.com/find-a-writer/find-a-book-or-author/?page=CiviCRM&q=civicrm/file&reset=1&id=37&eid=5962
It looks like the problem might be in CRM/Core/BAO/CustomField.php but I don't know the code well enough to even try a fix.