Forum Replies Created

Viewing 4 replies - 1 through 4 (of 4 total)
  • Thread Starter peter_s

    (@peter_s)

    Alright, thanks mbrsolution for your help.
    Overall I achieved what I wanted with CataBlog by editing the single-catablog-items.php by “hand”.

    I’ll try to figure out how to achieve the same thing but through WordPress’ CataBlog admind panel with templates later on. I’m still kind of confused how one would do it, but I’ll read your tutorial more thoroughly to get a better understanding.

    Thread Starter peter_s

    (@peter_s)

    As far as I understand Catablog: you can’t do anything about the templates vie Catablog admin interface in WordPress when wanting to display individual items.

    There’s even an article on the Catablog site that exaplain if you wish to edit the view of individual items then you need to edit single-catablog-items.php or taxonomy-xxx-xxx.php. And you can’t use tokens there.

    Thread Starter peter_s

    (@peter_s)

    I think I’ve partially figured it out.
    This is what I’ve put into the single-catablog-items.php:

    <?php
    	$catablog_data = get_post_meta(get_the_ID(), "catablog-post-meta", true);
    
    	$originalsPath = $wp_plugin_catablog_class->urls['originals'] . "/";
    	$subImages = $catablog_data['sub-images'];
    	var_dump($catablog_data);
    ?>
    
    <!DOCTYPE html>
    <html>
    	<head>
    		<title><!-- How to put item title here? --></title>
    	</head>
    	<body>
    
    <a href="javascript:history.back()">Back</a>
    
    <img src="<?php echo $originalsPath . $catablog_data['image']; ?>" />
    
    <?php foreach ($subImages as $subImage): ?>
      <img src="<?php echo $originalsPath . $subImage; ?>" />
    <?php endforeach; ?>
    	</body>
    </html>

    Last thing I can’t figure out is how to retrieve the item’s title too?
    Because get_post_meta() doesn’t give me the title and description data of the item I’ve clicked on.

    Thread Starter peter_s

    (@peter_s)

    mbrsolution,

    I’m using my own template that is basically an exact copy of the default one, but I’ve removed the %BUYBUTTON% and %SUBIMAGES%.

    What I want to do is when I click on one of the catablog items that are all listed on my page – the site would open an individual page with that item’s detailed info and sub-images.

    What you’re suggesting for me to do – I already did. I have the catablog items displying properly, but I want to make a separate details page for each item that gets generated when click on one of the items.

    Update:

    So this is what I basically want to do. I’ve already did the left part of the image plan, but I need to somehow now do the right part:

    Plan image

Viewing 4 replies - 1 through 4 (of 4 total)