Help changing text links by images in im store links

Tagged: , , , ,

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #54418
    danielgm
    Participant

    Hi:

    In my site http://hoyosfotoestudio.com/venzuela

    private gallery example:

    id de galería: prueba
    contraseña: 1234567

    As you can see I’m changing some im store text links and buttons by images links.

    I was able to do it in some places -not sure the right way ;)- changing the php code of the plugin.

    I’jm not able to do this with the links in the left upper side. 🙁 ¿Can you help me with this?

    If there is a more “elegant ” or right way to make what I’ve made “my way” please let me Know.

    I have very limited and general programming knowledge, but I can edit the files you tell me.

    If it is possible I prefer to make this changes not edit the php code of the pluging, could these changes be made with css in my themes preferences? If not tell me what files and how to do it.

    Thanks in Advance!

    Daniel,

    #54455
    Xpark Media
    Keymaster

    @danielgm,

    The plugin uses it’s on hooks just like WordPress to allow you to make modification without editing the code. That way you can update the plugin at any time.

    You can use is these two hooks

    function  change_image_store_links( $link, $data ){
    
      if( $data[ 'value' ] == 'something'  ){
        // modify link here
        $link = "my-new-link";
      }
      return $link;
    }
    add_filter( 'ims_image_link', 'change_image_store_links' )
    

    You can use add_filter( 'ims_image_data', 'my_function' ) to modify the data provided in the previous function.

    You can add additional links by using add_filter( 'ims_image_tag_meta', 'my_function' )

    I hope this helps

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