Re: [Cppcms-users] Fw: Advice on debugging file upload
Brought to you by:
artyom-beilis
From: doug l. <bi...@gm...> - 2012-04-24 19:28:32
|
Yeah, that's what I guessed -- thanks for having a look. I'll create a form in cppcms to upload the file from & see if that works. If it does, is there an easy way to inspect the request data, to try to work out what is different? & thanks again, Doug. On 24 April 2012 19:15, Artyom Beilis <art...@ya...> wrote: > > > > > Instead doing this all over again start from there: > > > > http://cppcms.com/cppcms_ref/latest/ex_uploads.html > > > I don't know what is your problem, most likely you don't send files > properly > > > > Artyom Beilis > -------------- > CppCMS - C++ Web Framework: http://cppcms.com/ > CppDB - C++ SQL Connectivity: http://cppcms.com/sql/cppdb/ > > > > > > >>________________________________ > >> From: doug livesey <bi...@gm...> > >>To: Artyom Beilis <art...@ya...>; > cpp...@li... > >>Sent: Tuesday, April 24, 2012 8:33 PM > >>Subject: Re: [Cppcms-users] Advice on debugging file upload > >> > >> > >>Ah, that got rid of that error, thankyou! > >>Unfortunately, I'm still not getting any content for the file, and when > I try to output the value of the form's key widget, I'm getting an empty > string, even though the call to cURL explicitly sets the value. > >>Could this be because I'm using cURL? > >>& sorry to be spamming the list with this -- I'll be good & quiet when > I've got the hang of everything, honest. ;) > >> Doug. > >> > >> > >>On 23 April 2012 20:57, Artyom Beilis <art...@ya...> wrote: > >> > >>Read: http://cppcms.com/wikipp/en/page/cppcms_1x_forms > >>> > >>> > >>>Your widgets are not registered withing the form > >>> > >>>Artyom Beilis > >>>-------------- > >>>CppCMS - C++ Web Framework: http://cppcms.com/ > >>>CppDB - C++ SQL Connectivity: http://cppcms.com/sql/cppdb/ > >>> > >>> > >>> > >>>>________________________________ > >>>> From: doug livesey <bi...@gm...> > >>>> > >>>>To: Artyom Beilis <art...@ya...>; > cpp...@li... > >>>>Sent: Monday, April 23, 2012 10:13 PM > >>>> > >>>>Subject: Re: [Cppcms-users] Advice on debugging file upload > >>>> > >>>> > >>>>Ah, so it looks like my issue is something else -- my form isn't even > getting loaded. > >>>>For completeness, I have a simple context object: > https://github.com/biot023/improc/blob/master/content.h > >>>>And I have a simple server: > https://github.com/biot023/improc/blob/master/imageserver.cpp#L32 > >>>>And I'm testing the server with this call to cURL: > >>>> $ curl localhost:8080/imageserver/abc -F > file=@features/fixtures/img01.jpg -F key=def > >>>> > >>>> > >>>>The response is a 500, and the error that cppcms logs to cerr is this: > >>>> 2012-04-23 20:07:57; cppcms, error: Caught exception [Value was not > loaded] > >>>> 0x10653d2b3: cppcms::cppcms_error::cppcms_error(std::string const&) > + 0x63 in /usr/local/lib/libcppcms.1.dylib > >>>> (http_context.cpp:139) > >>>> > >>>> > >>>>The error is caused by the highlighted line in the imageserver.cpp > file. > >>>>From my reading of the tutorials, the create() member function should > be loading the form from the context(), but obviously it isn't, so > obviously I'm missing something. > >>>>Can anyone maybe see where I'm going wrong / what I'm failing to do? > >>>>& thanks again for all the help, it's really appreciated. > >>>> Doug. > >>>> > >>>> > >>>> > > >>>>------------------------------------------------------------------------------ > >>>>For Developers, A Lot Can Happen In A Second. > >>>>Boundary is the first to Know...and Tell You. > >>>>Monitor Your Applications in Ultra-Fine Resolution. Try it FREE! > >>>>http://p.sf.net/sfu/Boundary-d2dvs2 > >>>> > >>>>_______________________________________________ > >>>>Cppcms-users mailing list > >>>>Cpp...@li... > >>>>https://lists.sourceforge.net/lists/listinfo/cppcms-users > >>>> > >>>> > >>>> > > >>>------------------------------------------------------------------------------ > >>>For Developers, A Lot Can Happen In A Second. > >>>Boundary is the first to Know...and Tell You. > >>>Monitor Your Applications in Ultra-Fine Resolution. Try it FREE! > >>>http://p.sf.net/sfu/Boundary-d2dvs2 > >>> > >>>_______________________________________________ > >>>Cppcms-users mailing list > >>>Cpp...@li... > >>>https://lists.sourceforge.net/lists/listinfo/cppcms-users > >>> > >>> > >> > > >>------------------------------------------------------------------------------ > >>Live Security Virtual Conference > >>Exclusive live event will cover all the ways today's security and > >>threat landscape has changed and how IT managers can respond. Discussions > >>will include endpoint security, mobile security and the latest in malware > >>threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > >>_______________________________________________ > >>Cppcms-users mailing list > >>Cpp...@li... > >>https://lists.sourceforge.net/lists/listinfo/cppcms-users > >> > >> > >> > > > > > > > ------------------------------------------------------------------------------ > Live Security Virtual Conference > Exclusive live event will cover all the ways today's security and > threat landscape has changed and how IT managers can respond. Discussions > will include endpoint security, mobile security and the latest in malware > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > _______________________________________________ > Cppcms-users mailing list > Cpp...@li... > https://lists.sourceforge.net/lists/listinfo/cppcms-users > |