Author Topic: About Aggregator, doubled  (Read 669 times)

Offline Асен Баръмов

  • Posts: 31
  • Gender: Male
    • graphic & web design
About Aggregator, doubled
« on: August 16, 2017, 02:35:53 PM »
Hello everyone!

Searching for help with Aggregator :) I have a page with a lot of subpages:
http://asen.baramov.org/pages/segashno-prodlzhitelno/bibliotechka.php?lang=BG

Every subpage is about one book (cover & some text). I wanted to use two sections of Aggregator/Enhanced Aggregator: first section shows only covers, second section shows covers and some text. First problem: First section Aggregator does not deals OK with <div> if only image must be shown. Second problem: Second section Aggregator shows the complete list of suppages (what I wanted) TWICE (and this was not what I wanted :)).

Will be very grateful for any kind of help. Thank you in advance!
smile!

Offline Асен Баръмов

  • Posts: 31
  • Gender: Male
    • graphic & web design
Re: About Aggregator, doubled
« Reply #1 on: August 17, 2017, 04:11:00 PM »
Quote
First problem: First section Aggregator does not deals OK with <div> if only image must be shown.

is resolved.

In "view.php" of Agregator I changed the lines:

Code: [Select]
//IF USER WANTS PAGE TITLES:
if($agg_settings['use_title']){ echo spacer(5) . "<h3>" . $item['page_title'] . "</h3></a>\n"; }

to:

Code: [Select]
//IF USER WANTS PAGE TITLES:
if($agg_settings['use_title']){ echo spacer(5) . "<h3>" . $item['page_title'] . "</h3>"; }
echo "</a>\n";

Any ideas about the second problem?
smile!

Offline jacobi22

  • Posts: 5579
  • Gender: Male
  • Support also via PM or EMail
    • Jacobi22
Re: About Aggregator, doubled
« Reply #2 on: August 17, 2017, 04:30:40 PM »
whats the versions number of this aggregator module?

i dont have the a-tag on this place, but any other code like

//IF USER WANTS PAGE TITLES:
        
if($agg_settings['use_title']){        echo spacer(5) . "<h3>" $item['menu_title'] . "</h3>\n"; }


        
//IF USER WANTS PAGE SUMMARIES:
        //determine what type of search we'll do for a summary element
        // - we can search for an element based on id, class, tag name,
        // class AND tag name, or perform no search at all - no summary needed.
        
if(($agg_settings['aggregate_hidden'] && ($item['visibility'] != 'hidden')) && !$wb->show_page($item) &&
        ((
$agg_settings['summary_class'] != '') || ($agg_settings['summary_tag'] != ''))){
                echo 
spacer(5) . "<p>" $MESSAGE['FRONTEND']['SORRY_NO_VIEWING_PERMISSIONS'] . "</p>\n";
        }


        if((
$agg_settings['summary_class'] != '') && ($agg_settings['summary_tag'] != '')){
                
//combined tag + class search:
                
$summary_tag get_first_element($page_source$agg_settings['summary_tag'], $agg_settings['summary_class']);
        } elseif((
$agg_settings['summary_class'] == '') && ($agg_settings['summary_tag'] != '')){
                
//tag only search:
                
$summary_tag get_first_element($page_source$agg_settings['summary_tag']);
        } elseif((
$agg_settings['summary_class'] != '') && ($agg_settings['summary_tag'] == '')){
                
//class only search:
                
$summary_tag get_first_element($page_source''$agg_settings['summary_class']);
        } else {
                
//if user class and tag fields blank, no summary is needed:
                
$summary_tag false;
        }

        echo 
spacer(4) . "</a>\n"//closing the title link


the last line closed the a-tag from the title. module version is v 1.28 / enhanced_aggregator

set some echo's in the view.php, so that you see, where it comes from (which select)
if possible / avaiable, set debug mode in the top of the view.php to TRUE, it give's some more informations, some echo's, so maybe its better / easyer to found the problem
Probleme sind da, um sie zu lösen, nicht, um nach Ausreden zu suchen.

Offline Асен Баръмов

  • Posts: 31
  • Gender: Male
    • graphic & web design
Re: About Aggregator, doubled
« Reply #3 on: August 17, 2017, 04:35:28 PM »
Module details report:

Name:   Aggregator
Type:   Page
Author:   Igor de Oliveira Couto | Pixel Media Pty. Ltd.
with many thanks to Christian Sommer and Matthias Gallas for their corrections, tips, suggestions and translations.
Version:   1.4
Designed For:   Website Baker 2.6.x

Yes, I've noticed, that there is difference between Aggregator and Enhanced Aggregator, thank you . However, I fixed for now the first problem, but still can't understand why Aggregator lists child pages twice.
smile!

Offline jacobi22

  • Posts: 5579
  • Gender: Male
  • Support also via PM or EMail
    • Jacobi22
Re: About Aggregator, doubled
« Reply #4 on: August 17, 2017, 07:06:06 PM »
Vers. 1.4 show's me also a different code, looks like my example in the top, not like your code with the included ending a-tag in the title

Question: do you use two sections of the aggregator on one page? if YES, maybe, thats the key, but i'll try it first in my locale test area

maybe you can make a simple test
go on the page overview to the section administration of this page with the aggregator section.


there you found a table with the on this page used sections and a start- and enddate for every section. pls set the enddate for the section with the image only to yesterday or a day in the past. save this changes and check the output in the frontend. do you have now a single list for all books now (picture + Description, but not twice)??

after this check, go back to the section administration, remove the enddate from the first aggregator section and set it to the second aggregator section. Any changes on the output now?

P.S.: dont be afraid, there is no risk to lost anything. its a simple timeswitch. the script compare the actualtime with a possible enddate and will not display this section, if the enddate in the past
Probleme sind da, um sie zu lösen, nicht, um nach Ausreden zu suchen.