Demo

Probiere ClanSphere aus und teste daran herum. Demo


Antworten: 8
Seite [1]
Tress13


Highlander




Herkunft: Lüdenscheid
Beiträge: 3048
# Thema - 10.09.2009 um 15:23 Uhr
Ich habe mir die Neue listcat für die Downloads installiert.
Hab das auch ein wenig meinen Bedürfnissen angepasst.

Bloss find ich nirgends die Werte für die Grösse des Vorschaubildes.

Kann mir evntl jemand helfen ???

Hab schon in der listcat.php geschaut und so...
Finds aber nicht.
Ist doch bestimmt über System/Options irgendwie zu regeln, oder ???



------------------


www.iv-gaming.de | www.iv-artwork.de
Inaktiv
palle ClanSphere Team

Supporter
Supporter




Beiträge: 3073
# Antwort: 1 - 10.09.2009 um 15:52 Uhr
der inhalt der listcat.php könnte hilfreich sein...


------------------
I like the part where it says 'nyan'



Inaktiv
|
Tress13
Thread-Ersteller


Highlander




Herkunft: Lüdenscheid
Beiträge: 3048
# Antwort: 2 - 10.09.2009 um 22:53 Uhr
mehr... +-
<?php
// ClanSphere 2009 - www.clansphere.net
// $Id: listcat.php 3009 2009-05-03 14:57:11Z hajo $

$cs_lang = cs_translate('files');
require_once 'mods/clansphere/filetype.php';

$data = array();

$files_size = '';

empty($_REQUEST['start']) ? $start = 0 : $start = $_REQUEST['start'];
$categories_id = $_REQUEST['where'];
settype($categories_id,'integer');
$where = "categories_id = '" . $categories_id . "'";

$cs_sort[1] = 'files_name DESC';
$cs_sort[2] = 'files_name ASC';
$cs_sort[3] = 'files_time DESC';
$cs_sort[4] = 'files_time ASC';
$cs_sort[5] = 'files_size DESC';
$cs_sort[6] = 'files_size ASC';
empty($_REQUEST['sort']) ? $sort = 2 : $sort = $_REQUEST['sort'];
$order = $cs_sort[$sort];

$categories = cs_sql_select(__FILE__,'categories','categories_name'," categories_id = '" . $categories_id . "'");
$data['category']['name'] = $categories['categories_name'];
$data['category']['count'] = cs_sql_count(__FILE__,'files',$where);

$data['category']['paginator'] = cs_pages('files','listcat',$data['category'][' count'],$start,$categories_id,$sort);

$from = 'files fls INNER JOIN {pre}_users usr ON fls.users_id = usr.users_id';
$select = 'fls.files_name AS files_name, fls.users_id AS users_id, usr.users_nick';
$select .= ' AS users_nick, usr.users_active AS users_active, fls.files_time AS files_time, fls.files_id AS files_id, fls.files_mirror AS files_mirror';
$select .= ', fls.files_mirror AS files_mirror, fls.files_size AS files_size, fls.files_count AS files_count, fls.files_mirror AS files_mirror, fls.files_previews AS files_previews, fls.files_version AS files_version, fls.files_description AS files_description';
$cs_files = cs_sql_select(__FILE__,$from,$select,$where,$order,$start,$account['users_l imit']);
$files_loop = count($cs_files);

$data['sort']['name'] = cs_sort('files','listcat',$start,$categories_id,1,$sort);
$data['sort']['date'] = cs_sort('files','listcat',$start,$categories_id,3,$sort);
$data['sort']['big'] = cs_sort('files','listcat',$start,$categories_id,5,$sort);

$data['files'] = array();

