• twitter image
  • facebook image
  • youtube image
  • linkedin image
Language: CMS Made Simple Czech CMS Made Simple France CMS Made Simple Spain CMS Made Simple Hungary CMS Made Simple Russia CMS Made Simple Netherlands

All times are UTC




Post new topic Reply to topic  [ 8 posts ] 
Author Message
 Post subject: [fixed] Drag and drop gives wrong json response
PostPosted: Thu Jun 21, 2012 7:50 am 
Offline
Power Poster
Power Poster

Joined: Sun Apr 19, 2009 9:33 am
Posts: 1372
Rev: 8071

When dropping a file on the 'upload' zone (top right corner) the dashed retancle blinks green.. the percentage indicator is changing but the file is not uploaded.

On Content -> File Manager [Upload files]-tab the dashed dropzone gives no feedback when dropping a file. No file is uploaded.

Os: Windows 7

HTTP_USER_AGENT Mozilla/5.0 (Windows NT 6.1; WOW64; rv:9.0.1) Gecko/20100101 Firefox/9.0.1

By looking at the json response from FireBug I saw:

Code:
-----------------------------4827543632391 Content-Disposition: form-data; name="mact" FileManager,m33f11,upload,0 -----------------------------4827543632391 Content-Disposition: form-data; name="_sx_" 8583d4f7 -----------------------------4827543632391 Content-Disposition: form-data; name="disable_buffer" 1 -----------------------------4827543632391 Content-Disposition: form-data; name="m33f11files[]"; filename="31122011045.jpg" Content-Type: image/jpeg

[{"name":"31122011045.jpg","size":false,"type":"image\/jpeg","delete_url":"http:\/\/beta.biesheuvel.lan\/admin\/class.jquery_upload_handler.php?file=31122011045.jpg","delete_type":"DELETE"}]


Same result with a .pdf file:

Code:
[{"name":"test_2012.pdf","size":false,"type":"application\/pdf","delete_url":"http:\/\/beta.biesheuvel.lan\/admin\/class.jquery_upload_handler.php?file=test_2012.pdf","delete_type":"DELETE"}]



ad1) Same response for Google Chrome:

HTTP_USER_AGENT: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/536.5 (KHTML, like Gecko) Chrome/19.0.1084.56 Safari/536.5

Code:
 {name:test_2012.pdf, size:false, type:application/pdf,…}
delete_type: "DELETE"
delete_url: "http://beta.biesheuvel.lan/admin/class.jquery_upload_handler.php?file=test_2012.pdf"
name: "test_2012.pdf"
size: false
type: "application/pdf"


ad2) The good ;D Internet Explorer 9 does not show a dropzone at all (probally that is by design)

HTTP_USER_AGENT: Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; WOW64; Trident/5.0; BOIE9;NLNL)


If you need more feedback or information let me know.

_________________
The CMSMS Builder is a tool to help you develop and optimize CMS Made Simple >= 2.2.3 themes, it is made by a developer for developers.

I you like an automated file based work-flow this project might be for you. It is usable to kick-start a new CMSMS project or it can be applied to existing ones.


Top
  Profile  
 
Share On:
Share on Facebook Share on Twitter Share on Google+
 Post subject: Re: Drag and drop gives wrong json response
PostPosted: Thu Jun 21, 2012 10:38 am 
Offline
Power Poster
Power Poster
User avatar

Joined: Tue Aug 12, 2008 9:30 pm
Posts: 2071
Location: Feldkirchen in Kärnten, Austria
Rev 8071

Works for me in FF12 and Chrome 19 on Win7, file is uploaded by using dropzone in Theme or in FileManager (pdf. zip, tar.gz, jpeg).

IE9 was excluded from this joy by intention.

My System info
Quote:
----------------------------------------------
Cms Version: 1.11-beta1
Installed Modules:
AceEditor: 0.2.3.2
CMSMailer: 5.2.1
CMSPrinting: 1.0.2
FileManager: 1.4.0
MenuManager: 1.8.2
MicroTiny: 1.2.1
ModuleManager: 1.5.4
News: 2.12.7
Search: 1.7.6
ThemeManager: 1.1.6

Config Information:
php_memory_limit:
process_whole_template:
output_compression:
max_upload_size: 32000000
url_rewriting: none
page_extension:
query_var: page
image_manipulation_prog: GD
auto_alias_content: true
locale:
default_encoding: utf-8
admin_encoding: utf-8
set_names: true

Php Information:
phpversion: 5.3.9
md5_function: On (True)
gd_version: 2
tempnam_function: On (True)
magic_quotes_runtime: Off (False)
E_STRICT: 2048
E_DEPRECATED: 8192
memory_limit: 128M
max_execution_time: 60
output_buffering: 1
safe_mode: Off (False)
file_uploads: On (True)
post_max_size: 32M
upload_max_filesize: 32M
session_save_path: D:/Localhost/tmp (0777)
session_use_cookies: On (True)
xml_function: On (True)
xmlreader_class: On (True)

Server Information:
Server Api: apache2handler
Server Db Type: MySQL (mysqli)
Server Db Version: 5.5.20
Server Db Grants: Found a "GRANT ALL" statement that appears to be suitable

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

