Zend Framework

Zend AMF Server startup does not start provide expected "Zend Amf Endpoint"

Details

  • Type: Docs:  Problem Docs: Problem
  • Status: Open Open
  • Priority: Major Major
  • Resolution: Unresolved
  • Affects Version/s: 1.8.0
  • Fix Version/s: None
  • Component/s: Zend_Amf
  • Labels:
    None

Description

Getting my system to show the success message: "Zend Amf Endpoint" has been a long, difficult struggle.

Working with SuSE 11.1, PHP 5.2.9, Apache/2.2.10, ZendFramework-1.8.0
phpinfo() reports:
include_path .:/usr/share/php5:/usr/share/php5/PEAR:/srv/www/htdocs/ZendFramework-1.8.0/library

This is the contents of my index.php file sitting in the DocRoot folder (/srv/www/htdocs):

<?php
    require_once 'Zend/Amf/Server.php';
    require_once '/srv/www/htdocs/flextest/zendamf_remote/HelloWorld.php';
    $server = new Zend_Amf_Server();
    $server->setClass("HelloWorld");
    $_handle = $server->handle();

I can only ever see the success message: "Zend Amf Endpoint" if I include the line:

$_handle = $server->handle();

Omitting that line and just saying

echo( $server->handle() );
not only will not show "Zend Amf Endpoint", but all browsers I tested on, a dialog pops up to then ask to Download the index.php file:
Open 'http://localhost/index.php'?
Type: application/x-amf

As this took days of struggle for a Framework with "no installation", I need to know is this an error the documentation or is this the best practice server instantiation?

Thanks

  • Alan Gruskoff

Activity

Hide
Alan Gruskoff added a comment -

Need to add that my HelloWorld Flex example DOES work if I have the

echo( $server->handle() );
statement in place, while the browser will not show the "Zend Amf Endpoint" message.

The opposite is also true, if I remove the

echo( $server->handle() );
statement , I see the "Zend Amf Endpoint" message, but the HelloWorld Flex example does NOT work.

It would be great to have a reliable benchmark that "if you see this -all is well".

Show
Alan Gruskoff added a comment - Need to add that my HelloWorld Flex example DOES work if I have the
echo( $server->handle() );
statement in place, while the browser will not show the "Zend Amf Endpoint" message. The opposite is also true, if I remove the
echo( $server->handle() );
statement , I see the "Zend Amf Endpoint" message, but the HelloWorld Flex example does NOT work. It would be great to have a reliable benchmark that "if you see this -all is well".
Hide
Marc-Antuan Enriquez added a comment -

I kind of had a similar issue to this. I had a working version in a VPS, but when I moved it to a new VPS i got the file save as prompt.

By removing "echo" from the "echo $server->handle();" line, this was fixed.

My best guess is that this is because of the php versions, since on my old VPS I have PHP 5.2.4 and on the new VPS I have 5.3.2

Just adding this comment as a reference for any other person that gets stuck on this like I did.

Marc

Show
Marc-Antuan Enriquez added a comment - I kind of had a similar issue to this. I had a working version in a VPS, but when I moved it to a new VPS i got the file save as prompt. By removing "echo" from the "echo $server->handle();" line, this was fixed. My best guess is that this is because of the php versions, since on my old VPS I have PHP 5.2.4 and on the new VPS I have 5.3.2 Just adding this comment as a reference for any other person that gets stuck on this like I did. Marc

People

Vote (0)
Watch (1)

Dates

  • Created:
    Updated: