Questions tagged [dancer]

Dancer is a lightweight yet powerful web application framework for Perl, inspired by Sinatra. It aims to be simple, flexible, and easy to get to grips with.

Dancer is a micro web application framework for Perl, originally inspired by the Sinatra framework in Ruby.

Dancer is designed to be as effortless as possible for the developer, taking care of the boring bits as easily as possible, yet staying out of your way and letting you get on with writing your code.

Dancer offers the flexibility to scale between a very simple lightweight web service consisting of a few lines of code in a single file, all the way up to a much more complex fully-fledged web application with session support, templates for views and layouts, etc.

There are a wide variety of Dancer plugins available on CPAN to make common tasks easy (for example, database access, sending email, sending SMS text messages, interacting with Facebook).

There are also various template engine wrappers available for common templating engines such as Template Toolkit, HTML::Template, Mason and many more; writing additional wrappers for new templating engines is easy too.

Getting help

Dancer developers tend to monitor questions on Stackoverflow tagged 'dancer'.

There is an active IRC community on irc.perl.org/#perl (web chat client available).

There's also a mailing list.

Related tags:

264 questions
0
votes
1 answer

How to get the public path in Perl Dancer

Probably a silly question, but how do I get the path to the /public folder in Dancer? I want to store/read csv files under the public folder, but don't know if Dancer offers any convenience methods to get the base path to the public folder. The…
a7omiton
  • 1,597
  • 4
  • 34
  • 61
0
votes
1 answer

Dancer Quickstart Instructions Not Working

I am trying to follow the quick start instructions for Dancer, http://perldancer.org/quickstart. The first command ... curl -L http://cpanmin.us | perl - --sudo Dancer ... worked fine as far as I can tell, but the second command fails like so: $…
Red Cricket
  • 9,762
  • 21
  • 81
  • 166
0
votes
1 answer

timestamp update on oracle via perl dancer

I am getting the following error while trying to update a timestamp on oracle database using per dancer. ORA-01858: a non-numeric character was found where a numeric was expected. The code: my $fmt = 'YYYY-MM-DD HH24:MI:SS:FF3'; …
0
votes
1 answer

Debugging Email::Sender::Simple with Email::Sender::Transport::SMTPS

I'm writing an email service which sends data to my users with Email::Sender::Simple and Email::Sender::Transport::SMTPS. Right now, I've got a package which should just take some inputs and send an e-mail: package MyApp::Service::Mail; use…
Glitch Desire
  • 14,632
  • 7
  • 43
  • 55
0
votes
2 answers

Parse json response from Net::Twitter::Lite::WithAPIv1_1 in a Perl Dancer app

Preface: I'm "new" to Perl, meaning before 3 days ago I had not written anything in Perl since dinosaurs roamed the earth. Yes, I RTFM, but still new at this. So, I'm trying to parse a response from a call to the Twitter API. Parsing the response…
Feather
  • 31
  • 4
0
votes
1 answer

Equivalent for Dancer of Mojolicious Mojolicious::Plugin::PODRenderer?

I would like to generate documentation in a Dancer application in the same way that Mojolicious does with Mojolicious::Plugin::PODRenderer, I mean in the browser, under the /perldoc path. Does somebody knows a module that can help? I found no…
smonff
  • 3,399
  • 3
  • 36
  • 46
0
votes
1 answer

dancer+database on Openshift?

I am trying to deploy a dancer based application on openshift. I am unable to workaround teh following issues. How do I get dancer to use the openshift environment variables e.g. OPENSHIFT_MYSQL_DB_HOST or OPENSHIFT_DATA_DIR. Putting them in the…
vijayvithal
  • 551
  • 1
  • 5
  • 13
0
votes
2 answers

Is there a very simple way to update a page in Perl Dancer using jQuery/AJAX?

I have the following code in my main Dancer app .pm: package Deadlands; use Dancer ':syntax'; use Dice; our $VERSION = '0.1'; get '/' => sub { my ($dieQty, $dieType, $bonus); my $button = param('button'); $dieQty = param('dieQty'); …
BackPacker777
  • 673
  • 2
  • 6
  • 21
0
votes
1 answer

Dancer not save data in sqlite after reboot

sub connect_db { my $dbh = DBI->connect("dbi:SQLite:dbname=".setting('database')) or die $DBI::errstr; return $dbh; } sub init_db { my $db = connect_db(); my $schema = read_file('./schema.sql'); …
Dima Candu
  • 25
  • 1
  • 6
0
votes
2 answers

Dancer::Tutorial connect to SQLite

I'm create database sqlite3 database create table if not exists entries ( id integer primary key autoincrement, title string not null, text string not null ); ^D Where should i put this database ? After sub…
Dima Candu
  • 25
  • 1
  • 6
0
votes
1 answer

using Plack::Middleware::DBIC::QueryLog with Dancer webapp

I am trying to use Plack::Middleware::DBIC::QueryLog inside of a dancer application. The documentation tells me to get the querylog like this: use Plack::Middleware::DBIC::QueryLog; sub get_querylog_from_env { my ($self, $env) = @_; …
Kungi
  • 1,477
  • 1
  • 18
  • 34
0
votes
1 answer

How do I read URL parameters from flex application in Perl Dancer CGI?

I want to know how to pass input parameter to perl cgi . I have a flex application, it will take name and some other details of a person, then i want to call a perl cgi with these details as input. How it's possible? Is appending parameter at the…
neha88
  • 79
  • 5
0
votes
2 answers

How to shutdown Perl dancer applications nicely

I run several Perl dancer applications at the same time with the same user in FCGI mode (Apache). As I understand correctly, Apache (or any other webserver) will fork a new dancer application if the current one(s) are busy. To ensure that no visitor…
burnersk
  • 3,320
  • 4
  • 33
  • 56
0
votes
1 answer

Printing a Table from a Perl Data Structure

I have a Perl data structure like the following: %hash = ( table_id => { column_1_header => [ column_value_1, column_value_2, column_value_3 ], …
indiguy
  • 505
  • 1
  • 9
  • 21
0
votes
2 answers

Pre-forking Dancer app on CentOS

I have a prototype application (RESTful web service database front-end) that is written using Dancer. As a prototype this runs fine under Apache with mod_proxy, and Dancer's routes work really nice. My next step is to see if I can get this to scale…
gsiems
  • 3,500
  • 1
  • 22
  • 24
1 2 3
17
18