Page 1 of 1

Output wild card use in PHP exec

Posted: 2015-07-06T21:00:06-07:00
by gweiss27
Maybe you can help me with one more thing. I'm trying to dynamically name my files with numbering but I can't get the wildcards to work.

This is my EXEC code:
  • $new_file = $dir_name . '/' . $file_name_base . '_Page_';

    $cmd = '/usr/local/bin/convert ' .
    ' -density ' . $compression .
    ' -profile USWebCoatedSWOP.icc ' .
    $file_name .
    ' -profile sRGB_v4_ICC_preference.icc ' .
    ' -scene 1' .
    ' -trim ' .
    ' -resize x1732 ' .
    ' -quality ' . $compressQuality .
    ' ' . $new_file . '%+02d'. $ext;
but this is what I get out.

EvilErnie_04_Page_%+02d-1.jpg

Thoughts?

Re: Output wild card use in PHP exec

Posted: 2015-07-07T17:14:44-07:00
by fmw42
'%+02d
try %02d without the +