maybe it's a bug, or my fault
  • i'm using prettyPhoto for overlaying big images in the frontend of a CMS that i'm developing, and for overlaying some iframes at the backend for attaching some files... for this, i'm launching prettyPhoto from a button... but after a lot of reading, and checking my code, i found that if i don't "initialize" prettyPhoto with:

    $(document).ready(function(){ $("a[rel^='prettyPhoto']").prettyPhoto(); ]);

    this.. doesn't work

    $('#adjuntaImagen').click( function () {
    $.prettyPhoto.open('files.attachSingleImage.php?div_id=attached_images&iframe=true&width=480&height=380','','');
    });

    i don't know if this is the way that it has to be ,always attaching prettyPhoto to an anchor with rel=prettyPhoto, even if i don't have any anchor at all in the document...

    in my code i have this:

    $(document).ready(function(){
    $("a[rel^='prettyPhoto']").prettyPhoto(); //without this line prettyPhoto doesn't work.

    $('#adjuntaImagen').click( function () {
    $.prettyPhoto.open('files.attachSingleImage.php?div_id=attached_images&iframe=true&width=480&height=380','','');
    });

    $('#previsualizar').click( function () {
    $.prettyPhoto.open('noticias.preview.php?iframe=true&width=1024&height=600','Previsualizar Página','');
    });
    });

    adjuntaImagen is: attach gallery

    previsualizar is:


    thanks...

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Login with Facebook Sign In with Google Sign In with OpenID Sign In with Twitter