-
elisaparigiParticipant
hi, is it possible in the “page format gallery” make a link between the images of the gallery and a post?
I have created a page named PROJETS with the gallery of differents projets and a post for each projet in the page “list of projets” (=my “blog” page)
I have to change something in the function “minimatica_post_gallery”?
thank you very much, i hope i have be clear!Daniel TaraKeymasterYou can change the link inside the [code]<figure>[/code] element to whatever suits you, but you may want to remove the “colorbox” class since this works only on images.
elisaparigiParticipantthank you, just to see if i have understand…. I have to remove the “colorbox” class and put
<figure class=’gallery-item’>
” title=”<?php echo esc_attr( get_the_title( $attachment->ID ) ); ?>” rel=”attachment”>
sorry but i dont’ know the php….
And i have one more problem… i don’t know why but i have the menu footer now only in the page home (where there is the gallery)… in the other pages or posts no….. I think it is a backend’s problem because i did’nt change the footer function or the <?php get_footer(); ?> in the page.php and single.php
thank you very much for your support!
Daniel TaraKeymasterWhat you need to change is the [code]href[/code] attribute of the [code][/code] element.
elisaparigiParticipantsorry
i wished whrite….<figure class=’gallery-item’>
” title=”<?php echo esc_attr( get_the_title( $attachment->ID ) ); ?>” rel=”attachment”>
elisaparigiParticipantsorry….. i whrite a think … with href….but after this is the result….
i try to comment
//<figure class=’gallery-item’>//” title=”<?php //echo esc_attr( get_the_title( $attachment->ID ) ); ?>” rel=”attachment”>
//” title=”<?php echo esc_attr( get_the_title( $attachment->ID ) ); ?>” //rel=”attachment”>
ok…. the function that i have to put in the href is wp_get_post
thanks!
elisaparigiParticipantit does’nt work….
but the function that i have to put inside href is wp_get_post?
thank you…. and for the my footer problem do you have any idea?thank thank thank
Daniel TaraKeymasterFrom what I understood, the function you need to put is [code]echo get_permalink( $post->ID )[/code] with the post ID you wish to show a link to passed as a parameter.
You must be logged in to reply to this topic.