Advanced search  

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Pages: [1]   Go Down

Author Topic: [Solved]: Biografie und SiteURL in SubCategorie anzeigen  (Read 3321 times)

0 Members and 1 Guest are viewing this topic.

thlolymp

  • Coppermine newbie
  • Offline Offline
  • Gender: Male
  • Posts: 3
    • Fantasy-Art, Künstler unserer Zeit
[Solved]: Biografie und SiteURL in SubCategorie anzeigen
« on: August 14, 2009, 11:14:57 am »

Seit einer Woche habe ich nun Copermine auf meiner Seite laufen und es funktioniert auch alles ganz toll. Nun habe ich allerdings ein Problem, welches ich seit 2 Tagen zu lösen versuche, es aber selber leider nicht hin bekomme.
Ich möchte in den Subcat, bevor ich auf das Album klicke, die URL des jeweiligen Künstlers und die Biografie des Künstlers anzeigen. Mit der Biografie habe ich es erst einmal so gelöst, das ich die in der Albumbeschreibung ablege.
Wie kann ich ein Feld anlegen, wo ich die URL ablegen kann.
http://fantasy-art.luecom.com/index.php
« Last Edit: August 17, 2009, 09:08:14 am by Joachim Müller »
Logged

Αndré

  • Administrator
  • Coppermine addict
  • ****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15764
Re: Biografie und SiteURL in SubCategorie anzeigen
« Reply #1 on: August 14, 2009, 11:27:58 am »

Wieso schreibst du die URL nicht einfach mit in die Albenbeschreibung rein? Ansonsten kann dir das Plugin MiniCMS weiterhelfen.
Logged

thlolymp

  • Coppermine newbie
  • Offline Offline
  • Gender: Male
  • Posts: 3
    • Fantasy-Art, Künstler unserer Zeit
Re: Biografie und SiteURL in SubCategorie anzeigen
« Reply #2 on: August 14, 2009, 12:02:11 pm »

Wenn ich die URL in die Albumbeschreibung mit rein schreibe, ist sie ja nicht anklickbar. Oder täsche ich mich da?
Logged

Αndré

  • Administrator
  • Coppermine addict
  • ****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15764
Re: Biografie und SiteURL in SubCategorie anzeigen
« Reply #3 on: August 14, 2009, 12:16:35 pm »

Richtig. Wenn du folgenden Code in die Datei themes/<Dein Theme>/theme.php kopierst, lassen sie sich anklicken:
Code: [Select]
function theme_display_album_list(&$alb_list, $nbAlb, $cat, $page, $total_pages)
{

    global $CONFIG, $STATS_IN_ALB_LIST, $statistics, $template_tab_display, $template_album_list, $lang_album_list;

    $theme_alb_list_tab_tmpl = $template_tab_display;

    $theme_alb_list_tab_tmpl['left_text'] = strtr($theme_alb_list_tab_tmpl['left_text'], array('{LEFT_TEXT}' => $lang_album_list['album_on_page']));
    $theme_alb_list_tab_tmpl['inactive_tab'] = strtr($theme_alb_list_tab_tmpl['inactive_tab'], array('{LINK}' => 'index.php?cat=' . $cat . '&amp;page=%d'));
    $theme_alb_list_tab_tmpl['inactive_next_tab'] = strtr($theme_alb_list_tab_tmpl['inactive_next_tab'], array('{LINK}' => 'index.php?cat=' . $cat . '&amp;page=%d'));
    $theme_alb_list_tab_tmpl['inactive_prev_tab'] = strtr($theme_alb_list_tab_tmpl['inactive_prev_tab'], array('{LINK}' => 'index.php?cat=' . $cat . '&amp;page=%d'));

    $tabs = create_tabs($nbAlb, $page, $total_pages, $theme_alb_list_tab_tmpl);

    $album_cell = template_extract_block($template_album_list, 'album_cell');
    $empty_cell = template_extract_block($template_album_list, 'empty_cell');
    $tabs_row = template_extract_block($template_album_list, 'tabs');
    $stat_row = template_extract_block($template_album_list, 'stat_row');
    $spacer = template_extract_block($template_album_list, 'spacer');
    $header = template_extract_block($template_album_list, 'header');
    $footer = template_extract_block($template_album_list, 'footer');
    $rows_separator = template_extract_block($template_album_list, 'row_separator');

    $count = 0;

    $columns = $CONFIG['album_list_cols'];
    $column_width = ceil(100 / $columns);
    $thumb_cell_width = $CONFIG['alb_list_thumb_size'] + 2;

    starttable('100%');

    if ($STATS_IN_ALB_LIST) {
        $params = array('{STATISTICS}' => $statistics,
            '{COLUMNS}' => $columns,
            );
        echo template_eval($stat_row, $params);
    }

    echo $header;

    if (is_array($alb_list)) {
        foreach($alb_list as $album) {
            $count ++;

            $params = array('{COL_WIDTH}' => $column_width,
                '{ALBUM_TITLE}' => $album['album_title'],
                '{THUMB_CELL_WIDTH}' => $thumb_cell_width,
                '{ALB_LINK_TGT}' => "thumbnails.php?album={$album['aid']}",
                '{ALB_LINK_PIC}' => $album['thumb_pic'],
                '{ADMIN_MENU}' => $album['album_adm_menu'],
                '{ALB_DESC}' => make_clickable($album['album_desc']), // make urls in album description clickable
                '{ALB_INFOS}' => $album['album_info'],
                );

            echo template_eval($album_cell, $params);

            if ($count % $columns == 0 && $count < count($alb_list)) {
                echo $rows_separator;
            }
        }
    }

    $params = array('{COL_WIDTH}' => $column_width,
          '{SPACER}' => $thumb_cell_width
          );
    $empty_cell = template_eval($empty_cell, $params);

    while ($count++ % $columns != 0) {
        echo $empty_cell;
    }

    echo $footer;
    // Tab display
    $params = array('{COLUMNS}' => $columns,
        '{TABS}' => $tabs,
        );
    echo template_eval($tabs_row, $params);

    endtable();

    echo $spacer;
}
Logged

thlolymp

  • Coppermine newbie
  • Offline Offline
  • Gender: Male
  • Posts: 3
    • Fantasy-Art, Künstler unserer Zeit
Re: Biografie und SiteURL in SubCategorie anzeigen
« Reply #4 on: August 14, 2009, 12:38:32 pm »

Ha, SUPI.
Ich danke von ganzen Herzen. Somit ist mein Problem gelöst.

PS.: Toller Support, schnell und effektiv. Nochmal Danke
Logged
Pages: [1]   Go Up
 

Page created in 0.018 seconds with 19 queries.