Comcode page link with image rollover
|
Posted
#89029
(In Topic #18024)
|
|
|---|---|
|
Fan in action |
No mouseover image changeUsing image as a page link: Initial image works, and the link works, but there's no 'rollover' image change. Code
[codebox][page="standards:teachersonly"][img="Go To" align="bottom" title="Go To" rollover="themes/Opus_Unita/images_custom/coda2_s.png"]themes/Opus_Unita/images_custom/coda_s.png[/img] [/page][/codebox]
Image paths valid.
"I think ...therefore I'm in a mess..."
|
|
Posted
|
|
|
Community saint |
Do you have a Samsung Galaxy S / Galaxy S II ? If so, why not check out my ScreenFree FM Radio .
|
|
Posted
|
|
|
Fan in action |
I'd tried the absolute, since I had noted that the javascript wasn't rendering the 'rollover' image source as fully qualified, but the main image was being rendered as absolute. As in the below 'rendered source' for two "page links". Code
Code
[codebox][font size="1.2em"]<b>PSD Music Evidence Outcomes by Level</b>[/font] [page="esources:evoutcomes"][img="Go To" align="bottom" title="Go To" rollover="themes/Opus_Unita/images_custom/coda2_s.png"]themes/Opus_Unita/images_custom/coda_s.png[/img] [/page]
I'm wondering if this is javascript issue related to HTTPS based site /cross scripting?. I don't need the rollover effect for this, implemented it through the 'learning' curve, and noted it doesn't work, in this case of 'page links', haven't the straight-up 'image rollover' elsewhere... yet. Just inside the 'page link'.
"I think ...therefore I'm in a mess..."
|
|
Posted
|
|
|
Community saint |
The IMG tag is missing an id attribute. This can be fixed by editing the COMCODE_IMG.tpl template and changing: Code
<img{+START,IF_NON_EMPTY,{ALIGN}} style="vertical-align: {ALIGN|}"{+END} src="{URL*}" title="{+START,IF_PASSED,TOOLTIP}{$STRIP_TAGS,{TOOLTIP}}{+END}{+START,IF_NON_PASSED,TOOLTIP}{$STRIP_TAGS,{CAPTION}}{+END}" alt="{$STRIP_TAGS,{CAPTION}}" />
Code
<img{+START,IF_NON_EMPTY,{ALIGN}} style="vertical-align: {ALIGN|}"{+END} src="{URL*}" {+START,IF_PASSED,ROLLOVER}id="{$GET%,RAND_ID_IMG}"{+END} title="{+START,IF_PASSED,TOOLTIP}{$STRIP_TAGS,{TOOLTIP}}{+END}{+START,IF_NON_PASSED,TOOLTIP}{$STRIP_TAGS,{CAPTION}}{+END}" alt="{$STRIP_TAGS,{CAPTION}}" />
Do you have a Samsung Galaxy S / Galaxy S II ? If so, why not check out my ScreenFree FM Radio .
|
|
Posted
|
|
|
Community saint |
Do you have a Samsung Galaxy S / Galaxy S II ? If so, why not check out my ScreenFree FM Radio .
|
|
Posted
|
|
|
Fan in action |
That got it working... for 'page links' right off the comcode link wizard... in order to get it working right for external links, I finally came up with a mish-mash of code... all kinds of xml validation probs otherwise, it seemed. Was Nuts! Screwy! For external this is what resolves it, after changing the template code you gave: Code
"some text defining the external page  "
accompanied by a tiny 'superscript' "external link" image with the link's title tooltip. Since I didn't need or want that little thingy hovering by my link image, and had the link "defining text" next to the image, easiest/safest way to get rid of it for me was to go to my theme's global.css down about line 3980 under 'Link Type Display' classes and comment out Code
a[target="_blank"] {background: url('{$IMG;,filetypes/external_link}') no-repeat right top; padding-right:10px;}
Thanks Temp! Mike
"I think ...therefore I'm in a mess..."
|
|
Posted
|
|
|
Community saint |
|
|
Posted
|
|
|
Fan in action |
I thought another newbie might want to know how to get rid of that superscript new window thingy... That rollover fix is due to Temp1024 finding the fault in the template. The crazy zoo of code possibilities for an old fool like me that I ran into trying to come up with that simple ext page linking nearly drove me back to drinking. Looks simple, now that's it there, doesn't it? duh. But I couldn't get past the validation checks on page preview, and have it working, with anything else. Gotta wonder how I could get so obsessed with something glitzy that wasn't even necessary to get the simple effect of 'go to' something 'from here'. Now, moving on to real issues.... Cheers! Mike
"I think ...therefore I'm in a mess..."
|
| Important! |
Posted
|
|
ocStaff (admin) |
Automated fix messageThis issue has been filed on the tracker as issue #721, with a fix. If I answered something that you think should be in the documentation, please take the initiative and add it to the community documentation. We really need people to help out here and build a well-organised large support resource. |
| Important! | |
|
Posted
|
|
|
Fan in action |
"I think ...therefore I'm in a mess..."
|
1 guests and 0 members have just viewed this: None
Control functions:









