What's wrong with this conditional statement
-
Hello,
I am using a custom post type called ‘artists’ to display a profile of them. As part of this i wish to display a number of pictures related to each artist profile and for this i am using the ‘Metaslider’ plugin.
I have updated content-artist.php with the following IF/ELSE IF/ELSE loop:
<div align=center> <?php if ( 'artist' == get_post_type( (is_single( 'Tereska Shepherd - Watercolour' ) ) ) ) { // custom post title echo do_shortcode("[metaslider id=3944]"); } elseif ( 'artist' == get_post_type( (is_single( 'Alison Holt - Embroidery' ) ) ) ) { // custom post title echo do_shortcode("[metaslider id=3945]"); } else { } ?> </div>
Currently, Metaslider id=3944 displays on both artist profiles, so i’m guessing there might be something wrong with the above code. Can anyone suggest what might be wrong?
Many thanks
Viewing 6 replies - 1 through 6 (of 6 total)
Viewing 6 replies - 1 through 6 (of 6 total)
- The topic ‘What's wrong with this conditional statement’ is closed to new replies.