Button-style picture link?
Moderators: Alexander Halser, Tim Green
-
- Posts: 38
- Joined: Tue Jun 07, 2011 10:03 am
Button-style picture link?
I can make a topic link as a predefined button with custom text. And I can make a topic link to be a custom picture. But what if I want my custom picture link to act like a button (i.e., to change when I hover over it and click it)? Is that possible or are picture links "static"?
- Tim Green
- Site Admin
- Posts: 23189
- Joined: Mon Jun 24, 2002 9:11 am
- Location: Bruehl, Germany
- Contact:
Re: Button-style picture link?
Hi Alexey,
Use an image toggle for this. You can define the "small" version to be a different image, and you would use a button image for that. The only restriction on this is that it must be a click event, you can't define it to expand on mouseover. You must also turn off lightbox mode in Configuration > Publishing Options > HTML Help/Webhelp > HTML Export Options, otherwise the expanded image will be displayed in a lightbox overlay instead of inline.
Use an image toggle for this. You can define the "small" version to be a different image, and you would use a button image for that. The only restriction on this is that it must be a click event, you can't define it to expand on mouseover. You must also turn off lightbox mode in Configuration > Publishing Options > HTML Help/Webhelp > HTML Export Options, otherwise the expanded image will be displayed in a lightbox overlay instead of inline.
Regards,
Tim (EC Software Documentation & User Support)
Private support:
Please do not email or PM me with private support requests -- post to the forum directly.
Tim (EC Software Documentation & User Support)
Private support:
Please do not email or PM me with private support requests -- post to the forum directly.
-
- Posts: 38
- Joined: Tue Jun 07, 2011 10:03 am
Re: Button-style picture link?
But a toggle picture can't be a link, can it?
- Tim Green
- Site Admin
- Posts: 23189
- Joined: Mon Jun 24, 2002 9:11 am
- Location: Bruehl, Germany
- Contact:
Re: Button-style picture link?
No, but wouldn't a link that expands when you click on it be a bit distracting/confusing. It might be interesting the first time but I think quite soon you would find it annoying, like blinking text...Alexey Zhebel wrote:But a toggle picture can't be a link, can it?
Regards,
Tim (EC Software Documentation & User Support)
Private support:
Please do not email or PM me with private support requests -- post to the forum directly.
Tim (EC Software Documentation & User Support)
Private support:
Please do not email or PM me with private support requests -- post to the forum directly.
- Martin Wynne
- Posts: 2656
- Joined: Mon May 12, 2003 3:21 pm
- Location: West of the Severn, UK
Re: Button-style picture link?
Hi Alexey,Alexey Zhebel wrote:I can make a topic link as a predefined button with custom text. And I can make a topic link to be a custom picture. But what if I want my custom picture link to act like a button (i.e., to change when I hover over it and click it)? Is that possible or are picture links "static"?
Unless you need PDF output, often the easiest solution for CHM and Webhelp is to Insert HTML Code Object and write your own code:
1. create two images of your button, say button_dead_abc.png and button_live_abc.png to represent the normal and mouse-over appearance of your button. Put the image files in your Baggage Files.
2. then to create a working button link to say topic ID topic_abc put something like this in an HTML Code Object:
Code: Select all
<a href="topic_abc.htm"
onmouseout="document.getElementById('button_abc_1').src='button_dead_abc.png'"
onmouseover="document.getElementById('button_abc_1').src='button_live_abc.png'">
<img id="button_abc_1" border="0" src="button_dead_abc.png" title="go to topic abc" alt="button link to topic abc">
</a>
regards,
Martin.
-
- Posts: 38
- Joined: Tue Jun 07, 2011 10:03 am
Re: Button-style picture link?
Thanks, Martin. That seems like a nice workaround.