for($run=0; $run<$files_loop; $run++) {

$data['files'][$run]['id'] = $cs_files[$run]['files_id'];
$data['files'][$run]['name'] = $cs_files[$run]['files_name'];
$data['files'][$run]['version'] = cs_secure($cs_files[$run]['files_version']);
$data['files'][$run]['user'] = $cs_files[$run]['users_nick'];
$data['files'][$run]['date'] = cs_date('unix',$cs_files[$run]['files_time'],1);
$data['files'][$run]['size'] = '';
$data['files'][$run]['description'] = cs_secure($cs_files[$run]['files_description'],1,1);

$data['files'][$run]['count'] = cs_secure($cs_files[$run]['files_count']);

$data['files'][$run]['size'] = cs_filesize($cs_files[$run]['files_size']);

// START PREVIEW ADDED BY Ramires
$data['files'][$run]['if']['preview'] = false;
if(!empty($cs_files[$run]['files_previews'])) {
$data['files'][$run]['if']['preview'] = true;

$files_pics = explode("\n",$cs_files[$run]['files_previews']);
$count = 0;
foreach($files_pics AS $pic) {
$data['files'][$run]['previews'][$count]['image'] = cs_html_img('uploads/files/thumb-' . $pic);
$data['files'][$run]['previews'][$count]['path'] = 'uploads/files/picture-' . $pic;
$count++;
}
}
// STOP PREVIEW ADDED BY Ramires

$data['files'][$run]['filetypes'] = array();
$files_mirror = $cs_files[$run]['files_mirror'];
$temp = explode("-----", $files_mirror);
$temp_loop = count($temp);
$file_typ_array = array();
$run_3 = '0';
for ($run_2 = 1; $run_2 < $temp_loop; $run_2++) {
$temp_a = explode("\n", $temp[$run_2]);
if(in_array($temp_a['3'],$file_typ_array,TRUE)) {} else {
$file_typ_array[$run_3] = $temp_a['3'];
$run_3++;
}
}
$loop_file_typ_array = count($file_typ_array);
for ($run_2 = 0; $run_2 < $loop_file_typ_array; $run_2++) {
$ext = $file_typ_array[$run_2];

$data['files'][$run]['filetypes'][$run_2]['icon'] = cs_filetype($ext);
}
// START DOWNLOAD BUTTON ADDED BY Ramires
$data['files'][$run]['mirrors'] = array();
$files_mirror = $cs_files[$run]['files_mirror'];
$temp = explode("-----", $files_mirror);
$temp_loop2 = count($temp);

if (isset($_REQUEST['target']))
{
$files_cells = array('files_count');
$files_save = array(++$cs_file[$run]['files_count']);
cs_sql_update(__FILE__,'files',$files_cells,$files_save,$file_id);
$temp_a = explode("\n", $temp[$_REQUEST['target']]);
$select_mirrow = $temp_a['1'];
header("location:".$select_mirrow."");
}

require_once 'mods/clansphere/filetype.php';

for ($run_4 = 1; $run_4 < $temp_loop2; $run_4++)
{

$temp_a = explode("\n", $temp[$run_4]);
if($account['access_files'] >= $temp_a['4'])
{
$data['files'][$run]['mirrors'][$run_4-1]['name'] = empty($temp_a['2']) ? $temp_a['1'] : $temp_a['2'];
$data['files'][$run]['mirrors'][$run_4-1]['id'] = $run_4;

$data['files'][$run]['mirrors'][$run_4-1]['filetype_ima ge'] = cs_filetype($temp_a['3']);
$data['files'][$run]['mirrors'][$run_4-1]['filetype_nam e'] = $temp_a['3'];
}
}
// STOP DOWNLOAD BUTTON ADDED BY Ramires
}

echo cs_subtemplate(__FILE__,$data,'files','listcat');


------------------


www.iv-gaming.de | www.iv-artwork.de

Inaktiv
|
palle ClanSphere Team

Supporter
Supporter




Beiträge: 3073
# Antwort: 3 - 11.09.2009 um 11:38 Uhr
UNGETESTET

hättest du das als php quelltext gepostet könnte ich dir die zeilen nennen so musst du nun folgende absatz suchen...

$data['files'][$run]['previews'][$count]['image'] = cs_html_img('uploads/files/thumb-' . $pic);
$data['files'][$run]['previews'][$count]['path'] = 'uploads/files/picture-' . $pic;

ersetzen durch

$data['files'][$run]['previews'][$count]['image'] = cs_html_img('uploads/files/thumb-' . $pic,100,100);
$data['files'][$run]['previews'][$count]['path'] = 'uploads/files/picture-' . $pic,100,100;


nun sollte das bild in zB 100x100 angezeigt werden ^^



------------------
I like the part where it says 'nyan'



Zuletzt editiert von PAlle! ClanSphere Team am 11.09.2009 um 11:39 Uhr (2x Editiert)
Inaktiv
|
duRiel ClanSphere Team


Weltmeister




Herkunft: Cambridge
Beiträge: 7300
# Antwort: 4 - 11.09.2009 um 15:48 Uhr
hab mir den thread nicht durch gelesen aber die letzte zeile von palle verursacht garantiert einen parse error.


Inaktiv
|
palle ClanSphere Team

Supporter
Supporter




Beiträge: 3073
# Antwort: 5 - 11.09.2009 um 16:15 Uhr
ja, omg ich depp... nur das

$data['files'][$run]['previews'][$count]['image'] = cs_html_img('uploads/files/thumb-' . $pic);

gegen das

$data['files'][$run]['previews'][$count]['image'] = cs_html_img('uploads/files/thumb-' . $pic,100,100);


danke duriel


------------------
I like the part where it says 'nyan'



Zuletzt editiert von PAlle! ClanSphere Team am 11.09.2009 um 16:15 Uhr (2x Editiert)
Inaktiv
|
Tress13
Thread-Ersteller


Highlander




Herkunft: Lüdenscheid
Beiträge: 3048
# Antwort: 6 - 12.09.2009 um 13:42 Uhr
OK, hab's mal probiert.
Es geht, nur sind meine Bilder nicht alle Quadratisch.
Die werden dann verzerrt angezeigt !

Gibt' vlt noch ne andere Lösung ???


------------------


www.iv-gaming.de | www.iv-artwork.de

Inaktiv
|
palle ClanSphere Team

Supporter
Supporter




Beiträge: 3073
# Antwort: 7 - 12.09.2009 um 14:07 Uhr
für die 100x100 kannst du doch einsetzten was du willst oO das war nur ein beispiel


------------------
I like the part where it says 'nyan'



Inaktiv
|
Tress13
Thread-Ersteller


Highlander




Herkunft: Lüdenscheid
Beiträge: 3048
# Antwort: 8 - 12.09.2009 um 14:21 Uhr
Ja weiss ich, nur die Bilder sind ALLE unterschiedlich.
Hab z.B Header, dann auch Logo's die Quadratisch sind usw.


------------------


www.iv-gaming.de | www.iv-artwork.de

Inaktiv
|
Antworten: 8
Seite [1]


Sie müssen sich registrieren, um zu antworten.