Advanced search  

News:

cpg1.5.36 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.34 or older update to this latest version as soon as possible.
[more]

Pages: [1]   Go Down

Author Topic: Details about the uploaded files ??  (Read 34891 times)

0 Members and 1 Guest are viewing this topic.

altenae

  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Posts: 231
Details about the uploaded files ??
« on: October 29, 2011, 08:37:20 PM »

The manual says:

You'll be sent to a screen where you can enter details about the uploaded files. After filling in, submit that form using the "Apply changes" button at the bottom of that form.

I would expect to see only the uploaded files.
However I (and others not admin) see al there files for that Album.

Question is this how it suppose to work ?

Edward
 
Logged

Phill Luckhurst

  • Administrator
  • Coppermine addict
  • *****
  • Country: gb
  • Offline Offline
  • Gender: Male
  • Posts: 4281
    • Windsurf.me
Re: Details about the uploaded files ??
« Reply #1 on: October 30, 2011, 01:04:08 AM »

It works exactly as you see it, you will see all the files from the user. Cannot remember why that ay as chosen though.
Logged
It is a mistake to think you can solve any major problems just with potatoes.

altenae

  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Posts: 231
Re: Details about the uploaded files ??
« Reply #2 on: October 30, 2011, 09:40:43 AM »

Is there a way to see only the uploaded files ?

Edward
Logged

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15212
Re: Details about the uploaded files ??
« Reply #3 on: November 03, 2011, 05:11:14 PM »

Coppermine doesn't store the upload queue, so it's not possible to display only the files you just uploaded as-is.

It should be possible to submit the timestamp of the upload form initialization and just display files with a later timestamp. This might be a good (configurable) addition to the next Coppermine release.


I'm currently short of time, so I cannot create the solution yet. Please reply to this thread so I don't miss this thread.
Logged

Phill Luckhurst

  • Administrator
  • Coppermine addict
  • *****
  • Country: gb
  • Offline Offline
  • Gender: Male
  • Posts: 4281
    • Windsurf.me
Re: Details about the uploaded files ??
« Reply #4 on: November 03, 2011, 05:48:58 PM »

I suppose in a way that depends on whether we stick with the Flash uploader or go another route.
Logged
It is a mistake to think you can solve any major problems just with potatoes.

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15212
Re: Details about the uploaded files ??
« Reply #5 on: November 17, 2011, 06:04:26 PM »

Please apply the following code changes and report if it works as expected.

1. Open upload.php, find
Code: [Select]
set_js_var('max_upl_size', $CONFIG['max_upl_size']);and below, add
Code: [Select]
set_js_var('timestamp', time());

2. Open js/setup_swf_upload.js, find
Code: [Select]
window.location = js_vars.site_url + '/editpics.php?album=' + $("select[name='album']").val();and replace with
Code: [Select]
window.location = js_vars.site_url + '/editpics.php?album=' + $("select[name='album']").val() + '&newer_than=' + js_vars.timestamp;

3. Open editpics.php, find
Code: [Select]
$result = cpg_db_query($sql . $owner_str);and above, add
Code: [Select]
    // Display only the files from the last queue after flash upload
    if ($superCage->get->keyExists('newer_than')) {
        $owner_str .= " AND ctime > '".$superCage->get->getInt('newer_than')."'";
    }

find
Code: [Select]
$next_target = $CPG_PHP_SELF . '?album=' . $album_id . '&start=' . ($start + $count) . '&count=' . $count . (UPLOAD_APPROVAL_MODE ? '&mode=upload_approval' : '');
$prev_target = $CPG_PHP_SELF . '?album=' . $album_id . '&start=' . max(0, $start - $count) . '&count=' . $count . (UPLOAD_APPROVAL_MODE ? '&mode=upload_approval' : '');
and replace with
Code: [Select]
$newer_than = $superCage->get->keyExists('newer_than') ? "&newer_than=".$superCage->get->getInt('newer_than') : '';

$next_target = $CPG_PHP_SELF . '?album=' . $album_id . '&start=' . ($start + $count) . '&count=' . $count . (UPLOAD_APPROVAL_MODE ? '&mode=upload_approval' : '') . $newer_than;
$prev_target = $CPG_PHP_SELF . '?album=' . $album_id . '&start=' . max(0, $start - $count) . '&count=' . $count . (UPLOAD_APPROVAL_MODE ? '&mode=upload_approval' : '') . $newer_than;

find
Code: [Select]
$form_target = $CPG_PHP_SELF . '?album=' . $album_id . '&start=' . $start . '&count=' . $count;and replace with
Code: [Select]
$form_target = $CPG_PHP_SELF . '?album=' . $album_id . '&start=' . $start . '&count=' . $count . $newer_than;
find
Code: [Select]
<select onchange="if(this.options[this.selectedIndex].value) window.location.href='{$CPG_PHP_SELF}?album=$album_id$mode&amp;start=$start&amp;count='+this.options[this.selectedIndex].value;"  name="count" class="listbox">and replace with
Code: [Select]
<select onchange="if(this.options[this.selectedIndex].value) window.location.href='{$CPG_PHP_SELF}?album=$album_id$mode&amp;start=$start&amp;count='+this.options[this.selectedIndex].value+'$newer_than'"  name="count" class="listbox">

Imo we should add this feature to the core code if it works as expected (even to the cpg1.5.x branch).
Logged

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15212
Re: Details about the uploaded files ??
« Reply #6 on: January 31, 2012, 10:22:07 AM »

Does the mod work as expected?
Logged

Phill Luckhurst

  • Administrator
  • Coppermine addict
  • *****
  • Country: gb
  • Offline Offline
  • Gender: Male
  • Posts: 4281
    • Windsurf.me
Re: Details about the uploaded files ??
« Reply #7 on: February 01, 2012, 07:40:49 PM »

It does for me.
Logged
It is a mistake to think you can solve any major problems just with potatoes.

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15212
Re: Details about the uploaded files ??
« Reply #8 on: March 08, 2012, 05:39:30 PM »

Committed changes in SVN revision 8323 for cpg1.5.x and cpg1.6.x.
Logged
Pages: [1]   Go Up
 

Page created in 0.067 seconds with 19 queries.