fREW Schmidt wrote: > I am trying to figure out how to get some JSON with dbic and I am not > really sure what I am doing wrong.
When I wanted to do that, I took an entirely different approach. My module for the table includes a TO_JSON subroutine (as specified by the JSON::XS module): http://github.com/dorward/simple-ajax-demo/tree/master/lib/App/SimpleAjaxDemo/DB/Twitter.pm#L30 Then I perform a query: http://github.com/dorward/simple-ajax-demo/tree/master/webroot/demo.pl#L42 Put the results into my data structure: http://github.com/dorward/simple-ajax-demo/tree/master/webroot/demo.pl#L49 And convert to JSON: http://github.com/dorward/simple-ajax-demo/tree/master/webroot/demo.pl#L53 -- David Dorward <http://dorward.me.uk/> _______________________________________________ List: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/dbix-class IRC: irc.perl.org#dbix-class SVN: http://dev.catalyst.perl.org/repos/bast/DBIx-Class/ Searchable Archive: http://www.grokbase.com/group/[email protected]
