You need to sign in to do that
Don't have an account?
Farihin Ghaffar
visualforce page coding - unnecessary blank space
Hello – I created a visualforce page to allow a contact image to be added to the contact creation page. It worked out fine, but I have a lot of blank space around the image so now the fields after it are so far away. Does anyone know how I can shrink the empty spaces?
Below is the visualforce code I used:
1. <apex:page standardController="Contact">
2.
3. <apex:repeat value="{!Contact.Attachments}" var="att">
4.
5. <apex:image width="100" height="100" rendered="{!att.ContentType='image/jpeg'}" value="{!URLFOR($Action.Attachment.Download, att.Id)}"/>
6.
7. </apex:repeat>
8.
9. </apex:page>
Below is the visualforce code I used:
1. <apex:page standardController="Contact">
2.
3. <apex:repeat value="{!Contact.Attachments}" var="att">
4.
5. <apex:image width="100" height="100" rendered="{!att.ContentType='image/jpeg'}" value="{!URLFOR($Action.Attachment.Download, att.Id)}"/>
6.
7. </apex:repeat>
8.
9. </apex:page>
James Loghry
I would try condensing the tags so that they're loser together. In other words, remove empty lines 4 and 6. It could also be that your width and height are set incorrectly and thus the images are looking odd.