Sustituir enlace url en lugar de la imagen lightbox

vortex Seguir

Beta
Verificación en dos pasos desactivada
Desde
26 Oct 2012
Mensajes
40
Hola tengo un slider en mi pagina de inicio y necesito eliminar el popup Lightbox para sustituirlo por una URL específica, por ejemplo a una de mis entradas. La web es Regidor Fotógrafos está en cosntrucción pero necesito solucionarlo.

Esta galería del index depende de 3 ficheros que os muestro a continuación:

index.php



<?php

/**

* The main template file.

*

* @package WordPress

*/



session_start();



if(isset($_SESSION['pp_homepage_slideshow_style']))

{

$pp_homepage_slideshow_style = $_SESSION['pp_homepage_slideshow_style'];

}

else

{

$pp_homepage_slideshow_style = get_option('pp_homepage_slideshow_style');

}

if(empty($pp_homepage_slideshow_style))

{

$pp_homepage_slideshow_style = 'flow';

}



if($pp_homepage_slideshow_style == 'youtube_video')

{

$_GET['mode'] = 'f';

}





get_header();



$pp_homepage_slideshow_cat = get_option('pp_homepage_slideshow_cat');

$homepage_items = -1;



$args = array(

'post_type' => 'attachment',

'numberposts' => $homepage_items,

'post_status' => null,

'post_parent' => $pp_homepage_slideshow_cat,

'order' => 'ASC',

'orderby' => 'menu_order',

);

$all_photo_arr = get_posts( $args );





include (TEMPLATEPATH . "/templates/template-slider-".$pp_homepage_slideshow_style.".php");



if($pp_homepage_slideshow_style != 'fullscreen')

{

get_footer();

}

?>



imageFlowXML.php



<?php

if(file_exists('../../../wp-load.php'))

{

require_once( '../../../wp-load.php' );

}

else

{

require_once( '../../../../wp-load.php' );

}





if(!isset($_GET['gallery_id']) OR empty($_GET['gallery_id']))

{

$pp_homepage_slideshow_cat = get_option('pp_homepage_slideshow_cat');

$homepage_items = -1;



$args = array(

'post_type' => 'attachment',

'numberposts' => $homepage_items,

'post_status' => null,

'post_parent' => $pp_homepage_slideshow_cat,

'order' => 'ASC',

'orderby' => 'menu_order',

);

$all_photo_arr = get_posts( $args );

}

else

{

$portfolio_items = -1;



$args = array(

'post_type' => 'attachment',

'numberposts' => $portfolio_items,

'post_status' => null,

'post_parent' => $_GET['gallery_id'],

'order' => 'ASC',

'orderby' => 'menu_order',

);

$all_photo_arr = get_posts( $args );

}





header("Content-type: text/xml");

echo '<?xml version="1.0" encoding="utf-8" ?>

<bank>';



foreach($all_photo_arr as $photo)

{

$full_image_url = wp_get_attachment_image_src( $photo->ID, 'full' );

$small_image_url = wp_get_attachment_image_src( $photo->ID, 'large' );



echo '<img>';

echo '<src>'.$small_image_url[0].'</src>';

echo '<link>'.$full_image_url[0].'</link>';

echo '<title></title>';

echo '<caption></caption>';

echo '</img>';

}



echo '</bank>';

?>

template-slider-flow.php

<div id="imageFlow">

<div class="text">

<div class="title">Loading</div>

<div class="legend">Please wait...</div>

</div>

<div class="scrollbar">

<?php

if(isset($_SESSION['pp_skin']))

{

$pp_skin = $_SESSION['pp_skin'];

}

else

{

$pp_skin = get_option('pp_skin');

}



if($pp_skin == 'light')

{

?>

<img class="track" src="<?php echo get_stylesheet_directory_uri(); ?>/images/white_slider_bg.png" alt="">

<img class="bar" src="<?php echo get_stylesheet_directory_uri(); ?>/images/white_slider_handle.png" alt="">

<?php

}

else

{

?>

<img class="track" src="<?php echo get_stylesheet_directory_uri(); ?>/images/dark_slider_bg.png" alt="">

<img class="bar" src="<?php echo get_stylesheet_directory_uri(); ?>/images/white_slider_handle.png" alt="">

<?php

}

?>

<img class="arrow-left" src="<?php echo get_stylesheet_directory_uri(); ?>/images/sl.gif" alt="">

<img class="arrow-right" src="<?php echo get_stylesheet_directory_uri(); ?>/images/sr.gif" alt="">

</div>

</div>



<div id="fancy_gallery" style="display:none">

<?php

$pp_display_image_title = get_option('pp_display_image_title');



foreach($all_photo_arr as $key => $photo)

{

$full_image_url = wp_get_attachment_image_src( $photo->ID, 'full' );

$small_image_url = wp_get_attachment_image_src( $photo->ID, 'large' );

?>

<a id="fancy_gallery<?php echo $key; ?>" href="<?php echo $full_image_url[0]; ?>" rel="gallery" <?php if(!empty($pp_display_image_title)) { ?> title="<?php echo $photo->post_title; ?>" <?php } ?>><img src="<?php echo get_stylesheet_directory_uri(); ?>/images/white_slider_handle.png" /></a>

<?php

}

?>

</div>



<?php

if(!empty($all_photo_arr))

{

?>

<script>

/* ==== create imageFlow ==== */

// div ID, imagesbank, horizon, size, zoom, border, autoscroll_start, autoscroll_interval

imf.create("imageFlow", '<?php echo get_stylesheet_directory_uri(); ?>/imageFlowXML.php', 0.6, 0.4, 0, 10, 8, 4);



jQuery(document).ready(function(){

jQuery('#footer').css('position', 'fixed');

jQuery('#footer').css('bottom', '20px');

jQuery('#footer').css('width', '100%');

jQuery('#footer').css('textAlign', 'center');

});

</script>

<?php

}

?>

funcion especifica


/* ==== diapo onclick ==== */

click : function () {

/* ---- stop autoscroll ---- */

this.parent.time = 0;

this.parent.time_out = this.parent.time_start;

if (this.parent.view == this.N) {

/* ---- click on zoomed diapo ---- */

if (this.url) {

/* ---- open hyperlink ---- */

//$j('#fancy_gallery'+this.N).trigger('click');

window.open(this.url, this.target);

} else {

/* ---- zoom in/out ---- */

/*this.z1 = this.z1 == 1 ? this.parent.zoom : 1;

this.parent.calc();*/

}

} else {

/* ---- select diapo ---- */

this.parent.view = this.N;

this.parent.calc();

}

return false;

}



Que tengo que hacer por favor que alguien me ayude.

Gracias.
 

¡Regístrate y comienza a ganar!

Beneficios

  • Gana dinero por participar
  • Gana dinero por recomendarnos
  • Descubre ofertas de empleo diariamente
  • Negocios seguros
  • ¡Información premium y más!

Acceder

¿Ya tienes una cuenta? Accede aquí

Arriba