Jump to content

gmclelland

Members
  • Posts

    566
  • Joined

  • Last visited

  • Days Won

    6

Posts posted by gmclelland

  1. Hi tpr.  Feature Request: If possible one thing I would like to see is better consistency for replacing files in file and image fields.  This is a task that content editors have to do constantly, so I would like to make it dead simple and obvious.

    Here is some quick mockups:

    For image fields:

    Image field.jpg

    When the "Replace Image" Button is clicked, a modal dialog pops up.

    Edit-Image-Modal.jpg

    For File Fields:

    Same thing...It opens a dialog to replace the file

    ReplaceFile.jpg

    Any thoughts?

    • Like 2
  2. I see the problem... I installed the site with pwshell and didn't set a timezone.

    In the response there was this warning

    Warning: strtotime(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone.

    As soon as I set the timezone in the config.php everything started working.  Sorry for the alert

    • Like 1
  3. After reading the comment in the scss file

    // AdminTweaks (default theme tweaks)
    // note: the default theme adds theme name class only to body, AOS adds to html

    maybe AOS isn't adding the class "AdminThemeDefault" to the html element in the default admin theme in AdminOnSteriods.module line 243?

  4. I just updated to v056 and here are my html element classes

    <html class=" headSticky HoverDropdown moduleCompact moduleModal" lang="en">

    and

    <body class="id-10 template-admin hasWireTabs AdminThemeDefault ProcessPageEdit-id-1015 ProcessPageEdit-template-left-sidebar pw-ready InputfieldColumnWidthsInit">

    So I have classes now, but the header still isn't sticking.  Sorry... I'm trying to find the problem as well.

  5. Strange.  It still didn't work.  I clicked the clear compiled files button at /admin/module/.  I also did a module refresh.  I'm using the latest Google Chrome on a mac.

    Here are my body classes when editing a page.

    id-10 template-admin hasWireTabs AdminThemeDefault ProcessPageEdit-id-1002 ProcessPageEdit-template-basic-page pw-ready InputfieldColumnWidthsInit

  6. Just wanted to let you know that the sticky header isn't sticking for me with the latest 3.0.32 devns and the default theme.  Seems like it started after I upgraded to 3.0.32.  I'm also using the latest AOS.  I have hard refresh the browser several times.

  7. I haven't tried it yet, but this module looks great!

    I'm guessing the Media files are stored using PW pages?  Is there any way to add more fields to those PW pages?  For example, I might want to use a text field to store where I got the image from.

    I'm also curious how the File Usage works?

    1. Does it just count and list the pages where the media file is used in a media field.
    2. Does it also take into consideration files that have been inserted into text areas?
    3. Does it include pages with text areas that link to the files?
  8. I'm so confused.  Today it just started working.  I didn't even do anything.  Maybe opcache related?  Even tested on different PW2 and PW3 sites.

    HI @adrian and @horst.  I tried Tracy debugger and here is what it shows (see attachment)

    It also confirmed that I was editing the correct php.ini file.

    Thank you both for your help.  I'm hoping it won't happen again :)

     

    Test | My Processwire Site.jpg

    • Like 3
  9. Well crap, now for some reason I can't upload images or files on my mac.  Same problem, but I'm just using core image and file fields.  It was working, I'm not sure what changed?  This happens with PW2 and PW3 sites when I try to upload the files.

    I've tried the same in firefox, chrome, and safari.
    When I check my response in Chrome it shows the following:

    <br />
    <b>Deprecated</b>:  Automatically populating $HTTP_RAW_POST_DATA is deprecated and will be removed in a future version. To avoid this warning set 'always_populate_raw_post_data' to '-1' in php.ini and use the php://input stream instead. in <b>Unknown</b> on line <b>0</b><br />
    <br />
    <b>Warning</b>:  Cannot modify header information - headers already sent in <b>Unknown</b> on line <b>0</b><br />
    [{"error":false,"message":"Added file: globals.jpg","file":"\/site\/assets\/files\/1002\/globals.jpg","size":25337,"markup":"\n\t<li id='file_91ef455ec27970cb238861b2c8895d64' class='InputfieldFileItem InputfieldImage ui-widget'>\n\t\t<p class='InputfieldFileInfo InputfieldItemHeader ui-widget ui-widget-header ui-helper-clearfix'>\n\t\t\t<span class='HideIfSingle HideIfEmpty InputfieldFileDrag'><i class='fa fa-sort'><\/i> <\/span>\n\t\t\t<i class='fa fa-caret-right InputfieldFileDrag HideIfMultiple'><\/i> \n\t\t\t<label class='InputfieldFileDelete'><input type='checkbox' name='delete_images_91ef455ec27970cb238861b2c8895d64' value='1' title='Delete' \/><i class='fa fa-fw fa-trash'><\/i><\/label>\n\t\t\t<a class='InputfieldFileMove InputfieldFileMoveBottom' href='#' title='Move to bottom'><i class='fa fa-fw fa-angle-double-down'><\/i><\/a> \n\t\t\t<a class='InputfieldFileMove InputfieldFileMoveTop' href='#' title='Move to top'><i class='fa fa-fw fa-angle-double-up'><\/i><\/a> \n\t\t\t<a class='InputfieldFileName pw-modal pw-modal-large' title='globals.jpg: globals.jpg (281x386)' href='\/admin\/page\/image\/edit\/?id=1002&file=1002,globals.jpg&rte=0&field=images' data-buttons='#non_rte_dialog_buttons button' data-autoclose='1' data-close='#non_rte_cancel'>globals.jpg <i class='fa fa-pencil ui-priority-secondary'><\/i><\/a> \n\t\t\t<span class='InputfieldFileStats'>25 kB, 281x386  <\/span> \n\t\t<\/p>\n\t\t<div class='InputfieldFileData ui-widget ui-widget-content'>\n\t\t\t<div class='InputfieldImagePreview'>\n\t\t\t\t<a class='InputfieldFileLink' target='_blank' href='\/site\/assets\/files\/1002\/globals.jpg?nc=10'><img height=\"100\" src=\"\/site\/assets\/files\/1002\/globals.0x100.jpg?nc=1452724334\" alt=\"\" data-gridsize=\"100\"  \/><\/a>\n\t\t\t\t<div class='InputfieldImageActions'>\n\t\t\t\t\t<a title='globals.jpg (281x386)' href='\/admin\/page\/image\/edit\/?id=1002&file=1002,globals.jpg&rte=0&field=images' class='pw-modal pw-modal-large' data-buttons='#non_rte_dialog_buttons button' data-autoclose='1' data-close='#non_rte_cancel'><i class='fa fa-fw fa-crop'><\/i><\/a>\n\t\t\t\t<\/div>\n\t\t\t<\/div>\n\t\t\t<div class='InputfieldFileDescription'><label for='description_images_91ef455ec27970cb238861b2c8895d64' class='detail'>Description<\/label><input type='text' name='description_images_91ef455ec27970cb238861b2c8895d64' id='description_images_91ef455ec27970cb238861b2c8895d64' value='' \/><\/div>\n\t\t\t<input class='InputfieldFileSort' type='text' name='sort_images_91ef455ec27970cb238861b2c8895d64' value='0' \/>\n\t\t<\/div>\n\t<\/li>","replace":false,"overwrite":0}]

    I tried disabling xdebug, turning off php error warnings, turning off debug mode in Processwire, always_populate_raw_post_data = -1 and 0 in my php.ini all while restarting apache between each change.

    In my PHP error logs I get:

    [Fri Jul 29 19:01:42.816150 2016] [:error] [pid 900] [client 127.0.0.1:50397] PHP Deprecated:  Automatically populating $HTTP_RAW_POST_DATA is deprecated and will be removed in a future version. To avoid this warning set 'always_populate_raw_post_data' to '-1' in php.ini and use the php://input stream instead. in Unknown on line 0, referer: http://pw3.dev/admin/page/edit/?id=1019
    [Fri Jul 29 19:01:42.816467 2016] [:error] [pid 900] [client 127.0.0.1:50397] PHP Warning:  Cannot modify header information - headers already sent in Unknown on line 0, referer: http://pw3.dev/admin/page/edit/?id=1019

    I'm running PHP 5.6.24 / Apache/2.4.18 on my mac installed with homebrew.

    Any other help is appreciated

     

  10. Maybe you could try updating PHP to 5.6?  I think PHP 5.4 is unsupported now anyways?

    Maybe also check your upload_tmp_dir = "/tmp" in php.ini is set to the correct location for your OS.

    I'm not sure what else to try...:(

    You might list your Operating Systems as well in case others chime in here to help.... maybe upload your php.ini file?

    • Like 1
  11. Few questions for you:

    How did you install php on your setup?

    What version of php are you running?

    Is xdebug installed?

    I installed php via homebrew on a mac using php 5.6.23.

    Using always_populate_raw_post_data = -1 didn't work for me.

    I had to update/reinstall php with 

    brew unlink php56

    brew unlink php56-mcrypt

    brew unlink php56-xdebug

    brew install php56

    brew install php56-mcrypt

    brew install php56-xdebug

    restart apache and then it started working

    Note: In the github issue I stated that it was only working with xdebug enabled, but now(after following the steps above) I can run it with xdebug disabled.

    Hope that helps

    • Like 1
×
×
  • Create New...