_________________
CMSMS Blog - I do this!
Forge profile
Github profile
Twitter
=============================================
Support CMSMS


Top
  Profile  
 
Share On:
Share on Facebook Share on Twitter Share on Google+
 Post subject: Re: Drag and drop gives wrong json response
PostPosted: Thu Jun 21, 2012 10:42 am 
Offline
Power Poster
Power Poster

Joined: Sun Apr 19, 2009 9:33 am
Posts: 1372
Tested both the dropzone in the theme as the dropzone in the FileManager both not working with above mentioned browsers and setup.

Good to have confirmed that IE9 is excluded by intention.

for the record:

Code:
----------------------------------------------

Cms Version: [b]1.11-beta1[/b]

Installed Modules:

    CMSMailer: [b]5.2.1[/b]
    CMSPrinting: [b]1.0.2[/b]
    FileManager: [b]1.4.0[/b]
    MenuManager: [b]1.8.2[/b]
    MicroTiny: [b]1.2.1[/b]
    ModuleManager: [b]1.5.4[/b]
    News: [b]2.12.7[/b]
    Search: [b]1.7.6[/b]
    ThemeManager: [b]1.1.6[/b]


Config Information:

    php_memory_limit: [b][/b]
    process_whole_template: [b][/b]
    output_compression: [b][/b]
    max_upload_size: [b]10000000[/b]
    url_rewriting: [b]none[/b]
    page_extension: [b][/b]
    query_var: [b]page[/b]
    image_manipulation_prog: [b]GD[/b]
    auto_alias_content: [b]true[/b]
    locale: [b][/b]
    default_encoding: [b]utf-8[/b]
    admin_encoding: [b]utf-8[/b]
    set_names: [b]true[/b]


Php Information:

    phpversion: [b]5.3.3-7+squeeze13[/b]
    md5_function: [b]On[/b] (True)
    gd_version: [b]2[/b]
    tempnam_function: [b]On[/b] (True)
    magic_quotes_runtime: [b]Off[/b] (False)
    E_STRICT: [b]0[/b]
    E_DEPRECATED: [b]0[/b]
    memory_limit: [b]128M[/b]
    max_execution_time: [b]60[/b]
    output_buffering: [b]4096[/b]
    safe_mode: [b]Off[/b] (False)
    file_uploads: [b]On[/b] (True)
    post_max_size: [b]10M[/b]
    upload_max_filesize: [b]10M[/b]
    session_save_path: [b]/var/lib/php5[/b] (1733)
    session_use_cookies: [b]On[/b] (True)
    xml_function: [b]On[/b] (True)
    xmlreader_class: [b]On[/b] (True)


Server Information:

    Server Api: [b]apache2handler[/b]
    Server Db Type: [b]MySQL (mysqli)[/b]
    Server Db Version: [b]5.1.61[/b]
    Server Db Grants: [b]Found a "GRANT ALL" statement that appears to be suitable[/b]


_________________
The CMSMS Builder is a tool to help you develop and optimize CMS Made Simple >= 2.2.3 themes, it is made by a developer for developers.

I you like an automated file based work-flow this project might be for you. It is usable to kick-start a new CMSMS project or it can be applied to existing ones.


Top
  Profile  
 
Share On:
Share on Facebook Share on Twitter Share on Google+
 Post subject: Re: Drag and drop gives wrong json response
PostPosted: Thu Jun 21, 2012 11:06 am 
Offline
Power Poster
Power Poster

Joined: Sun Apr 19, 2009 9:33 am
Posts: 1372
Did some more testing on the drag and drop functionality now the apache error log's open.

Do you notice the "/public/public/" the server path is not read out correctly. Just using the default config.php


Code:
[Thu Jun 21 13:04:24 2012] [error] [client 192.168.2.12] PHP Warning:  move_uploaded_file(/home/shared/web/beta/public/public/uploads/images/home_01.jpg): failed to open stream: No such file or directory in /home/shared/web/beta/public/modules/FileManager/lib/class.jquery_upload_handler.php on line 225, referer: http://beta.biesheuvel.lan/admin/imagefiles.php?_sx_=f5d70e9f
[Thu Jun 21 13:04:24 2012] [error] [client 192.168.2.12] PHP Warning:  move_uploaded_file(): Unable to move '/tmp/php1rKAB5' to '/home/shared/web/beta/public/public/uploads/images/home_01.jpg' in /home/shared/web/beta/public/modules/FileManager/lib/class.jquery_upload_handler.php on line 225, referer: http://beta.biesheuvel.lan/admin/imagefiles.php?_sx_=f5d70e9f
[Thu Jun 21 13:04:24 2012] [error] [client 192.168.2.12] PHP Warning:  filesize(): stat failed for /home/shared/web/beta/public/public/uploads/images/home_01.jpg in /home/shared/web/beta/public/modules/FileManager/lib/class.jquery_upload_handler.php on line 235, referer: http://beta.biesheuvel.lan/admin/imagefiles.php?_sx_=f5d70e9f


