in reply to Re^3: POE::Component::Server::HTTP and CSS
in thread POE::Component::Server::HTTP and CSS

Actually I am. Check out MainHandler() which is the content handler. The $response->content() will return to the web client the data specified. In this case, I'm calling the sub get_content().

sub MainHandler { my ($request, $response) = @_; $response->code(RC_OK); $response->content( get_content($request) ); return RC_OK; }

The handler is declared in create_httpd() which I didn't include in the OP :

sub create_httpd { my ($kernel, $heap, $Port) = @_[KERNEL, HEAP, ARG0]; $kernel->alias_set('httpd_parent'); my $httpd = POE::Component::Server::HTTP->new ( Port => $Port, ContentHandler => { '/' => \&MainHandler } ); $heap->{httpd} = $httpd; }

Jason L. Froebe

Team Sybase member

No one has seen what you have seen, and until that happens, we're all going to think that you're nuts. - Jack O'Neil, Stargate SG-1

Replies are listed 'Best First'.
Re^5: POE::Component::Server::HTTP and CSS
by jfroebe (Parson) on Jan 10, 2006 at 19:52 UTC
    'tis working now. :) Looks like it was an issue of the remote css links. In any case.. thanks! :)

    Jason L. Froebe

    Team Sybase member

    No one has seen what you have seen, and until that happens, we're all going to think that you're nuts. - Jack O'Neil, Stargate SG-1