Tagged: 

Viewing 14 posts - 1 through 14 (of 14 total)
  • Author
    Posts
  • #368218

    Hi,

    I have insert an image link on a hotspot.
    When I click on the hotspot, the photo appears, but I haven’t title at the bottom of the image (The photo have a title on the WordPress photo library).

    There is a possibility to include a fonction to insert the photo’s title on the hotspot module ?

    I try this :

    $output .= "<div class='av-image-hotspot' data-avia-tooltip-position='{$data_pos}' data-avia-tooltip-alignment='{$align}' data-avia-tooltip-class='{$tooltip_width} {$tooltip_pos} {$extraClass} {$tooltip_style} av-tt-hotspot' data-avia-tooltip='".esc_attr(ShortcodeHelper::avia_apply_autop($content))."' style='{$pos_string}'>";
    				/* AJOUT */$output .= "<".$tags[0]." title='{$alt}' class='av-image-hotspot_inner' style='{$custom_bg} {$custom_font}'>{$counter}</".$tags[1].">";
    

    and that :

    function add_hotspot($hotspot, $counter, $extraClass = "")
    			{
    				extract(shortcode_atts(array('tooltip_width' => 'av-tt-default-width', 'tooltip_pos'=>'av-tt-pos-above av-tt-align-left', 'hotspot_pos'=>'50,50', 'output'=>'', 'hotspot_color'=>'', 'custom_bg'=>'', 'custom_font'=>'', 'custom_pulse'=>'', 'tooltip_style'=>'main_color', 'link' => '', 'attachment'=>'', 'attachment_size'=>''), $hotspot['attr']));
    				$content = $hotspot['content'];
    				
    				/* AJOUT */
    				
    				if(!empty($attachment))
    				{
    					$attachment_entry = get_post( $attachment );
    					
    					if(!empty($attachment_entry))
    					{
    						$alt = get_post_meta($attachment_entry->ID, '_wp_attachment_image_alt', true);
    	                	$alt = !empty($alt) ? esc_attr($alt) : '';
    	                	$title = trim($attachment_entry->post_title) ? esc_attr($attachment_entry->post_title) : "";
    	                	
    	                	if(!empty($attachment_size))
    						{
    							$src = wp_get_attachment_image_src($attachment_entry->ID, $attachment_size);
    							$src = !empty($src[0]) ? $src[0] : "";
    						}
    					}
    				}
    				else
    				{
    					$attachment = false;
    				}
    
    				/* FIN AJOUT */

    Thanks for your help.

    #368479

    Hi _fizz!

    Thanks for using Enfold.

    I’m sorry but I’m not sure I understand what your trying to do. Are you trying to add an image inside the tooltip that displays with the hotspots?

    Go ahead and send us a link to your page so we can get a better idea of what’s going on. You can set your reply as private if you wish.

    Cheers!
    Elliott

    #368491

    An image will be more explicit (my new website is not online) :
    No title in a link on photo hotspot

    #368671

    Hey!

    If you set a title for the image in your media library then it should be displayed there. If your still having trouble then send us a link so we can get a better idea of what’s going on.

    Best regards,
    Elliott

    #368851
    This reply has been marked as private.
    #369051

    Hey!

    Switch to the text editor instead of the Visual editor and add a title to the link.

    <a title="here is a title" href="your URL goes here">
    

    Regards,
    Elliott

    #369376

    Hello,

    The problem is in the interface of admin hotspot … and if I add your link like the image below, it’s impossible to click on the link.
    link
    The result :
    Résultat

    Thanks for your help.

    #369661

    Hi!

    Your trying to add images inside the tooltips of your hotspots correct? Send us a WordPress login so we can get a better idea of what’s going on.

    Best regards,
    Elliott

    #371526

    Sorry, but I can’t give access to the website.
    We don’t want to add images inside the tooltips of our hotspots but we want to add a zoom image with a link on a hotspot.
    That’s work but the display of the title zoom image is not display.

    The problem is simple and it’s the same on all installation of Enfold.
    The “title='{$alt}'” or “title='{$title}'” in the function add_hotspot doesn’t work :
    /* AJOUT */$output .= "<".$tags[0]." title='{$alt}' class='av-image-hotspot_inner' style='{$custom_bg} {$custom_font}'>{$counter}</".$tags[1].">";

    Thanks for your help

    #371837

    Hey!

    If your adding a link inside the tooltip then the link needs a title set like so.

    <a href = "URL to your image" title = "Here is the caption">Click on me</a>
    

    Cheers!
    Elliott

    #376211

    Hi,

    It’s not possible to add a link on the hotspot. If I add this code, the hotspot doesn’t work.
    (if I add the code on the text editor it’s not possible to click on the link, it appears only during the hover on the bubble description)

    bug

    Here is how I create a hotspot :

    I click on the hotspot to edit :

    hotspot

    I add a description for the “bubble” (for the hover on the hotspot)
    description

    And I add the link of the picture for the zoom.
    link

    No field to add a title exists and if I add a html code, the hotspot doesn’t work (1st screenshot)
    It’s not possible to edit the page with a default editor too (the content is empty)
    editor

    No possibility to have the picture title ?
    resume

    Thanks for your help

    • This reply was modified 9 years, 11 months ago by _fizz.
    #376498

    Hey!

    I think I see what your trying to do now. Unfortunately I don’t see an easy way of going about that. If there was a way to grab an attachment from a URL then we could grab the title or alt from the attachment but how this works is your just setting a URL to use.

    If you’d like you can add a custom title on the line.

    $output .= "<".$tags[0]." title = 'Here is a caption' class='av-image-hotspot_inner' style='{$custom_bg} {$custom_font}'>{$counter}</".$tags[1].">";
    

    Cheers!
    Elliott

    #376810

    Hi,

    Thank you for your help.
    Do you plan an update with this option ?

    #377014

    Hey!

    I do not think we have plans for this. You can add a feature request here, https://kriesi.at/support/enfold-feature-requests/, but it seems kind of specific so I’m not sure if it will get added or not.

    Best regards,
    Elliott

Viewing 14 posts - 1 through 14 (of 14 total)
  • You must be logged in to reply to this topic.