ad1) Nothing wrong with my apache config:
Code:
DocumentRoot /home/shared/web/beta/public/
    <Directory />
        Options FollowSymLinks
        AllowOverride None
    </Directory>

    <Directory /home/shared/web/beta/public/>
        Options Indexes FollowSymLinks MultiViews
        AllowOverride All
        Order allow,deny
        allow from all
    </Directory>

_________________
The CMSMS Builder is a tool to help you develop and optimize CMS Made Simple >= 2.2.3 themes, it is made by a developer for developers.

I you like an automated file based work-flow this project might be for you. It is usable to kick-start a new CMSMS project or it can be applied to existing ones.


Top
  Profile  
 
Share On:
Share on Facebook Share on Twitter Share on Google+
 Post subject: Re: Drag and drop gives wrong json response
PostPosted: Sun Jun 24, 2012 9:17 am 
Offline
Power Poster
Power Poster

Joined: Sun Apr 19, 2009 9:33 am
Posts: 1372
Rev: 8100

Ok did a fresh install tryed the drag and drop functionality and it worked perfectly.

So why did it not work before?

I made a change in Content -> File Manager -> Settings:

[x] Lets you gain access to whole cmsms filesystem, not just /uploads/ (if allowed) <--- file upload, drag and drop does not work

Code:
[Sun Jun 24 11:15:23 2012] [error] [client 192.168.2.12] PHP Warning:  move_uploaded_file(/home/shared/web/beta/public/public/uploads/images/p1000403.jpg): failed to open stream: No such file or directory in /home/shared/web/beta/public/modules/FileManager/lib/class.jquery_upload_handler.php on line 225, referer: http://beta.biesheuvel.lan/admin/moduleinterface.php?mact=FileManager,m1_,defaultadmin,0&_sx_=6f88e402



[] Lets you gain access to whole cmsms filesystem, not just /uploads/ (if allowed) <--- "default setting" file upload, drag and drop does work

Can anybody test this also?

_________________
The CMSMS Builder is a tool to help you develop and optimize CMS Made Simple >= 2.2.3 themes, it is made by a developer for developers.

I you like an automated file based work-flow this project might be for you. It is usable to kick-start a new CMSMS project or it can be applied to existing ones.


Top
  Profile  
 
Share On:
Share on Facebook Share on Twitter Share on Google+
 Post subject: Re: Drag and drop gives wrong json response
PostPosted: Sun Jun 24, 2012 9:29 am 
Offline
Dev Team Member
Dev Team Member
User avatar

Joined: Wed Apr 23, 2008 7:53 am
Posts: 7678
Location: The Netherlands
Confirmed, good catch Arnoud

Quote:
[Sun Jun 24 11:24:56 2012] [error] [client 127.0.0.1] PHP Warning: move_uploaded_file(C:\\www\\trunk/trunk/uploads/gewicht-groenten.pdf) [<a href='function.move-uploaded-file'>function.move-uploaded-file</a>]: failed to open stream: No such file or directory in C:\\www\\trunk\\modules\\FileManager\\lib\\class.jquery_upload_handler.php on line 225, referer: http://localhost/trunk/admin/moduleinte ... _=b5b5ba94

[Sun Jun 24 11:24:56 2012] [error] [client 127.0.0.1] PHP Warning: filesize() [<a href='function.filesize'>function.filesize</a>]: stat failed for C:\\www\\trunk/trunk/uploads/gewicht-groenten.pdf in C:\\www\\trunk\\modules\\FileManager\\lib\\class.jquery_upload_handler.php on line 235, referer: http://localhost/trunk/admin/moduleinte ... _=b5b5ba94
Filesize 10kB

_________________
Image

Did my post help you solving a problem at your (customers) website and it saved you many hours of work? Great!! Consider buying me a cup of coffee in return!



Top
  Profile  
 
Share On:
Share on Facebook Share on Twitter Share on Google+
 Post subject: Re: [reproduced] Drag and drop gives wrong json response
PostPosted: Sun Jun 24, 2012 4:14 pm 
Offline
Power Poster
Power Poster

Joined: Sun Apr 19, 2009 9:33 am
Posts: 1372
Rev: 8102 confirmed fix

_________________
The CMSMS Builder is a tool to help you develop and optimize CMS Made Simple >= 2.2.3 themes, it is made by a developer for developers.

I you like an automated file based work-flow this project might be for you. It is usable to kick-start a new CMSMS project or it can be applied to existing ones.


Top
  Profile  
 
Share On:
Share on Facebook Share on Twitter Share on Google+
 Post subject: Re: [reproduced] Drag and drop gives wrong json response
PostPosted: Sun Jun 24, 2012 4:48 pm 
Offline
Dev Team Member
Dev Team Member
User avatar

Joined: Wed Apr 23, 2008 7:53 am
Posts: 7678
Location: The Netherlands
fixed in rev. 8105

_________________
Image

Did my post help you solving a problem at your (customers) website and it saved you many hours of work? Great!! Consider buying me a cup of coffee in return!



Top
  Profile  
 
Share On:
Share on Facebook Share on Twitter Share on Google+
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 8 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Hosting Nation - Managed CMSMS Hosting