A really, really simple Services + AMFPHP example using Flex

averageyoungman's picture

Hello,

Many seem to be chomping at the bit for examples, and seeing as I've got this working I figured I might as well post one. This is about as simple as you can get in terms of retrieving data from Drupal, via services.module, in Flex:

*NOTE: This is only an example of getting the gateway working with Flex. Nothing more. Please let me know if I have erred anywhere in my description. Also note that I used an example by Alessandro Crugnola as the basis of this example. His example is not Drupal-specific, but it can be found here: http://www.sephiroth.it/tutorials/flashPHP/flex_remoteobject/index.php

*ALSO NOTE: In my settings for the services module I have turned off the options for use keys and use sessid. This is because I wanted to present the simplest working example.

My Setup:
• OSX 10.4.8 (Intel)
• Apache 2
• PHP 5.2.0
• MySQL 5.0.33

What you need on the Drupal end:
Drupal 5.x
AMFPHP 1.9 Beta 2 (UPDATED - 1.9 Beta 2 now supports Services override requirements.)
AMFPHP module (I am using HEAD)
Services module (I am using HEAD)
• At least one node saved to your DB to retrieve

What you need on the Flex end:
• Flex Builder 2
• A Flex Project or equivalent AS3
• A services-config.xml file for your project (see below)
• A Flex compiler directive to include the services-config.xml file in the build
• An instance of a RemoteObject with which to call a service

Everyone probably already knows how to install the Drupal modules, so I won't go over that. Gory details follow:


1) Make sure AMFPHP 1.9 Beta 1 is in the root of your installation of the amfphp module. The path to it should be: your_drupal_install/modules/amfphp/amfphp

2) Confirm AMFPHP is working. To do this go to administer->site building->services and click on the AMFPHP - /services/amfphp link. If it's working properly you should see something like this:

amfphp and this gateway are installed correctly. You may now connect to this gateway from Flash.

Note: If you're reading an old tutorial, it will tell you that you should see a download window instead of this message. This confused people so this is the new behaviour starting from amfphp 1.2.

View the amfphp documentation

If you get an error make sure you have the correct beta I noted above.

3) Once you've confirmed it's working, create a new Flex project of type "Basic". I called mine AMFPHPTest.

4) Now create a new file anywhere in your project and call it services-config.xml. I created a folder in my project called "services" and put it in there.

5) In this file, you'll want the following. You will need to change the endpoint uri to reflect the location of your own install of the amfphp module:

<?xml version="1.0" encoding="UTF-8"?>
<services-config>
  <services>
    <service id="amfphp-flashremoting-service"
                 class="flex.messaging.services.RemotingService"
                 messageTypes="flex.messaging.messages.RemotingMessage">
            <destination id="amfphp">
                <channels>
                    <channel ref="my-amfphp"/>
                </channels>
                <properties>
                    <source>*</source>
                </properties>
            </destination>
        </service>
    </services>

    <channels>
        <channel-definition id="my-amfphp" class="mx.messaging.channels.AMFChannel">
            <endpoint uri="http://localhost/d5/services/amfphp" class="flex.messaging.endpoints.AMFEndpoint"/>
        </channel-definition>
    </channels>
</services-config>

6) Now add a compiler directive for the services-config.xml file you just created. To do this, do the following:

  1. Right click on your project in Flex Builder and select "Properties".
  2. In the Properties dialog, click on "Flex Compiler".
  3. In the "Additional compiler arguments" textfield, you need to add an additional directive telling Flex the location of your services-config.xml file and its location on your machine. In my case this file is in my default Flex Project location, and my directive looks like the block below. What I added starts with "-services":
  4. -locale en_US -services "/Users/my-user-name/Documents/Flex Builder 2/AMFPHPTest/services/services-config.xml".

    Note that in my case it was necessary to provide the full path to the file. This may not be necessary in your case.

  5. Click OK in the Properties dialog.
  6. If you get errors in Flex stating that the services-config.xml file can't be found, then the path to it is wrong. If it is wrong, an error will show up immediately in the "Problems" pane of Flex Builder. If you do not get errors, then your services-config.xml file is being compiled into your project when you click debug or run.

6) In the Application mxml file for your Flex Project, you're going to want something like this:

<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute">
  <mx:RemoteObject id="amfService" fault="faultHandler(event)" showBusyCursor="true" source="node" destination="amfphp">
        <mx:method name="load" result="resultHandler(event)" />
    </mx:RemoteObject>
  <mx:Script>
    <![CDATA[
        import mx.rpc.remoting.RemoteObject;
        import mx.rpc.events.ResultEvent;
        import mx.rpc.events.FaultEvent;

        [Bindable]
        public var resObject:Object;

        public function resultHandler(event:ResultEvent):void {
         // Do something
            resObject = event.result;
            result_text.text = "Success! The title of your node is: " + event.result.title;
        }

        public function faultHandler (event:FaultEvent):void {
         // Deal with event.faultstring, etc.
            result_text.text = "fault: " + event.fault.toString();
        }
    ]]>
</mx:Script>
<mx:Button x="250" y="157" label="nodeLoad" click="amfService.getOperation('load').send(1);"/>
<mx:TextArea x="10" y="36" width="319" height="113" id="result_text"/>
<mx:Label x="10" y="10" text="Result:"/>
</mx:Application>

Here's a quick piece-by-piece of the really important bits:

  1. Declare the RemoteObject and method with which we will connect to the node service. That looks like this:
  2. <mx:RemoteObject id="amfService" fault="faultHandler(event)" showBusyCursor="true" source="node" destination="amfphp">
            <mx:method name="load" result="resultHandler(event)" />
        </mx:RemoteObject>

    • The ID is local to the flex project, specific to the RemoteObject, and is not associated with our services-config.xml
    • The Source is the node service
    • The destination matches the destination ID of the service we declared in services-config.xml
    • The method name is the method of the node service we want to call
    • The rest should be relatively self-explanatory
  3. Import the classes / packages we need. That looks like this:
  4.         import mx.rpc.remoting.RemoteObject;
            import mx.rpc.events.ResultEvent;
            import mx.rpc.events.FaultEvent;

  5. Declare the button used to invoke the call to the service. That looks like this:
  6. <mx:Button x="250" y="157" label="Load that node!" width="79" click="amfService.getOperation('load').send(1);"/>

    • The click event uses the ID we gave our RemoteObject to first get the specific operation (method) we want to call and then send the request with a NID of 1. In my case this is a Drupal page with a title of "TestPage". You can change the NID to any node you have published.

The bits I didn't cover here are the event handlers for the RemoteObject and the textarea component that displays a fault or result. That stuff should be relatively self explanatory.

This works for me. I can not guarantee that it will for you, but by all accounts it should.

Once you have all these pieces assembled, you should be able to click the "Load that node!" button and see output of your node title. You'll just have the change the endpoint etc. that I mentioned above. If you want, email me and I'll give you my simple source. I can't attach it here. Please let me know if I've missed anything, it would be easy to.

NOTE: - Apologies to anyone who downloaded 1.9 Beta 1 and had issues. When this post was first created, AMFPHP 1.9 Beta 2 did not support the Services module's requirements. 1.9 beta 2 works in the context of these instructions without any modifications to file locations.

Comments

Nice

snelson's picture

Thanks for doing this. I have a couple of screencasts coming in the next few days.

Scott

No problem!

averageyoungman's picture

To the contrary, Thank You for getting this going. This is truly a spectacular addition to Drupal, and really exciting. Great work.

justin

Recipe Service Error

chand-gdo's picture

I am following your screen cast for creating a recipe viewer with flex and drupal. I have a problem in it I am using drupal 6.12 but when I am going to make recipe_service.info and recipe_service.module then problem occured and I attached the file to this message of error. Please have a look on the file attached to this message for having the better idea of my problem. I dont want to use drupal5.x to solve this specific problem and the error is about the version incompatibilty and this occured only here the previous process goes very nicely.

I'll be very grateful to you for the great tutorials and also please solve this problem.

Thanks
chand

Try adding the line: core =

mrconnerton's picture

Try adding the line:

core = 6.x

to your recipe_service.info file


Matthew Connerton
http://www.mrconnerton.com


Matthew Connerton | matthew@aspiringweb.com
Aspiring Web a design & development agency

problem is still there

chand-gdo's picture

Thanks for responding but problem is still there, here my recipe_service.info file's content

core = 6.x
name = Recipe Service
description = Some sevices for recipes
package = Services - services
dependencies = services

before I don't have first line core = 6.x but now also the case is same nothing different.
Take a look on this problem please.

Thanks
Chand
chand.wasim@gmail.com

shortcut

snelson's picture

Instead of doing:

amfService.getOperation('load').send(1);

You can do:

amfService.load(1);

For this reason, I like to give my RemoteObjects an ID related to the service source, like "nodeService" or even simply "node".

Then, you can do:

node.load(1);

... clean.

Scott

what abut flash users?

gavri's picture

what if i wanted to implement this example or one similar to it using flash - how can i call to the node service?

thanks

A Flash example

averageyoungman's picture

Hey,

Sorry for the late reply. Here's an example using Flash 8 Professional / AS2:

// remoting
import mx.remoting.Service;
import mx.remoting.PendingCall;
import mx.rpc.RelayResponder;
import mx.rpc.FaultEvent;
import mx.rpc.ResultEvent;
import mx.remoting.debug.NetDebug;

mx.remoting.debug.NetDebug.initialize();

var tf:TextField = this.createTextField("field", 10, 0, 0, 200, 200);

var node:Service = new Service("http://localhost/d5/services/amfphp", new Log(), "node", null, null); // connect to remote service
var pc:PendingCall = node.load(1); // call service method
pc.responder = new RelayResponder(this, "getData_Result", "getData_Fault");

tf.text = "no response from server yet.";

function getData_Result( re:ResultEvent ):Void { // receive result
  tf.text = "response";
}

function getData_Fault( fe:FaultEvent ):Void { // receive fault
tf.text = "error";
}

Remember that this example is subject to Flash Player Security Sandbox restrictions. If you get an "Error Opening URL" error, you need to place the swf file within the domain in which the services reside, or create a cross-domain policy file that will enable the swf to issue the service call.

  • justin
texas-bronius's picture

Note that a simple to install library of two Remoting components is required on the Flash end:
http://www.adobe.com/products/flashremoting/downloads/components/

I got "The class or interface 'mx.remoting.Service' could not be loaded." in my Flash8 output window on compile/run until I installed these components. First you install (see link above), then in Flash8 choose Window>>CommonLibraries>>Remoting, and drag both components onto the stage.

oh this is exciting!

texas-bronius's picture

It works, it really works! The simple example calls the node load service, and the result, on success, can be seen by adding:
trace(er.response.title);
into the function getData_Result.

I've added your code snippet, mildly amended, and my other steps discovered to d.o handbooks:
http://drupal.org/node/113697

I've copied this example

mokargas's picture

I've copied this example exactly, and Services + amfphp (under d5.6) appears to be installed properly. I've even had this working before under 5.1. I've installed and re-installed at least 20 times.

For some reason, now I can't get anything returned. If I use justins example above for Flash 8 Prof and AS2, the text fields are filled with 'undefined' in Flash CS3 (doesn't matter what node id I use either).

If I go into the service browser in Drupal, and open node.load and use an nid of 1, the correct data is returned. Does anyone have any idea on how to remedy this? It's driving me bonkers !

Mo of the Cloud Concept, Adelaide, Australia.

View my (aging) site @ http://www.reactiondynamics.com.


Mo of the Cloud Concept, Adelaide, Australia.

View my (aging) site @ http://www.reactiondynamics.com.

Thanks

jskeesick's picture

I appreciate you putting this together. It's a very simple introduction to getting the connections between flex and amfphp.... however, I seem to be even more simple than this tutorial.

Any chance you know what might be going on with my attempt? I am getting the following error returned.

fault: [RPC Fault faultString="Send failed" faultCode="Client.Error.MessageSend" faultDetail="Channel.Connect.Failed error NetConnection.Call.Failed: HTTP: Failed"]

Everything seems to be set up fine on my server. amfphp seems happy, I can step through the servers and send arguments and the like, but the above error persists.

Any thoughts?

Thanks again for your work on this,

Hmmmm...

averageyoungman's picture

Hey,

I haven't had a chance to look at the example and compare it with your
error message yet, but the first thing that comes to mind is that the
services-config file may not be getting compiled in properly, or there
is domething up with the channel/destination. Did you
add the services-config file to the compiler arguments field?

If I knew your context I might be of more help. My guess is it's
something in or related to the services-config file, considering that
the error is referring to the send portion of the RPC connection in
reference to the channel.

WHat does your services-config file look like?

  • justin

Thanks for having a think on

jskeesick's picture

Thanks for having a think on this...

I have played with the services-config file a bit as it appeared to be the problem to me as well but it seems alright. I altered the location in the compiler arguments to be both relative and absolute, purposely made it incorrect to make sure it would give me an error (which it does) I also changed the endpoint from my (virtual) domain location to the actual server domain location.

The services config file looks exactly like the one posted except with my install location.... (there are only 2 test nodes on this install)

<?xml version="1.0" encoding="UTF-8"?>
<services-config>
    <services>
        <service id="amfphp-flashremoting-service"
                 class="flex.messaging.services.RemotingService"
                 messageTypes="flex.messaging.messages.RemotingMessage">
            <destination id="amfphp">
                <channels>
                    <channel ref="my-amfphp"/>
                </channels>
                <properties>
                    <source>*</source>
                </properties>
            </destination>
        </service>
    </services>

    <channels>
        <channel-definition id="my-amfphp" class="mx.messaging.channels.AMFChannel">
            <endpoint uri="http://skeesick.com/modules/amfphp/amfphp/gateway.php" class="flex.messaging.endpoints.AMFEndpoint"/>
        </channel-definition>
    </channels>
</services-config>

Aha!

averageyoungman's picture

I think it's your channel endpoint...

The amfphp module overrides the AMFPHP gateway in order to make the services directly available within the Drupal API. So your endpoint should actually be something more like:

http://skeesick.com/services/amfphp

If you look in services.module, you'll see a hook_menu entry with that path and a callback specified if I remember correctly. That callback is essentially the entry point for your service call. I can't be totally sure, but I think that's the problem.

  • justin

No Dice

jskeesick's picture

Well I was hopeful, but after changing (in several ways) the endpoint I ended up with the same error.

J

Damn

averageyoungman's picture

Are you logged in to your Drupal install?

I tested my own installation and Flex app while logged out of my install. I got the same error! So I logged in as the admin...and it worked again! I'm not sure what the connection is there, seeing as this simple Flex app does not send or require session or user information, but I can confirm that I get the same error when logged out. Try logging in and see what happens. Also, one other thing to check (if you're on a Mac running an install of Apache 2.x) is if the default install of Apache on the Mac in /usr/sbin is running. If it is, and you're attempting to use a different httpd, I believe this will cause problems.

If being logged out is the issue, that's definitely something I missed. So sorry about that. I also tested this by creating a generic user with virtually no priviliges, logging that user in, and running the Flex app. It works this way as well. So, interestingly, it appears that there must be at least one user logged in for the app to work. Not sure why.

  • justin

Done and Dusted

jskeesick's picture

Justin,

Thanks for all your help with this. You've gone above and beyond. I kept plugging away and figured out that it was a conflict with PHP4. I'm on 1and1 host and they run several PHP versions concurrently. I changed the htaccess file to make the site globally run PHP5 by adding the line AddType x-mapp-php5 .php alternately you can simply make your extensions .php5 on individual files to use 5 for just that file.

Once I made that change the original file worked fine. I appreciate all your help.

J

Flex/Drupal AMF only works if logged into Drupal.

ShawnW's picture

I encountered this same issue. It seems that AMFPHP uses the User object in Drupal that only exists if someone is logged in. I added a block of code to my Flex app to do an automatic login of a generic user created for this purpose. Make sure the user has permission to access views.

CODE
public function init():void
{
LogIn();
}

public function LogIn():void
{
var request:URLRequest = new URLRequest("http://yourdrupalsite.biz/index.php/node")
var variables:URLVariables = new URLVariables();
variables.destination="node";
variables.name="drupaluser";
variables.pass="drupalpass";
variables.op="Log in";
variables.form_id="user_login_block";
request.data = variables;
request.method=URLRequestMethod.POST;
var loader:URLLoader = new URLLoader();
loader.addEventListener(Event.COMPLETE,LoggedIn);   
loader.load(request);
}

END CODE

You can do it without being logged in drupal

redben's picture

Hi,
Just my 2 cents, if you want to access your services (through AMFPHP for instance), you can do the following :
1 - Log into you drupal site
2 - Goto Administer > User Management > Access Control
3 - Scroll down to "services module"
4 - Thick the "access services" checkbox for anonymous user
5 - Logout and give your flex app a test.
Theorically it should work. This would spear you the need for a generic user code block in your flex App.

By the way

I have been playing with the example a bit (and the article on http://devzone.zend.com/article/2660-Reading-And-Writing-Drupal-With-Flex) . Tried to use the session ID an key and here is what i did to make it work :
1 - Administer > Site Building > Sevices > Settings
2 - Created a Key
3 - On the settings page, i checked "Use Keys" and "Use sessid"
Changed my flex app to the following :

<mx:Application creationComplete="initSession()" xmlns:mx="http://www.adobe.com/2006/mxml" >
  <mx:Script>
    <![CDATA[
      import mx.controls.;
      import mx.rpc.events.
;
      import mx.utils.ArrayUtil;
      import mx.collections.ArrayCollection;
     
      // The key that i created in drupal services. Change this to whatever your generated key is
      private var myKey:String = 'f7572c6e02856507c96c677d65fa3d96';
     

      // Call this before anything to get a session id. I chose to call it  on the application's creationComplete event
      public function initSession():void
      {
        drupalSystem.connect(myKey);
      }
     
      // Use the result to  get the session Id and send the add it to the login method parameters
      public function logMeIn(event:ResultEvent):void {
         
        drupalUser.login(myKey,event.result.sessid,'myusername', 'mypassword' );
      }
     
      public function userLoggedIn(event:ResultEvent):void {
        Alert.show( "Logged in" );
      }
     
      public function onFault(event:FaultEvent):void{
        Alert.show(event.fault.faultString, "Error");
      }
    ]]>
  </mx:Script>
 
  <mx:RemoteObject showBusyCursor="true" destination="amfphp" source="system" id="drupalSystem">
    <mx:method name="connect" result="logMeIn(event)" fault="onFault(event)"/>
  </mx:RemoteObject>  
 
  <mx:RemoteObject showBusyCursor="true" destination="amfphp" source="user" id="drupalUser">
    <mx:method name="login" result="userLoggedIn(event)" fault="onFault(event)"/>
  </mx:RemoteObject>
</Application>

Gateway.php Error with local hosts

rockfer's picture

Hi guys,
I was having the same problem. Hopefully I found a solution to what might be one of the problems with amfphp. I am using a local server for testing purposes. I downloaded amfphp 1.9 and started running a simple test on the connection. I'm using wampserver as my testing server. I looked at the apache logs Apache>Apache error log. And found the following error: '[internal function]: services_server('amfphp')\n#8 C:\wamp\www\sandbox\includes\menu.inc(348): call_user_func_array('services_server', Ar in C:\wamp\www\sandbox\sites\all\modules\amfphp\amfphp\core\amf\app\Gateway.php on line 357, referer: file:///C|/wamp/www/flash/Demo1.swf'

I went ahead and looked at the 'Gateway.php' file on line 357. I found that that the following function was set to 'true':

CODE: SELECT ALL
function disableStandalonePlayer($value = false) {
if($value && $_SERVER['HTTP_USER_AGENT'] == "Shockwave Flash")
{
trigger_error("Standalone Flash player disabled. Update gateway.php to allow these connections", E_USER_ERROR);
die();
}
}

So basically if you change the '$value' to false it will let you make the connection.
As I said I'm a newb so I don't know if this was a no brainer for you guys

A couple of questions

newdru's picture

First let me say thanks to snelson and averageyoungman for sharing their knowledge. This is stuff a certain subset of users here are probably fairly interested in.

Now for the questions :-)

1) I still use flash mx2004 AS 2.0:

a) does the flash post example below apply to mx2004 / AS 2.0?

b) i'm assuming that for the flash post example below, the code presented would go in the mxml file and all the other code snippets / services config would remain the same. Is that correct?

2) the topic AMFPHP seems to be focusing on flex though the philwickam example that got the ball rolling is flash based. I personally have not ventured into flex yet and imagine that the majority of drupallers out there are probably more versed in flash/AS versus flex (though i could be wrong). meaning that the majority of folks interested in this are probably going to be looking for flash based examples. at least i am :-). Partly because it's what i know. Partly because i don't want to have to drop another couple of hundred bucks to get flex and learn yet another language when i can leverage the skills that i already have. So my thoughts, suggestions and questions related to this are as follows:

a) will there be more flash examples or at least an equal focus on flash versus flex with regard to these modules? i think that's where the majority of folks want to leverage your excellent work.

b) what's all the buzz about flex? should i be thinking about moving in this direction and making the investment? Is it supposed to augment flash or replace it?

I'm still having a hard time understanding what flex is i guess. I went to a local adobe group meeting a couple of months ago and from what i could tell, it appeared to be an AS generator that created bloated code. What i mean is that it seemed like it was a rapid app flash generator designed to allow non programmers to code AS (hence the code bloat) and generate forms and apps with predefined widgets? From what i understood it was pricey and targeted towards higher end corps that had the budget to buy the stuff (and lacked the coding experitise to simply code AS). At the time, my gut feeling was i'll let somebody else mess with this stuff. It's a waste. However, i must be wrong because i keep seeing "flex" pop up every where.

Somebody please set me straight. What is it that flex does that i should be excited about?

c) I read in one of the posts that you can get a free compiler for flex. that way you generate the xml files and compile the stuff without the slick interface. Is this feasible in the real world or do you really need the rest of the app/toolset?

d) assuming i'm going to jump and learn flex, anybody have a link or two to the holy grail of getting started with flex quick?

I mean jumping into the coding of meaningful examples quickly if you already have a background in AS 2 without wasting lots of time and also how to compile the code / set up the environment efficiently.

3) I've got Mx2004 and program in AS2. Soon after i bought that flash jumped to flash 8 with i believe hints of AS3. Now we've got a new version that just came out in CS3 and i believe that's AS3. I keep hearing about Apollo. AS3 is apparently pretty different from AS2. Now I've got flex on my horizon and god only knows what version that is at now and how it relates to the plethora of flash versions.

Can anyone in a paragraph or less sort all of this out or point to a good link :-)? (actually write as much as you desire!)

fwiw, i didn't jump to flash 8 because i had just dropped enough dough on the macromedia suite i bought at the time and it didnt' seem to offer much difference (although i really wish i had the flash 8 filters!). I just saw a preview of flash cs3 and the best feature was it's import features (it's now much easier to pull graphics in from ps) but other than that, it didn't seem that great to me.

a) So, am i going to be screwed if i stick with mx2004 and continue to program in AS2?

b) Will i be able to use AS2 with flex or does it use some other language?

c) AS3 is going to give me exactly what? (i'm starting to worry that if i don't start looking at AS3, i'm going to be left behind eventhough AS2 serves me fine right now)?

4) Screencasts! Yeah ... When are those coming? That would be really great..

Sorry for the long post but hopefully others have a lot of the same questions and share some of the same ideas. My thought is that by bringing them up, we can nip a lot in the bud for future posters.

thanks again for your contributions to this.

More about Flex

mikeypotter's picture

Hey there:
I'm on the developer marketing team for Flex, so I think I can answer some of your questions.

Flex is a framework for building Flash applications. As you said, its pre-built ActionScript components that you can use to build a .swf file (same output as Flash, though Flex apps require FlashPlayer 9).

The reason that people are so excited about it is that it remove timelines and other tools that developers aren't used to (like the paint brush... :) ) It gives software developers a way to build real applications that get delivered via the FlashPlayer.

Flex is all ActionScript 3.0. ActionScript 3 is more advanced than AS 2, though a bit more complicated too. However, its screaming fast. Way faster than AS 2. If you're running into performance problems with AS 2, you should move to Flex or AS 3. If not, then don't worry about it.

You can download the Flex SDK, which includes a compiler and debugger, for free. You can also use Flex Builder, an Eclipse plugin, that gives you WYSIWYG editing for your Flex application, plus code completion, highlighting, autocomplete etc... That product is $499.

You can get more information from http://www.flex.org/php/

Mike

hey mikey

newdru's picture

thanks for the reply.

I did a little more digging myself and combined with your replies i think i have a better understanding of flex now. But also a few more pointed questions:

fwiw, I rarely used the std flash ide / timelines period with mx2004. I mostly program AS2. So in that sense i'm using my current version of flash much like flex to build "real" applications. However, it seems that what you are saying is this:

1) Because flex is based on AS3, and the new flash player 9 is improved to take advantage of AS3, my swf apps now have newer capabilities that are already sitting in the engine (reside in the player) that can be exploited by AS3. I imagine that flash player 9 is also probably "heavier" then prior versions (e.g. larger file size) to accomodate the increased functionality. However, because it is only downloaded once, that allows your flex apps (swfs) to be lighter and not require as much download time but actually do more sophisticated stuff (e.g. the rendering is probably pushed more to the local player).

Would these be a (semi)correct statements?

2) Do you know current penetration of FP 9 and is there a link that keeps one up to date on those statistics?

3) How different is AS3 from AS2? Do you have any good links/books to recommend to make the transition for an AS2 programmer?

4) Without Builder, i imagine all the components are still available to me (i simply include x class and component is rendered at run time). Correct?

And if that's the case, if one simply loads the SDK, do you have a site link/section which gives good info (descriptions/live examples or at least imgs) of all the widgets/components so the developer can visualize them without Builder?

5) Did you guys build in tweening classes and sequences similar to fuse into flex? What are they called in flex (any links)?

6) Any upgrade path for MX2004?

7) wtf is apollo? ;-)

8) Finally, i understand that flex initially was a server based product. I completely understand the current "view" / incarnation of flex as a robust application environment based on AS3 and FP9. But with regards to server based flex, can you say anything about what that's all about currently if anything?

thanks for your time and input

Limited answers

averageyoungman's picture

Flash Player Penetration

Apollo is a cross-platform desktop runtime, capable of running Flex / AS3 applications.

As to question 4, you can use the Flex SDK with the Flex compilers and an IDE to create Flex apps without Flex Builder, although builder - IMO - is way more than worth the money. All the components etc. are documented in the LiveDocs.

AS3 is completely, totally different from AS2. However IMHO it is a far better, more complete implementation and programming language. Any complexities it adds are justified by what they can potentially yield for you as a developer. Also, from an architectural standpoint I think it makes a lot more sense. It is far more powerful than AS2 in just about every respect, and development is more inherently structured based on the differences and impovements.

There are robust tweening classes in AS3, but I myself am not aware of a Fuse-like sequencer equivalent. APE is looking rather promising though.

As to question 1, I'm not entirely sure what you're asking regarding the newer capabilities for existing apps. If they are written and compiled using AS3 then yeah, your apps have access to all the cool new features of Flex / AS3.

The ActionScript 3 Cookbook is a good transition book for moving from AS2 -> AS3. My recommendation however is to download the trail version of Flex Builder, read the docs, experiment, and consult books as is needed. There are also some Adobe-endorsed Flex specific books out there as well.

Good luck!

  • justin

Another thing

newdru's picture

If i'm going to move to flash 9 and start doing some flex AS3 but simultaneouly still develop AS2 stuff, is there anyway to have my local browser still use more than one flash player version eg. (fp7 + fp8 + fp9 or some combo of those). e.g. once i install fp9 that replaces (uninstalls?) my prior fp version?

I ask because i imagine many folks out there still do NOT have fp9 installed. So i'd like to be testing in environments that my consumers will be using.

otoh, maybe fp9 is completely backwards compatible with earlier players (i imagine it is).

thanks

Yes, Flash Player 9 is

mikeypotter's picture

Yes, Flash Player 9 is completely backwards compatible with Flash Player 8. You shouldn't have any problems updating your Flash Player.

Mike

Hey Mike I know your a Flex

cmcintosh's picture

Hey Mike I know your a Flex Guy over there, but any chance on getting someone from adobe to put together some docs on this. Seems still to be a lot of fuzziness around especially when it comes to Flash instead of Flex. I am personally running into an issue where I had an app that once worked, but now transitioning to a new host i am getting a BadVersion error and not much more to point me in a direction to go. Any good classes to trouble shoot something like that.

ServiceCapture/Charles

dazweeja's picture

IMO the best troubleshooting tool you can use in these cases is an HTTP/AMF inspector like ServiceCapture or Charles. That way you can see exactly what is being sent to your server and what's coming back. They both have free trial versions.

Installation

pfouet's picture

Good luck...
PfouEt

PfouEt

Error

newms's picture

I am trying out the example above, but whenever I hit "nodeLoad" in the flex app I get the following error:

fault: [RPC Fault faultString="[MessagingError message='Unknown destination 'amfphp'.']" faultCode="InvokeFailed" faultDetail="Couldn't establish a connection to 'amfphp'"]

It looks like it's not picking up the amfphp service. I have amfphp, services modules and the gateway installed. Any idea what's wrong?

Similar to what's been

mhovey's picture

Similar to what's been posted before, I'm getting this error:

RPC Fault faultString="Send failed" faultCode="Client.Error.MessageSend" faultDetail="Channel.Connect.Failed error NetConnection.Call.Failed: HTTP: Failed: url: 'http://www.tshovey.com/services/amfphp'"]

I've double checked all my code and I'm pretty sure everything is in line. Everything with Drupal is setup (views, services, amfphp) correctly yet I'm still running into this problem. I'm using 1and1 hosting, which I saw above, has a few issues with PHP4/PHP5 so I tried adding a line to my .htaccess to only enable PHP5 but I come up with a server error there. Any ideas?

Look at redben's comments

pushkar's picture

http://groups.drupal.org/node/2768#comment-30865

The permissions is a big thing. If you have that correctly set up - that will solve a LOT of issues. :)

Solved: You have to have

newms's picture

Solved: You have to have drupal installed in your webroot. That worked for me.

Flash Player 9

paysansan's picture

Please, what are the great difference between Flash Player 9 and the 8? Thx. Pierre.

Chris Charlton's picture

Flash Player 9 uses ActionScript 3 now, which processes 10x faster than ActionScript 2. It supports AS2 also. There's more video and hardware acceleration stuff now. Many more features, but there are just highlights.

Chris Charlton, Author & Drupal Community Leader, Enterprise Level Consultant

I teach you how to build Drupal Themes http://tinyurl.com/theme-drupal and provide add-on software at http://xtnd.us

Can't find globals.php (amfphp.module line 43)

LeeHunter's picture

I've installed the Drupal amfphp module ok and the amphp 1.9 beta (modules\amfphp\amfphp) but when I click on the amfphp server or the services page I get the following error:

require_once(modules/amfphp/amfphp/globals.php)[function.require-once]: failed to open stream: No such file or directory in c:\xampp\htdocs\Drupal\modules\amfphp\amfphp.module on line 43.

This isn't too surprising really, since the globals.php file is actually in /amfphp/amfphp/core/shared/app. I tried just editing the amfphp.module file but this just produces a new error. Obviously, there's something I've missed in the installation, but I've repeated the instructions several times and wind up in the same place.

My bad. In the confusion

LeeHunter's picture

My bad. In the confusion over the similarly named amfphp files, I wound up with the wrong version for amphp 1.9 beta. Looks ok now.

Service Browser doesn't load

LeeHunter's picture

I seem to have everything installed correctly, but when I click "Load the Service Browser" link, it gives me a page not found. The application is also not finding the http://localhost/Drupal/services/amfphp URL.

I have the same problem

Juonio's picture

It does this also when I try to install amfphp separated from Drupal. So I think the problem is in amfphp. Help needed! I'll try also to find answers on other forums handling amfphp.

Can this be a server issue?

Juonio's picture

I got my service browser working. It can't open it directly through services module but if I use absolute link to the browser folder, it works.

Still, I can't get the connection to my flash application working.

Could this be a server issue?
http://drupal.org/node/141992

Can anyone tell a localhost server configuration that works with servers module and amfphp module. It would be nice if setting it up is easy. I use WOS-portable serverpackage. It has:

Apache 2.2.4 (Small edition)
MySQL 5.0.41 (Small edition)
PHP 5.2.3 (Small edition)

cant get it working

ven's picture

When using the AMFPHP 1.9 beta 1 (the version downloaded from this page) i get the error:
Fatal error: require_once() [function.require]: Failed opening required 'modules/amfphp/amfphp/globals.php' (include_path='.:/usr/local/share/pear') in /xxx/modules/amfphp/amfphp.module on line 43

When i use the AMFPHP beta 2 (the version not recommended) it finds the globals.php, but then i get error

Fatal error: Uncaught exception ‘VerboseException’ with message ‘realpath(): Unable to access /xxx/services//’ in /xxx/modules/amfphp/amfphp/core/amf/app/Gateway.php:296 Stack trace: #0 [internal function]: amfErrorHandler(2 , ‘realpath(): Una…’, ‘/xxxxx…’, 296, Array) (... and lots of more errors)

[Edit]
Really never found out why it wasn't working, but it had to be something with the webhost/php setup, since none of these issues appeard with my new webhost.

i've attempted to get the

psi-borg's picture

i've attempted to get the amfphp.module working to no avail. i followed the example closely and read through this thread for solution pointers, no joy. i've tried setting n for node.load(n) to several different node types, but continue to get the following fault msg:

fault: [RPC Fault faultString="Didn't receive an acknowledge message" faultCode="Server.Acknowledge.Failed" faultDetail="Was expecting mx.messaging.messages.AcknowledgeMessage, but received null"]

i'm also wondering if the flex-ajax bridge new to flex 3 at adobe labs might be a better way to wrap drupal into a flex application... any thoughts?

Exact Same!

flex_vixen's picture

Hi guys,

I followed this to a "T" and get the same error that psi-borg posted. First a popup states an actionscript error "RangeError: Error #2006: The supplied index is out of bounds."

And then the result reads:

"fault: [RPC Fault faultString="Didn't receive an acknowledge message" faultCode="Server.Acknowledge.Failed" faultDetail="Was expecting mx.messaging.messages.AcknowledgeMessage, but received null"]"

Please help!

First...

averageyoungman's picture

I've updated this original post. Some of the problems people have been experiencing are the result of my not doing so earlier. AMFPHP 1.9 Beta 2 has been updated to support the requirements of the Services module, and I've been out of the loop for a bit. Nasty bike crash. Anyway, at the time the post was written Beta 2 did not work with the Services module. I tested the example above with 1.9 Beta 2 (which is now correctly linked in the post) and it works fine. No changes are needed save the change to using AMFPHP 1.9 Beta 2.

Apologies to anyone who experienced issues with Beta 1 as a result of my poor housekeeping.

As far as the range error, perhaps it has something to do with the type of node being retrieved? My experience with that first error has generally been in the context of the child list and attempts to access indexes which are undefined. Can't be sure, but it's likely that the fault error is/was related to usage of Beta 1.

  • justin

Thanks J! I upgraded to Beta

flex_vixen's picture

Thanks J!

I upgraded to Beta 2 and still have the same issue exactly as described. This weekend I'm going to roll up my sleeves and start fresh... admittedly I may have overlooked something obvious in my frustration. Thanks for the help :)

Receiving the same error

45mo4s39's picture

I'm getting the same range out of error/ RPC Fault faultString="Didn't receive an acknowledge message" amfphp messages. Did you ever get this to work?

my 2 cents..

johannes-gdo's picture

"out of range error" > probably some error in your actionscript (calling array[1].title when there is no array[1] for example..)

"Didn't receive an acknowledge message error" > sometimes appears when there is a conflict with other modules (in my case the Outline-module caused this error to appear)

Still getting same error

paulbhartzog's picture

We are using amfphp-1.9.beta.20080120.zip and still getting this error.

/admin/logs/status shows:

Drupal 5.12
AMFPHP 1.9 Beta 2

Suggestions?

same error

johannes-gdo's picture

hhmm..I recently got the same error and couldn't get rid of it.

This made me migrate the website to Drupal 6 where everything went perfect..

Possible solution to out of range error

dazweeja's picture

With my installation I get this error too unless I specify which node fields I want returned. So in the above example you could change the button click event like so:

<mx:Button x="250" y="157" label="nodeLoad" click="nodeLoad()" />

And then between the Script tags add this function:

private function nodeLoad():void
{
   var nid:Number = 1; // node number
   var fields:Array = new Array();
   fields[0] = 'title';
   fields[1] = 'body'; // add required field names here
   amfService.load(nid, fields);
}

Not getting it right

hemmie's picture

Great example, so I tried it out...
have installed:
xampp, with php version 5.2.3
drupal v 5.2

Installed and enabled the amfphp module, service module, node service
I can access them and use them through the drupal service page in adminitster

I am logged in as root on to my drupal site.

Now I tried two endpoint uri in service-config.xml:
1) "http://localhost/modules/amfphp" is where I installed my amfphp module
returns following error when I run the swf:

fault: [RPC Fault faultString="Send failed" faultCode="Client.Error.MessageSend" faultDetail="Channel.Connect.Failed error NetConnection.Call.Failed: HTTP: Failed: url: 'http://localhost/modules/amfphp'"]

???? do not what this means, anyone knows how to debug or what the problem is

2) also tried using the url which you get if click the amfphp/services link in the services (Servers, AMFPHP - /services/amfphp) page of drupal:
"http://localhost/?q=services/amfphp" as endpoint
where I get the following error:

fault: [RPC Fault faultString="Method does not exist." faultCode="AMFPHP_RUNTIME_ERROR" faultDetail="D:\work\CME\pltfrm\drupal-5.2\modules\amfphp\amfphp.module on line 101"]

where line 101 is trigger_error($message, E_USER_ERROR); in the module (which just throws the error).

I get a rather anonymous Method does not exits. Does this mean if I do node.load(1) => that the load method is not existing????

Can anybody tell me what to do and which of the two is the best approach.

Thank you.

It works

hemmie's picture

Got it working,

one should opt for option 2.

I got my mxml source wrong.

thx

How?

johnfyoung's picture

I'm missing something from your solution to this "Method does not exist" error. The app can't find a "node.load" method. You reported something wrong in your mxml source?


john young
codeandcreative.com

Ok - Duh

johnfyoung's picture

I had installed the services module, amfphp module, and amfphp and enabled them in admin/build/modules...but I hadn't enabled any of the services!


john young
codeandcreative.com

Using services with Flash 9/Actionscript 3

arithmetric's picture

I'm getting started with accessing content from Drupal sites with Flash. I work with Flash 9/Actionscript 3, and I haven't yet seen any examples with it. I've had some success and wanted to share what I found.

AS3 has NetConnection and ObjectEncoding classes that support an AMF connection. I made this class to provide a simple syntax for calling Drupal services. The source for a pretty simple Flash application that retrieves the nodes from a view is here (you can see it in action here).

I've been working with Thomas Saunders (who wrote about this topic here) on this site:
http://internal.thirdavedesign.com

Also, I'm beginning to refit my own site:
http://arithmetric.com

Why directly flash ?

redben's picture

It's just a matter of opinion but why use flash directly when you have flex libraries ? IMO with the flex framework, it is so easy and quick, and it you can add your flash content (animation or whatever) to your flex application, which is nothing but flash itself.
I still can't think of a scenario where the use of flex does not feet...I'd be pleased to have your opinion.

Just out of curiosity...

averageyoungman's picture

What version of PHP are you running? I tried and stumbled with this using versions of PHP < 5.

I am running 5.2.0 locally.

  • justin

help loading amfphp

sgitner's picture

i have loaded the file exactly as you say but am experiencing some issues.

i put the update in modules/amfphp/amfphp

is that right?

i get this when I go to mysite/services/amfphp/

Forbidden

You don't have permission to access /flashdata/services/amfphp/ on this server.

Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.
Apache/2.0.63 (Unix) mod_ssl/2.0.63 OpenSSL/0.9.7a mod_auth_passthrough/2.1 mod_bwlimited/1.4 PHP/4.4.8 Server at blogs.roanoke.com Port 80

please assist.

yeahhhhhaaaaaa, Great flash example, I love it

amax's picture

Hi Guys, I finally got the flash example above with AS2, flash 8, posted by averageyoungman working. After pulling my hair out

for ages trying to figure out what was wrong, it ended up being an issue with enabling clean URLs and my htaccess file. Hours

of googling solved it, and now I can connect fine to my flash, everything is perfect, almost.

Coming from an animation background, connecting flash and drupal is my first adventure in the arena. What I would love help on

now is actually what way I should set up my flash file to take advantage of my drupal connection.

I basically have a 50 pages / nodes that I want to extract the title and body info from into dynamic text boxes on stage.

What I currently have is:

import mx.remoting.Service;
import mx.remoting.PendingCall;
import mx.rpc.RelayResponder;
import mx.rpc.FaultEvent;
import mx.rpc.ResultEvent;
import mx.remoting.debug.NetDebug;
mx.remoting.debug.NetDebug.initialize();

var node:Service = new Service("http://www.xxxxx.com/services/amfphp", new Log(), "node", null, null);

var pc:PendingCall;
function callMe(num,resultfunc){
pc = node.load(num);
pc.responder = new RelayResponder(this, resultfunc, "getData_Fault");
}

callMe(133, "getData_Result");
function getData_Result( re:ResultEvent ):Void {
mytextbox.htmlText = re.result.body;
}

callMe(134, "getData_Result2");
function getData_Result2( re2:ResultEvent ):Void {
mytextbox2.htmlText = re2.result.body;
}

If I have 50 text boxes I want to fill from Drupal content, does that mean I have to make 50 "call me" functions to populate my boxes or is there a better way I should be doing this?

No! Don't make 50 functions or 50 service calls.

averageyoungman's picture

The node service only accepts one node per query - or at least it did the last time I used it. You should look into the taxonomy.getTree and taxonomy.selectNodes services. getTree will allow you to select all term IDs under a vocabulary given a vocabulary ID, and selectNodes will select all the nodes from a term, or array of terms, given the term IDs you want to select from. Unless you want to write your own service, you should look into these or look for contributed services that might fit the bill. If all your nodes are in terms under one vocabulary, you should be able to use the taxonomy service and methods using one client-side service call.

Aside from that, you might want to try writing a node service that allows you to select a range of nodes based on some other criteria like uid, name, type etc.

For certain, you shouldn't write a loop that makes one query per node. You should select all the nodes you need with one query if possible.

50 nodes through views

JoachimVdH's picture

if you create a view with views, you can get the 50 wanted nodes in 1 request.
( see views service )

Great!

Monica L's picture

Thank you for showing us this, it was very interesting!

Monica, IT Freelancer currently working on the How To Get Bigger Erection project.

Monica, IT Freelancer currently working on the How To Get Bigger Erection project.

My latest experiments as follows

amax's picture

Hi Guys,

As promised, my updated experiments with taxonomy below. This is working fine at present and should help any beginer like myself out who simply wants to pull in text for a banner etc. However,
I have 2 issues with various Terms I am trying to load into flash as I want to expand. My code at present is as follows:

import mx.remoting.*;
import mx.rpc.*;
import mx.remoting.debug.NetDebug;
import mx.utils.Delegate;
var gatewayUrl:String = "http://www.xxxxx.com/services/amfphp";
NetDebug.initialize();
var taxonomy:Service = new Service(gatewayUrl, null, 'taxonomy', null, null);
function getContent() {
//var pc:PendingCall = taxonomy.getTree(1);
var pc:PendingCall = taxonomy.selectNodes([22], ['title', 'body']);
pc.responder = new RelayResponder(this, "handlegetContent", "handleError");
}
function handlegetContent(re:ResultEvent) {
var rs:Object = re.result;
for (var i:Number = 0; i<rs.length; i++) {

    //trace(i);
    _root["txt_title"+i] = rs[i].title;

    //trace(rs[i].title);
    _root["txt_body"+i] = rs[i].body;

}

}
getContent();

function getContent2() {
//var pc:PendingCall = taxonomy.getTree(1);
var pc:PendingCall = taxonomy.selectNodes([23], ['title', 'body']);
pc.responder = new RelayResponder(this, "handlegetContent2", "handleError");
}
function handlegetContent2(re:ResultEvent) {
var rs:Object = re.result;
for (var i:Number = 0; i<rs.length; i++) {

    //trace(i);
    _root["term2_title"+i] = rs[i].title;

    //trace(rs[i].title);
    _root["term2_body"+i] = rs[i].body;

}

}
getContent2();

Within the flash - I have simply lots of Dynamic text fields on stage with the variable lable properties box filled in as follows:
_root.txt_title7 and _root.txt_body6 etc etc depending on what number [i] refers to in my loop from drupal.

For getContent2();, my text fields properties are simply labeled as _root.term2_title7 and _root.term2_body_title7 etc etc

Issue 1 - Am I going about this the right way ? or can someone please point me in a better direction. My actionscript / programming knowledge is basic coming from a design background to Drupal. Is it ok to use functions / text box labelling like this for say 20 terms thus getContent3();, getContent4(); etc

Issue 2 - If I add a new page to drupal with one of my terms, I find I have to go back and renumber my text fields properties in flash from say _root.term2_title7 to _root.term2_title8 as each new term added seems to get numbered in Drupal as "0" up. this is killing me when I want to add something

PS I hope I am not annoying anyone with these posts but I am determined to get my head around some actionscript and drupal. I find it very interesting

you could use Charles for

g10's picture

you could use Charles for what you are trying to do ( http://www.xk72.com/charles/ )
this program monitors your connections, and shows the calls and the responses from your service calls in a readable way ( nicely structured objects ), which is handy to filter out the fields that you actually want ( because the objects coming from drupal can be big and contain unnecessary values )

mohamedmustaf's picture

Hi I need a sample how to use the service for user login and log out since i am using flex as frontend. I have conected the database and worked out with the smpale but i am able to login even if i provide a wrong username and password. Please help me out how to use the user service in amfphp.

You are able to login with a

redben's picture

You are able to login with a wrong username and password ? how ? can you explain more and/or post your flex code ?

Same issue

leoman_730's picture

I encountered the same issue for user.login.
It should be very easy to re-create the problem
Just create a simple login form in flex, and then call the user.login("username","password"). Ok, i can connect to the remote server and play as normal. Then I close the program, and enter ramdon user name and password, bingo...
I am able to login.

I think the issue is with the session. Once user.login() call is success, it create a session and that session never expire. Why i say that? because after i clean up all the session and cookies from my browser, and i try login using ramdon name, it throw me an authentication error.

I have tried using user.logout(), but that didnt work.

Any idea would be great. Thanks.

autologout

freddymx's picture

I'm using automatic logout module => http://drupal.org/project/autologout ... using user.logout worked for me sometimes

FREDDY

FREDDY

What do you mean by

ven's picture

What do you mean by "sometimes"?

I can't get user.logout() to work either. I am not using autologout, though I will eventually. But for now i would prefer this simple function to work, seems like I'm not getting something here.

Weird thing is that user.logout() just silently fails. I do not get showBusyCursor or any fault/result event at all. All other functions I have tested so far works as a charm.

[Edit]

Problem was Flex. See http://drupal.org/node/178051

Have to use user.getOperation('logout').send() instead.

Data Grid Data

ryosaeba's picture

Dear Drupal Friends

I've try to make a mxml application in FLEX that read by AMFPHP a nodes

Well my mxml code is:

<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute" creationComplete="init()">
<mx:Script source="main.as" />
<mx:RemoteObject showBusyCursor="true" destination="amfphp" sorce="views" id="views">
   <mx:method name="getView" result="onViewsResult(event)" fault="onFault(event)" />
</mx:RemoteObject>
<mx:Panel width="500" height="400" layout="absolute" title="Recipes" horizontalCenter="0" verticalCenter="0">
        <mx:DataGrid x="10" y="10" width="460" height="204" id="recipes_select" dataProvider="{recipes}" >
           <mx:columns>
             <mx:DataGridColumn headerText="NID" dataField="nid" width="40"/>
               <mx:DataGridColumn headerText="Dish" dataField="title"/>
         </mx:columns>
        </mx:DataGrid>
       <mx:Label x="10" y="222" text="Dish"/>
     <mx:TextInput x="10" y="241" width="460" id="dish"/>
     <mx:Label x="10" y="278" text="Recipe"/>
       <mx:TextArea x="10" y="294" width="460" height="56" id="recipe"/>
      <mx:Button x="416" y="267" label="Save"/>
      <mx:Button x="420" y="217" label="New"/>
   </mx:Panel>
 
</mx:Application>

And my Actionscript code is:

// ActionScript file
import mx.controls.;
import mx.rpc.events.
;
import mx.rpc.remoting.*;
import mx.utils.ArrayUtil;
import mx.events.ResizeEvent;



[Bindable]
public var recipes:Array;

public function init():void
{
getRecipes();
}

public function onFault(event:FaultEvent):void
{
  Alert.show(event.fault.faultString, "Error");
}

public function onViewsResult(event:ResultEvent):void
{
recipes = ArrayUtil.toArray(event.result);
}

public function getRecipes():void
{
  views.getView("recipes_all", ['nid','title','body','changed']);
}

Well... If I try to run the application i see this error:

http://www.walterfantauzzi.com/forum/drupal_flex/img_f_d.jpg

I can't understand why I've this error...

Someone can help me please?

I noticed

behindthepage's picture

ryosaeba

4th line in MXML code has a smelling pistake.
sorce="views"

<mx:RemoteObject showBusyCursor="true" destination="amfphp" sorce="views" id="views">

Regards
Geoff

Regards
Geoff
The user previously known as gpdinoz

Hi ryosaeba, I'm a noob as

david.d.patrick's picture

Hi ryosaeba,

I'm a noob as well, still I can offer a few comments about getting this Flex / Drupal to work.

  1. Have you checked your service through Drupal (Admin -> Build -> Services) and checked your settings to make sure use keys, strict domain checking and use sessid are unchecked.

    1. Have you tried the service out by clicking it to see if you can add and or delete a node or (recipe) only in Drupal. You've got to make sure Drupal back end works first before you try it Flex/ Flash, or you'll get runtime errors.
  2. If you can include a copy of the service you're using it would be a great help, so I can recreate the issue on my end to help better figure this out.

                         ****Also I like your web site intro , pretty freakin sweet!*****   
    

    Drupal and Flex yeah!!!!

Drupal and Flex yeah!!!!

Services + AMFPHP vs. AMFPHP

lambeco's picture

I'm trying to get this to work with Flash/AS3 and I'm having a little difficulty. Here is the AS3 code I'm using:

package {
    import flash.display.Sprite;
    import flash.net.Responder;
  
    import RemotingConnection;
   
    public class Document extends Sprite {
        public var dataProvider:Array;
        public var gateway:RemotingConnection;
     
        public function Document() {
            this.init();
        }
      
        public function init() {
            /This works, but doesn't give me access to Drupal data/
            //var gatewayUrl:String = "http://XXXXXX.COM/DRUPAL_SUBDIR/modules/amfphp/amfphp/gateway.php";

            /This doesn't work/
            var gatewayUrl:String = "http://XXXXXX.COM/DRUPAL_SUBDIR/services/amfphp";

            gateway = new RemotingConnection(gatewayUrl);
            var responder:Responder = new Responder(onResult, onFault);
            var arg:String = 'foo';
            gateway.call( "HelloWorld.say", responder, arg);
        }
      
        public function onResult(result):void {
            trace('onResult invoked');
            trace(result);
        }
    
        public function onFault(error:Object):void {
            for each(var node in error) {
                trace(node);
            }
        }
    }
}

This is what gets traced out when the whole thing goes south:

Method <em>HelloWorld.say</em> does not exist.
101
User Error
/WEBROOT/domains/XXXXXX.COM/html/DRUPAL_SUBDIR/modules/amfphp/amfphp.module
AMFPHP_RUNTIME_ERROR

However, when I access the gateway directly (the first gatewayUrl), it returns:

onResult invoked
You said: foo

I sorta figured that maybe the AMFPHP module maintains its own services and doesn't repeat the services in the /modules/amfphp/amfphp/services directory, but the AMFPHP browser doesn't work using "http://domain.com/drupal_subdirectory/services/amfphp" either (though it works with a direct URL to gateway.php), throwing this error:

(mx.rpc::Fault)#0
  errorID = 0
  faultCode = "AMFPHP_RUNTIME_ERROR"
  faultDetail = "/WEBROOT/domains/XXXXXX.COM/html/DRUPAL_SUBDIR/modules/amfphp/amfphp.module on line 101"
  faultString = "Method <em>DiscoveryService.getServices</em> does not exist."
  message = "faultCode:AMFPHP_RUNTIME_ERROR faultString:'Method <em>DiscoveryService.getServices</em> does not exist.' faultDetail:'/WEBROOT/domains/XXXXXX.COM/html/DRUPAL_SUBDIR/modules/amfphp/amfphp.module on line 101'"
  name = "Error"
  rootCause = (null)

Sorry for the wall of text, but this is driving me insane, and I'm having a really hard time finding information that could help me with this. There don't seem to be any comprehensive tutorials. I'm planning on writing one, start to finish (for people like me who are new to Drupal) once I have this sorted!

Thanks!

Hi lambeco, firstly, the

vannen-gdo's picture

Hi lambeco,

firstly, the URL

http://XXXXXX.COM/DRUPAL_SUBDIR/services/amfphp

is the one you want to use to connect to the services module. It definitely should work as I've been using it!

You're trying to call helloworld.say, which I'm assuming is the Hello World example that comes with AMFPHP? if so, the URL you need to connect to the Hello World example service is

var gatewayUrl:String = "http://XXXXXX.COM/DRUPAL_SUBDIR/modules/amfphp/amfphp/gateway.php";

So what's happening is this (by the sound of it) - you're connecting to the hello world example just fine. But you're then trying to get Drupal data out of helloworld, which it isn't set up for. Helloworld is just a simple few lines of code that echoes back to you.

What you need to do is to go into your modules, enable services (really?! ;-) ) services-servers-AMFPHP, and, say, the node service or views service.

Then, the gateway you use is:

http://XXXXXX.COM/DRUPAL_SUBDIR/services/amfphp

And, instead of calling helloworld (which you can't access from this gateway), you call the node or view service.

In my code I use:

connection.call("views.getView", responder, viewName, arrayOfArgs);

Where views.getview is the service. It gets a view that I've specified as a string var viewName, with an array of arguments. The arguments are optional, so maybe leave them out 'til you've got the connection running?

Hope that helps, feel free to ask for more assistance!

DV

That did it!

lambeco's picture

Thanks so much, vannen! That worked.

For those stuck like me, my gateway call now looks like this (make sure you actually have a node to load):

var responder:Responder = new Responder(onResult, onFault);
var arg:int = 1;
gateway.call( "node.load", responder, arg);

Can someone just post a

jjjames's picture

Can someone just post a simple way to authenticate a Flex app using automatic login and API key? I want to use Air so it needs to automatically log in and have the ability to retrieve and create nodes. This sure is hard information to find!
Thanks

Not working

rwsprashant's picture

hey I am using the same steps but not getting the proper result
I am getting the following error .. Please help me
fault: [RPC Fault faultString="Send failed" faultCode="Client.Error.MessageSend" faultDetail="Channel.Connect.Failed error NetConnection.Call.Failed: HTTP: Failed: url: 'http://suse/websites/rightway/work/greg/vitaplanner/drupal5/services/amfphp'"]

Gateway

seppestaes's picture

AMFPHP 1.9 needs to be installed in the 'amfphp' folder within your drupal installation.
The path to the gateway will be something like

"{server}/suse/websites/rightway/work/greg/vitaplanner/drupal5/services/amfphp/amfphp/gateway.php"

(see three posts up, vannen)

Very stupid question

aikiken's picture

Would it be too hard for someone to take me by the hand and tell me how to actually use the resulting mxml file in drupal? I can't seem to find this info here or anywhere but you all seem to know... Please... :)

re

verticalwave's picture

You don't use the flex MXML file in drupal, but you compile the code and upload the swf file to drupal.
The swf file is located under the bin folder from your Flex Project.
In order to do the upload you can use Flash Node module for that. http://drupal.org/project/flashnode
Hope this answers your question.

failed to retrieve node

babymission's picture

I am running drupal 6.x in the Localhost (in Linux) for a while, everything is working ok so I tried to connect the flex application in drupal

I previously installed the Dashplayer so I already get the services, amfphp, views, etc working according to the instructions, and the Dashplayer is working fine.

In the user permission, I already check the permissions (for both annoymous and authenticated users) for all necessary access such as access content, load any node data, load own node data, access services, upload files, view upload file, access all views.

The service browser is also working fine, but I need to put the exact path "http://localhost/drupal/modules/amfphp/amfphp/broswer/index.html" in order to access to the browser screen. The link "Load the service browser" given in the service module does not work for me.

Then I compiled the flex project in Windows using flex builder, according to the instruction given here, and then I copied the swf file in the bin-release folder, and then go to drupal in my linux localhost to create a node, and attach this swf file to the node. I then double click the swf file drectly in the node. It shows up the interface page. But when I click the nodeLoad button, it did not return any anything, but keep showing the message "Transferring data from localhost...." at the status bar at the bottom and nothing really happened. I also checked the crossdomain.xml file (I put it in /var/www/drupal)to make sure it allows the localhost.

The endpoint uri I assigned in the services-config.xml file is "http://localhost/drupal/services/amfphp"

I also try many different endpoint uri (e.. use the actual path, with gateway.php, put localhost:80, et),but it is still does not work.

In the service settings, I already unchecked the User key and User Sessid.

I read some posts saying we need to put the drupal user login in the flex? but it was also said that as long as we check all the required user permission in drupal, it should be fine.

Can anyone give me some hints and helping hand to me as I have been working many weeks already and still did not get flex connected to drupal. Thanks.

Clean URL's enabled?

seppestaes's picture

Already mentioned in one of the posts above, so just to check: do you have clean URL's enabled?
If not, you could maybe try something like:

http://localhost/drupal/?q=services/amfphp

in your services-config.xml

or enable clean URL's

yes, I already enabled the

babymission's picture

yes, I already enabled the URL's, but it is not working.

How set Limit

jérômeC's picture

Hi,

I tried to set limit to 5, i would like my services give me just the 5last comment of my blog..(for example). But the limit dont work .

var fields:Array = new Array();

DrupalViewsNews.get('MyViewName',fields,fields,fields,5); <- i set the limit to 5

How can i do plz ?

Configure number of blog posts in views

z3cka's picture

I would use a view to display your blog posts through the services
module. Just configure your view to output the lastest 5 posts rather than trying to code it. Allow the server side object to be defined by views, then go retreve the array.

Hope that helps. Let me know.

-Casey

Ok but when i configure my

jérômeC's picture

Ok but when i configure my view directly from drupal, when i try it in drupal, thats work. But when i call my views from Flex, the view give me all my post...

Hmmm I would have to see you

z3cka's picture

Hmmm I would have to see you flex code and your views setup.

Error for this sample

molcom's picture

Hi!
I just tried this sample and I get an error:
fault: [RPC Fault faultString="Method node.load does not exist." faultCode="AMFPHP_RUNTIME_ERROR" faultDetail="D:\xampp\htdocs\drp613\sites\all\modules\amfphp\amfphp.module on line 106"]

I use Drupal 6.13. Any idea?
I'm looking in node_service and no load method, is a get method. I tried get method but the same error with node.load
Thanks,
Mihai

Indeed D6 replaced node load method with get method

waldmanm's picture

Hi Mihai,

This is probably not relevant anymore (I hope) but since there hasn't been a reply, I'll post one for completeness.

Indeed the D5 node load method was replaced with node get method. Make sure that you change it in all places, specifically in the remote object definition and also when calling the function on button click (in the above example).

Micah

AMFPHP_RUNTIME_ERROR

amalan's picture

Hi Molcom,

We are also try to configure in local...but get same error like the following....

"
fault: [RPC Fault faultString="Missing required arguments." faultCode="AMFPHP_RUNTIME_ERROR" faultDetail="C:\wamp\www\drupal_demo\sites\all\modules\amfphp\amfphp.module on line 106"]"

got any solution for this? if you have any idea/solution send me to amalanmca@gmail.com

Thanks in advance !

Found the solution!

coral's picture

I found the solution to this problem!

Go here: http://www.YourSite/admin/build/services/settings

and disable Use keys and Use sessid!

Method views.getView does not exist

uvo's picture

Hi!
I'm new to drupal and Flex. To start I tried out the http://files.thisbythem.com/screencasts/services-2.mov recipes_all tutorial. Using drupal 5... everything worked fine.

Now i upgraded to 6.15 and i get the error "Method views.getView does not exist". For days now I'm searching for the right way to call the new method views.get in the public function getRecipes(): void{views.getView("recipes_all", ["nid", "title", "body", "changed"]);} bud i can not find a solution to this problem.

Thanks for your help!

uvo

It's views.get

gabilee's picture

the mxml code is:

  <mx:RemoteObject showBusyCursor="true" destination="amfphp" source="views" id="views">
    <mx:method name="get" result="onViewsResult(event)" fault="onFault(event)" />
  </mx:RemoteObject>

and the AS code is:

      views.get("test_view");

-
Gabi Lee, סרגטה פיתוח תוכנה

Updated Example

wendell's picture

I have created a library (com.wwbtc.drupal) that should make it very easy to interface Drupal (with keys!!!) and Flash. Download Example2.rar and have a look.

http://www.wwbtc.com/content/easy-drupal-amfphp-flash

In case anyone is still subscribed to this thread :)

xyz

sabyasamuel's picture
* Login
  ← Back
  Login with Pissed Consumer Account
  Log In to Pissed Consumer or Sign Up.
  Your email address or username *
  Your password *
  Remember me Forgot Your Password?
      o
      o
      o
  show-popup
* Signup

← Back
Sign up
- Stay informed about any comments on your review.
- Write updates for your reviews any time you want.

Please try again later.
Username *
E-mail *
Password *
Remember Me
CAPTCHA What code is on the image *

Fields marked with an asterisk * are required.
PissedConsumer
Follow us:

* Submit complaint
* Companies
* Browse complaints
* Business solutions
* Blog
* Sample Complaint

Shares 0
xyz

xyz reviews, xyz complaints, read xyz reviews, find xyz reviews, xyz scam reports
Industry: Cosmetics and Toiletries
xyz social reviews and reports. Join community by posting your own comments or complaints.
xyz is a brand owned by Bellezza Products, LLC. It is an innovative anti-aging solutions line aimed at visible reduction up to 60% of thin lines and wrinkles. It has become a famous skin-care ... line since 2007. xyz rejuvenates face skin by reducing the signs of visible aging including age spots and crow's feet. As a result of using xyz products, skin becomes smoother, softer and more elastic. The xyz cosmetic line includes products in the following categories: rejuvenating, cleansing, balancing and finishing products, including lotions, tonics, cream, masks and more. xyz ultimate ingredients include Matrixylâ"žÂ¢ 3000 (collagen production stimulant), Argireline (amino acids combination), Hyaluronic Acid and SPF 15. Show more

Please try to contact xyz Customer Service directly prior to posting any complaints on this site.
Is this company description incorrect? Suggest changes
xyz

xyz Reviews and Complaints
Total Complaints 21
Claimed losses $2,273

* All
* Cosmetics and Toiletries (17)
* Advertisements and Cons (2)
* Health and Beauty (2)

More categories
Show complaints near me

* Everywhere
* ASHEVILLE(1)
* BARTLESVILLE(1)

* Latest
* Top rated
* Recently discussed
* Media

More locations

428757

Thibodaux, Louisiana
Jul 12
xyz - xyz took my money and it was he'll to get them to stop!
xyz
http://www.pissedconsumer.com/

I was scammed not once but twice!!! My daughter tried it without me knowing. I tried it and when I noticed the charges coming out of my accounts I was furious!!!! I tried to stop the charges and that was *** it took a act of congress to stop it!!, then I demanded refunds well I should have been talking to the wall because the wall would have helped me more!!!! I told xyz that they...

* xyz wrinkle cream

* by Anonymous
* 0 comments
*   1
* Cosmetics and Toiletries

427118

Jul 08
xyz - Mrs
xyz
http://www.pissedconsumer.com/

Hello, I understood that I was paying $1.99 for postage only for a free sample of xyz and have now recieved a charge of $69.95 + transfer fee of $1.61 on my credit card. I did not authorise this payment and would like to know what to do. This is obviously a scam and would really like to have my money refunded. The product is in a very small jar - looks like a sample and is not worth what...

* by maggie...
* 0 comments
*   1
* Health and Beauty

413448

Toronto, Ontario
May 30
xyz - overcharge
xyz
http://www.pissedconsumer.com/

Last March 5 I got an email from tepal amazing offer and coupon when I go to the website I saw this xyz that I never heard before. It said trail for 1.99 I said this is true I sign in and I gave my credit card. April 5 here this 2 bottle came when I got it in the post office I have to pay 29.85 Canadian dollar I said in the post office they didn't told me that is a shipping cost I Told...

* Post office
* Canadian dollar
* tepal amazing offer

* by Anonymous
* 0 comments
*   1
* Cosmetics and Toiletries

412176

May 26
xyz - Former employee
xyz
http://www.pissedconsumer.com/

I worked for this company a little over 2 years ago. I admit that their advertising is questionable, but what's worse is their business sensibility. They had a call center manager that was inflating numbers to make it look like we were doing better than we actually were, a "higher up" having relations with his assistant and several leads and supervisors who were drinking on the job selling...

* customer base
* job selling prescription
* advertise deceitful marketing

* by Anonymous
* 0 comments
*   1
* Advertisements and Cons

408426

May 13
xyz - misleading ad
xyz
http://www.pissedconsumer.com/

wanted the trial item but I was billed and still am being charged 119.00 plus 40.00 shipping I was told not to take the tv reliable source.phone automated ordering is deceptive.i see very little improvement. it is not what it appears on the ad you expect rep, was rude and proceeded to say i could not return it that quickly.i did not want my card charged,i assumed way too much with this company...

* why i get bags
* trial item
* tv ad

* by Anonymous
* 0 comments
*   1
* Cosmetics and Toiletries

406130

May 06
xyz - Joann Lucero complaint did not get refund
xyz
http://www.pissedconsumer.com/

I ordered xyz when it was first advertised on tv. I have received a notice in the mail. The notice is under my name Joann Lucero 55-A upper San Pedro Rd. Espanola, N.M. 87532 I would like to join in the law suit.I have rea d review that the product is un safe and that is why I did not want the product. I don't have record of the company refunding money to my credit card. I have been...

* Fraud
* Pleading
* Appeal

* by pepito
* 0 comments
*   1
* Advertisements and Cons

404654

San Luis Obispo, California
Apr 30
xyz - no refund big time run around
xyz
http://www.pissedconsumer.com/

They advertise full refund, they claim you did not return the merchandise, and on it goes. They want a delivery confirmation number, they say that they have a different order number. It is very frustrating and the product is nothing more than mere cold cream or hand lotion! They give mail order people a bad name that is for sure. I finally told them I give up and they can keep the money it is...

* Internet
* Mail
* Frustration

* by Anonymous
* 0 comments
*   1
* Cosmetics and Toiletries

395488

Thomasville, Georgia
Mar 25
xyz
xyz
http://www.pissedconsumer.com/

when cancelled they continue to charge for return product I feel I have been scammed this company is over charging people for something they don't have If there is a law against this please let me know I can only put stop payment at my bank and that cost 35.00 dollars and they charging me four payments of 69.95 this company is a big scam if any one else has a better solution please e-mail...

* Electric charge
* Credit card
* Receipt

* by minnie...
* 0 comments
*   1
* Cosmetics and Toiletries

391323

Adelaide, South Australia
Mar 08
xyz - Unauthorised monies stolen from account
xyz
http://www.pissedconsumer.com/

I only ever ordered a free sample for $1.99 postage, now they are arriving erratically with $16.00 taken out of my account every month for postage and then a further $140 a month for products I am not even receiving. I have never signed nor authorised any products to be sent to me, and never at this price per month. I am so angry that it has taken me months to notice. my name is Alanna Gray and...

* Price
* Value

* by alanna...
* 0 comments
*   1
* Cosmetics and Toiletries

355923

St. Charles, Missouri
Nov 01, 2012
Sent 2 jars of xyz and put unwanted charges on my credit card. I'm returning unused jar.
xyz
http://www.pissedconsumer.com/

This product also caused some irritation on my face. So I don't think it is cracked up to be what the advertisement says. I returned the unused portion of xyz cream. I am called my credit card company and advising them not to put anymore charges on my account without my permission from three companies that are a scam - Great Fun, Budget Savers and Savings to Go. Please alert the...

* credit card company
* unused portion
* anymore charges

* by Anonymous
* 1 comment
*   4
* Health and Beauty

Showing 1-10 of 21 complaints

* Previous
* 1
* 2
* 3
* Next

To the Top
Companies similar to xyz

* Hair Sisters
* Rocket MakeUp
* Nicholas Perricone
* Boots
* Lift serum pro
* EvolutionMD
* Chelleon
* Clarisonic Canada
* Olay
* Beautydotcom
* Dermagist Skin Care Products
* Kandyz
* Party Gals Taboo Essentials
* SpaBoutique
* LoveShantea
* NuVela21
* Filo America
* MH3
* New You Med Spa
* Rejuvenex
* TryPinkArmor

All companies in this industry

Submit complaint

abc

sabyasamuel's picture

Bellaplex and abc
Bellaplex and abc review
Menu
Skip to content

* Home

Where to buy Bellaplex and abc
8 Replies
Bellaplex and abc is a SCAM| Do not buy

Hi guys,

bellaplexandabcsmileI usually don’t complain, but after being billed two months in a row after I canceled my subcription, I got really pissed because they took my money for products that didn’t even work.
abc and Bellaplex didn’t work

I found bellaplex online and I did a quick research online about this product and it was suggested to to use abc for better result.Since It was a free trial and the product seemed legit, I tried both products.After following the instructions and using both products, I really didn’t see no results, my skin didn’t improve at all.The bellaplex cream smelled really bad also, I had to put extra layer of perfume to cover the strong smell, it litterally smelled like rotten milk.Since It was a free trial, I decided to cancel my subscription for both products.

After the cancellation, they kept mailling me the products and billing me for it.To get a refund, I returned both products with my transaction number and guess what they didn’t return my money.To make matters worst the next month they billed me again and didn’t even bother to send me the products, that’s how I figured out that it was the same company selling Bellaplex and abc.I was so pissed, I had to contact my credit card company to have them stop billing me because it was started to become ridicalus, and luckely I was able to get a full refund.
Why I recommend Truvisage over abc and Bellaplex

BellaplexAndabc3ed4rEven after my bad experience with abc and Bellaplex, I was still desparate into solving my aging skin issues.I joined many Facebook groupes that were talking about skin care products, and one user caught my attention because she supposely 57 years old and had a flawless skin for her age.I sent her a friend request.She accepte me, I told her my situation, and I asked her what products those she uses to have such a young looking skin.She said she have been using Truvisage Anti-Aging cream for only 2 weeks now.She recommended me to try Truvisage for free and she swore that it was not a scam like Bellaplex and abc.She send me her before and after picture. LOOK BELOW:

bellaplexandabcfriend2bellaplexandabcfriend1

CLICK HER TO TRY TRUVISAGE FOR FREE
My experience with TRUVISAGE

After 3 weeks, I was getting impressive results, I was shocked on how clear my skin was under one month.Look at the picture below:

BEFORE

Bellaplexandabcokface

AFTER 3 WEEKS

bellaplexandabcstar

After the trial period, Truvisage got ride of most off the my wrinkles around the eyes.Look at the picture below:

Before

bellaplexandabcundereyebefore

After one month

beforeandabcundereye

After using Truviage for over 3 months, my skin is clear and has almost no wrinkles.
I look like as if I was still 27 years old lol !!!

bellaplexandabc26yearsoldbellaplexandabcwithhat

Left: Me at 27 years old Right: Me at 48 years old

I strongly recommend you guys to try Truvisage for FREE, I garantee that you will be so impress that with no hesitition you will purchase next month supply.For a free trial, you can only get this promotion from their official website.

CLICK HERE FOR YOUR FREE TRIAL

This entry was posted in Uncategorized on March 30, 2013 by Admin.
Search for:
Recent Posts

* Where to buy Bellaplex and abc

Recent Comments

* touchscreen gloves on Where to buy Bellaplex and abc
* cheap mens suits on Where to buy Bellaplex and abc
* We make the best selection of the most selling products online on Where to buy Bellaplex and abc
* Revitalize Skin Cream on Where to buy Bellaplex and abc
* fake oakleys polarized on Where to buy Bellaplex and abc

Archives

* March 2013

Categories

* Uncategorized

Meta

* Log in
* Entries RSS
* Comments RSS
* WordPress.org

Proudly powered by WordPress

pqr

sabyasamuel's picture

Feedburner Receive our consumer tips & recalls newsletter by e-mail

Feedburner count
WRITE REVIEWCATEGORIESRESOURCESMY ACCOUNT
Home > Health & Beauty >
Facebook
Twitter
Google+
LinkedIn
pqr

Star Empty star Empty star Empty star
84 Reviews & Complaints
Top Customer Complaints & Reviews:
Beware Of The pqr Free Trial Offer, What They don't Tell You!
While driving, I was listening to a really long advertisement on the radio about this pqr cream and how amazing it was, it went on to say that I could receive a 30 day free trial, I'd pay 7.95 for S&H.
Doesn't Work, They'll take your money even if you Cancel
pqr, What was I thinking? Just ordering the product took an hour because I had to decline an endless loop of automated product solicitations.
pqr Free Offer Is A Setup - Beware!
I saw an ad for 30-day risk free trial of pqr anti-aging cream and decided to order it.

Latest Reviews:
StarEmpty StarEmpty StarEmpty StarEmpty Star
Former Employee - Customer Service
I worked for this company a little over 2 years ago. I admit that their advertising is questionable, but what's worse is their ...
-- Informative Posted by Ajtheamazing1 on 05/26/2013
StarEmpty StarEmpty StarEmpty StarEmpty Star
They Suck - Eye cream for dark circles
It does not work. I called to cancel in mid December and they said they would. and yet I keep seeing they are taking money out ...
-- Informative Posted by Tmkreiger on 01/25/2013
StarEmpty StarEmpty StarEmpty StarEmpty Star
Complaint - pqr-- Complaint Posted by Jill.brott on 12/18/2012
StarEmpty StarEmpty StarEmpty StarEmpty Star
They are a scam
I am going through the same thing. I returned the stuff and cancel. As they said. Then not even a month later they took out 69.95 ...
-- Complaint Posted by Blue_eye_blonde_taken on 12/14/2012
StarStarEmpty StarEmpty StarEmpty Star
Returns Only during Trial period! - pqr Advanced Under Eye Formula
I purchased this product awhile ago when I saw a very convincing television advertisement about diminishing darkness, wrinkles, ...
-- Complaint Posted by Tina823 on 11/25/2012
StarStarStarStarEmpty Star
If You Read the Terms
BIDDEFORD, MAINE -- If ANY of you people took the 30 seconds it takes to READ the "terms and conditions" box that YOU HAVE TO check and accept to ...
-- Informative Posted by Nhall1212 on 11/12/2012
StarEmpty StarEmpty StarEmpty StarEmpty Star
Cancel this product was billed for it -- Complaint Posted by Sylviashearin on 09/30/2012
StarEmpty StarEmpty StarEmpty StarEmpty Star
- Trial offer of 90 Second InstantEffect Winkle Reducer
serious complaint about pqr...Was calling to pay my credit card bill one day. Somehow I in turn got sales people for ...
-- Complaint Posted by Tinawolfe100 on 09/05/2012

StarEmpty StarEmpty StarEmpty StarEmpty Star
Misleading "Gotcha" company - Facial Creams
I ordered a 'free 30-day-trial of this cosmetic product - $1.99 and 'if I'm not happy, I just have to send the bottles back'. ...
-- Complaint Posted by Waterrat1 on 08/02/2012
StarEmpty StarEmpty StarEmpty StarEmpty Star
Does not work - pqr -- Complaint Posted by Rdhmommy on 04/19/2012
StarEmpty StarEmpty StarEmpty StarEmpty Star
IT DOESN'T WORK! - pqr
I used pqr as directed with no results whatsoever. I used it for the recommended amount of time and not only did I not ...
-- Complaint Posted by Glensidegirl505 on 04/01/2012
StarEmpty StarEmpty StarEmpty StarEmpty Star
could not use the product because it broke my face out they refuse to cancel my orders and are still charging my credit card - am/pm anti wrinkle complex spf 15
After I received the product I tried it and it broke my face out the next day. I then emailed the company and called them to ...
-- Complaint Posted by Baileytracey52 on 02/24/2012
Corn!!! Not Straightforward and Clear
ELGIN -- I had ordered onlline the pqr and Juveneu anti wrinkle cream, gave all my details away and been charged far more than ...
-- Complaint Posted by Maria_olah25 on 11/30/2011
Not Enough Info - pqr Cream -- Complaint Posted by Sylviagavan on 09/05/2011
Did not let me know I would have to pay for product, said that I would have to pay $1.99 for postage - pqr
pqr was advertised and it stated that you would have to pay only$1.99 postage they have already taken $69.95 out of my ...
-- Complaint Posted by Me_breda2004 on 09/03/2011

PR

sabyasamuel's picture

Sabol v. PQ LLC
Home Case Documents File A Claim Frequently Asked Questions Contact Us En Español

Welcome to the Sabol v. PQ LLC Settlement Website

SUMMARY OF CASE

A proposed national settlement has been reached in class action proceedings brought against PQ LLC and PQ (“Defendants”) relating to their sale or offer of products under a Risk Free Trial and/or Auto-Shipment Program (also known as “Preferred-Customer Beauty Program” or “Beauty Auto-Ship Program”).

The case is entitled Susan Sabol, et al., v. PQ LLC and PQ. If you are a member of the Settlement Class, your rights may be affected by this lawsuit. Please read all information on this website carefully. The purpose of this website is to provide information about the lawsuit and proposed Settlement so that potential class members can decide what steps to take, if any. The Settlement Class is defined as follows:

    All Persons residing in the PQ who between January 1, 2005 and March 28, 2013 paid for, and/or were charged for PQ-branded products, and/or were charged shipping and processing fees for such products, in connection with a Risk-Free Trial and/or Auto-Shipment Program, including but not limited to: PQ, PQ, PQ, and Orexis.

Defendants deny any wrongdoing and do not believe that they have any liability to the Settlement Class. However, all parties believe it is in their best interest to settle the Action under the terms of the Amended Settlement Agreement and obtain closure on these matters. The Court in charge of this case has preliminarily approved the Amended Settlement but still has to decide whether to grant final approval. Payments and settlement benefits will be made only if the Court grants final approval of the Amended Settlement and after appeals, if any, are resolved.

DESCRIPTION OF BENEFITS

The Amended Settlement Agreement provides for cash benefits, product benefits and prospective relief to eligible Settlement Class Members. A detailed description of all available benefits is included in the Long-Form Notice. You may also consult the Amended Settlement Agreement for information.

LEGAL RIGHTS AND OPTIONS

If you are a member of the Settlement Class, your legal rights and options are as follows:
YOU MAY         DEADLINE
File a claim online or by mail  Submitting a Claim Form on time is the only way to get a Cash Benefit or PQ Product Benefit.    August 15, 2013
Ask to be excluded (“opt out”)  If you ask to be excluded, you will not receive benefits, but you keep your rights to sue Defendants on your own regarding PQ products.     June 25, 2013
Comment or object to the settlement     Tell the Court why you like or dislike the settlement. You will continue to be a member of the Class and will be bound by the Settlement.   June 17, 2013
Do nothing  If you fail to either file a Claim Form or request to be excluded by the applicable deadlines, you will receive no benefits, but you will be bound by the Settlement.   

IMPORTANT DEADLINES
(Your legal rights are affected by your compliance or non-compliance with these dates)
June 17, 2013   Last day to file objection to the settlement
June 25, 2013   Last day to request exclusion
July 16, 2013   Court hearing on fairness of settlement
August 15, 2013     Last day to file a claim

Please check this website regularly for updates and new developments.

Gilardi & Co. LLC. Copyright © 2013 Privacy Policy

def

sabyasamuel's picture

def Reviews – Critical Facts You Need To Know Before Buying!
Type your search here...

* Advertise here!
* Contact
* Privacy Policy

def Scam – Free Trial Or A Total Rip – Off?
digg
Email
RSSS
digg 22 Email
Posted by Maria on March 27, 2012

def scam

def is a line of anti-aging rejuvenating products which are claimed to effectively remove wrinkles without the use of Botox. The product is supposedly being offered on a ‘free trial’ basis, the consumer has to pay only $1.99 for shipment. The product is to be returned within 30 days if the consumer is not satisfied with the

product in order to stop further shipment of the product. Seems like a pretty risk-free deal, yes? NO! This is where the def Spam jumps in.

def scam is a result of the company fooling literally hundreds of consumers about the “free-trial”. Numerous customers reported that money has been automatically being deducted from their credit cards, and monthly – a six month’s supple of def products was sent to them even after canceling their accounts for the free trial. def Spam has led to people losing approximately $69.95 monthly, even without ordering the def creams. Some have even reported that around $200 have been charged to their bank accounts.

They have been exploiting the credit-card details of their customers purely to gain money in an illegal manner. The customers claim that they returned the free trial bottles within 30 days and informed the company to discontinue the shipment of their products to them.

Remember though this is from the main company that is offering the free trials and not many of the other companies who are selling the product as you buy most products and not with a free trial.

After experiencing the def scam many people tried contacting the customer services. In several cases they were just put on hold and their calls were not answered. In other cases the customer service representatives answered the customer’s calls rather rudely, telling them that they have not canceled the free-trial package and have subscribed to the monthly one as well.

The only positive reviews can be seen from the def official websites; where it is claimed that the def scam is a campaign from the competitors, who do not want their brand to succeed. A few employees of def have commented on various threads about the products saying that the customers have clearly misunderstood the whole deal. Nothing comes for free these days; the ‘free trial’ deal is actually a ‘risk-free trial’. Some websites also suggest that refund was made to all the customers who returned their products and their subscriptions were canceled. However, the views from hundreds of people suggests otherwise.

The def scam from the main company has been filed for active lawsuit and all the customers are willing for it to face the consequences of literally ripping off people’s pocket in order to make illegal money. The company should halt all such actions and stop exploiting people’s personal information, such as, credit card details, address, etc.

We have some suggestions though. Don’t buy any free trial offer for this where they re-bill. There are other retailers online that sell this product, and you can be sure to test it out and see for yourself whether the product can work for you without worrying about the problems that have been found through the company with the situation.
Still not certain if this product is for you?
Click Here to Claim Your FREE TRIAL Bottle

Posted in def Reviews
0
Add Your Comment
Your Name
Your Email
Your Website
Your Comment
Submit

Subscribe to Our Feed
Type your search here...
Recent Posts

* def – Let’s see if this product truly works!
* Radialabs and def – Two is better than one; or is it?
* def Instant Effect – Achieve Visible Results In Minutes
* def Free Trial – Is It Really Free?
* def Scam – Free Trial Or A Total Rip – Off?

def reviews

Hello

My name is Maria , I'm 53 years old and i created this blog to give you my honest review about the def anti wrinkle cream.I hope you'll enjoy every piece of info I wrote on this blog , its all about this miracle anti aging cream that has done wonders for my face skin. If def helped me I'm sure it will help you too.

Kisses,
Maria Geller

© 2013 def Reviews – Critical Facts You Need To Know Before Buying!. Proudly powered by Wordpress

abcd

sabyasamuel's picture
* Login
  ← Back
  Login with Pissed Consumer Account
  Log In to Pissed Consumer or Sign Up.
  Your email address or username *
  Your password *
  Remember me Forgot Your Password?
      o
      o
      o
  show-popup
* Signup

← Back
Sign up
- Stay informed about any comments on your review.
- Write updates for your reviews any time you want.

Please try again later.
Username *
E-mail *
Password *
Remember Me
CAPTCHATry a different image What code is on the image *

Fields marked with an asterisk * are required.
PissedConsumer
Follow us:

* Submit complaint
* Companies
* Browse complaints
* Business solutions
* Blog
* Sample Complaint

Shares 0
0
0
0
abcd SCAM!

* by dianejohnson   Feb 07, 2012
* Review #: 295255

← Previous
14 of 21 abcd Reviews
Next →
abcd
Company abcd
Product / Service abcd
Category Cosmetics and Toiletries
Views 236

Ordered a sample online in November, 2011 from abcd because their company boasts such fabulous results."Only pay for shipping" is what this company claims".

Much to my surprise, I received not ONE, but TWO jars of cream within a week of ordering". Tried product for 2 weeks, but didn't see any results and developed a slight facial rash after 3 days:. I placed a call to Customer Service to cancel my "Membership";. Two weeks later I received an additional 2 jars (who in God's name can use 4 jars of facial cream in 2 months?) I called customer service again and was told just to return unused and unwanted merchandise, which is what I did,.

Two weeks later I received ANOTHER 2 JARS?.

I contacted customer service again and was told that I cannot return ANY unused merchandise for a refund EVER - UNDER ANY CIRCUMSTANCES'.Since November 2011, my Discover credit card has been charged over $600,.00 from these SCAM ARTISTS. b21b52

* Useful (14)
* Funny (0)
* Bullshit (9)
* ►
*

5
Report Spam
Comments (11) Hide comments
Showing 11 of 11 comments

Please fix the following input errors:

* dummy

Comment review as anonymous or Login
Nickname
Location Hide my location Show my location
Secure Code CAPTCHAReload Image

Post Comment
mel mel
Jul 30 from Sydney, New South Wales
I purchased abcd cream and luminique 90 second wrinkle cream online, it was under the free trial.

I understood (as i read the fine print) that i would be charged in full for the products (unless i was not satisfied and i applied for a refund) and then i would be charged again every 3 months and sent a refill of the products. The abcd was about $80 and i opted for some extras (inc abcd) which came to about $139. I was told on facebook that abcd worked best when used with abcd.

After i bought them i went online and saw all the scam websites against the company, i was so worried so i tried to phone the company but could not get through, i called my credit card company that night and put a block on my card (after they had charged me the $139).

I understood that most people were complaining online because they got charged the full fee to their credit card when they thought it was a free trial, this calmed me down a bit as i think this is very naive, nothing is free, i myself had read the fine print and understood i would be charged unless i change my mind.

I do not work for this company, i am 30 years old, i'm a legal secretary living in Australia, i am writing this review to share my experience with this company to hopefully calm anyone down who may have just signed up to the free trial with the company (however i note i may have just been one of the lucky ones).

Anyway i got tied... up with a few things so forgot to follow the company up again, then a week later my abcd arrived and the abcd arrived the day after that (i threw out the packaging but i recall they appeared to come from the same address - but were sent separately), both packages came with the extra toner which was offered to me as a bonus for signing up for both products.

I then went online again and read some more reviews where i read that the product had burnt peoples skin and even after cancelling the trial people had been charged numerous times to their credit card, i also came across the site dedicated to the lawsuit against the company. So i then called abcd again (quite worried at this stage) i got straight through to someone this time, i gave him my order number which was emailed to me previously, he found my account and i told him the items had arrived "but my financial situation had changed" so i wanted to cancel any future products. He did that for me and then said he would refund me $139 within the next 5 days, i said i only wanted to cancel any future orders, i was going to keep the products he sent me, so how come i was getting a refund? he said it was because i'd cancelled it within the 30 day period. I also asked if i had to cancel the abcd trial as i noticed they had a different phone number on their email, and the products did arrive separately. He advised i didn't have to and that he had cancelled both subscriptions for me.

I was still a bit worried about what i had read so i kept a close eye on the credit card statements, within 2 days the refund of the $139 had gone into my account, the only thing i had been charged was a $1.99 trial fee plus $4.20 x 2 which was an overseas processing fee when the amount came out of my account and then when it got refunded back to me. I also never had to sent the products back (unlike other stories i had read online)

I have tested the products on my arm and did not get a rash, i also looked up the ingredients online and they all appear to be safe (that is if what they put in the bottles are what they write on the bottles). I'm not a scientist but what i read said that the abcd mostly contained ingredients found in sunscreens, and the abcd 90 second cream appeared safe but some people may have have an irritation if the product gets in their eye and they are sensitive to one of the ingredients (butylene glycol). The 90 second wrinkle reducer does say on the box that its only a temporary fix and it also came with written instructions.

After the refund got processed i cancelled my card and got a new one issued just to be safe however i'm wondering if i have just stressed out over nothing, my experience is nothing like what i am reading online so I wonder what percentage of complaints about this company are merely about the amount they charge you as people are not reading the fine print properly and are assuming they will only be charged $1.99 for the trial (which i think is their own fault).

However, what percentage of complaints were ones where the client was told they had to return the product to get the refund but were then told the product never arrived back to the company (from reading the reviews it looks like you have to send it back in a new envelope and pay for the postage, not mark "return to sender" as it will never arrive back, but it looks like people were sending the products back "return to sender"). Has the company changed their policies and is this why i didn't have to return anything to get a refund? What percentage of clients were in Australia like me, maybe the service is worse in different countries? or was i simply one of the lucky ones, if this is the case it's unfortunate that other people have lost their money.

All in all i am satisfied with the service i got, the packaging the products came in looks pretty dodgy but i think i will still trial them on my face and see how they work, i am glad i only ended up paying $10 for the products, but am a bit regretful of the stress that was caused from what i had read online and now my reluctancy to actually try the product out on my face. If it works though, who knows i may purchase more from the company.
Show more Reply Kim Kim
Dec 04, 2012
Well, well, well. After repeatedly trying to contact this company by both phone and email, I just got a call from them saying that there was a problem with my order. *** right, there was. When all attempts to phone them were futile and they refused to respond to my emails asking for the order to be cancelled, I cancelled my credit card. And what do you know, today is the 30th day since I placed my order for the 'RISK FREE TRIAL'(and cancelled by email 10 minutes later). No doubt they were about to bill me for more products. When asked why I cancelled, I mentioned their appalling reputation and was told that they could not remain in business if they behaved unethically. A lot of scam companies seem to know how to circumvent the law and continue to trade after being exposed as crooks. Reply
Kim Kim
Dec 04, 2012
I am convinced the indignant denials of any wrongdoing by this company are made by employees/family members of the company. The same names pop up over and over again, many of which I suspect are the same person using different identities.. I have seen them claim that all criticisms of the product or company are made by people who are jealous of their success and out to destroy them. How ludicrous. Reply abcd X-Customer ! Hydroxatone X-Customer !
Aug 23, 2012
So my sister did the Free trial with them off my fiance's card which she thought was just for that price. Anyway, once we were told we're going to be billed the extra money, soon as the shipment came, we shipped it back the very next day. I waited 3-4 days to call and see if they received my product, one guy answers te phone and he says no we didn't receive it but it sounds like you're being 100% true. He then proceeds to tell me that I will not be billed and everything is fine. Now here I am with my fiancé now going haywire because they billed his account and put his account in the negatives. (we only use the card to pay bills online). Anyway, I believe the previous posters because this is just insane. I shipped back the products and they weren't even USED. They tried to tell me to keep the Bellaplex and I would not be billed, I said *** no and shipped that back along with the others. I cannot believe them! I'm so pissed off! They better be lucky they don't have 24 hr customer service in the U.S. because I would definitely be giving them a peace of my mind. :( Reply Susan Susan
Aug 16, 2012
I had a similar experience re: the "risk free trial". I did everything they required and spoke/wrote to their customer service numerous times, but they repeatedly did not follow up and my debit card continued to be charged.
My recent solution: I contacted my bank, disputed abcd additional charges, and discontinued my debit card so they could no longer add charges to it. My bank then issued me a new debit card, necessitating that I contact all my ongoing monthly creditors that utilized the previous card number.
PS Also want to add that the product didn't work -- as a matter of fact I think my wrinkles got worse! :)
PPS I suspect that a number of the positive comments here are from Hydroxatone people -- I had multiple contacts (at least 10) with their customer service via email and phone experience; in all cases, there was no resolve; worse, there was clearly evasive/deceptive behavior that did not reflect the "risk free trial", extended the time and resulted in additional charges. Reply Gapeach Gapeach
Jul 03, 2012
:) I am not sure if these comments are true or someone out there selling other beauty creams and bash abcd. When I first purchased this item, I called and canceled the prescription. Customer service was extremely nice, I mailed back my empty jar & was refunded my money & got to keep the free jar. I now call customer service to place my orders, they have even given me 6 $40 off an order cupons. I love the product. I am a customer, not a sales person. They will probably delete my comment since it is a positive one. Reply that was funny that was funny
Feb 11, 2012
:grin :grin Reply No problems for me No problems for me
Feb 10, 2012
I called their customer service and they pretty much did whatever I wanted. You can buy abcd pretty much anywhere online and even in a few stores. Its definitely not a scam - -what out for ambulance chasers like the one above who just want to use you so they can collect a HUGE fee. Reply abcd abcd
Feb 09, 2012
Hi there.

abcd offers a risk-free trial. We do this to give customers a chance to try our products before buying them. We are sorry your experience was not what you expected and we really hope you give our products another chance. Our risk-free trial comes with a 30 day money back guarantee. This means, if you aren’t satisfied with your results, you can call our customer service and return the products to avoid being charged for the merchandise. It is our goal that our customers have a positive and rewarding experience with both our products and our service.

We’re also sorry that we have been experiencing some difficulties with our international phone lines. This issue has been resolved. If you have any further questions please, please contact us using the information below:

USA/Canada (800) 672-2259 (8 am – 10 pm EST)
Australia (0011) 800-2358-7491 (24 hours)
New Zealand (00) 800-2358-7491 (24 hours)
Great Britain (00) 800-2358-7491 (24 hours)

You can also email us directly at FBHXsupport@abcd to let us know how we can help.

Please note that some mobile phone carriers do not allow toll free 800 numbers to the USA to connect. We suggest using a landline if you are having trouble with your mobile carrier. Reply DERF DERF
Feb 09 from Dallas, Texas
abcd You guys dont seem to be having any trouble your abcd number... you know the one where your *** unwanted robo calls are calling my cell phone 3 to 4 times a day.

Once I answered the number to ask to be removed from the list, it was an some Indian Guy claiming I owed $69 to your company.

Guess what??? I never done business with your company and I have no intention of EVER doing business with you. I really have no idea how you even got my number.

So yes in my opinion you are running a scam! :? Reply Angela Edwards Angela Edwards
Feb 08, 2012 from Halsey, Oregon
Hi I have filed a class action lawsuit against abcd for scamming customers via the "risk free trial" - customers who ordered abcd and returned the product within 30 days, but were still charged for the product and/or placed on "auto-ship" and billed further without the customer's consent. You can reach me direct at (413) 525-3820 or angelaedwards@charter.net for further information. Thank you. Reply

Showing 1-11 of 11 comments

← Previous
14 of 21 abcd Reviews
Next →
To the Top
Submit complaint
More abcd Reviews

* abcd took my money and it was he'll to get them to stop!
* Mrs
* Overcharge
* Former employee
* Misleading ad

All abcd Reviews →

Recently discussed

* Company
* Industry
* Overall

Jul 30
abcd
abcd SCAM!
Jul 29
abcd
overcharge
May 01
abcd
abcd CLASS ACTION LAWSUIT FILED!
Feb 20
abcd
abcd
Nov 29, 2012
abcd
Sent 2 jars of abcd and put unwanted charges on my credit card. I'm returning unused jar.
Aug 05
Larry Hahn
this is a scam
Aug 02
BH Cosmetics
Do not order from BH Cosmetics
Jul 30
abcd
abcd SCAM!
Jul 30
BH Cosmetics
BH Cosmetics - DO NOT BUY!
Jul 29
abcd
overcharge
8 minutes ago
Newsmax
Sean Hyman-Money Matrix Insider Loser!
9 minutes ago
UPS
UPS Workers steal your items.
10 minutes ago
Best Buy
Anti-Virus Scam
25 minutes ago
GNC
GNC-I work there, check this out for the shocking truth
46 minutes ago
USHIP
USHIP SCAM!!!
New Companies

* Jordan Valley Medical Center
* Starwood Hotels and Resorts Worldwide Inc
* Rhino Pest Control Las Vegas
* Sugarbears Pampered Pets
* Jack Cuvos Wrestling Warehouse
* Furniture Barn
* One Pissed SHOPPER
* Urban Tactical Supplies
* Ocean Coral & Turquesa Resort
* Johnny Rockets
* Pioneer Credit Counseling
* Amarpal Singh
* Abortion clinic in port elizabeth
* Abortion clinic in mafikeng
* Hardy Plumbing
* poolstoreoutletcom

All New Companies
Topics of the Moment
Second Chance Banking Peters Equipment Universal Mobile Homes Nude Underage Adult Affair Weatherchannel David Zargari Underage Girls Nude Visalus Scam Eskaton Pops Farm Fitness Contracts Trafficwavenet Bestway Rent To Own Naked Walmart Rushcard Marvin Windows Complaints Springleaf Financial Tiffany Dials Virool Ameren Power Back On Babies R Us Registry Davids Paint And Tile Kloster Contracting Jade Optical Boutique
Our Blog We in Press Research

* Submit complaint
* Companies
* Browse complaints
* Business solutions
* Featured Reviews
* Blog
* FAQ
* Recalls
* Our Research
*  
* We in Press
* Consumer Reviews
* Consumer Tips
* Consumer Resources
* Consumer Advocacy
* Complaint Letters Sample
*  
* Customer Satisfaction Index
* Privacy Policy
* Terms of Use
* Contact Us
* About Us
* Latest News
* Report a bug
*  

Pissed Consumer © All Rights Reserved

Report a bug
close
Read next abcd complaint
abcd CLASS ACTION LAWSUIT FILED!

Hi.I have filed a class action lawsuit against abcd for scamming customers via the "risk free...

close
Select Reason
Sexual Content
Violent or Abusive Content
Spam
Infriges my Rights
Please select the Reason
Send Report Cancel
close
Thank you!
We will review your report
Messageclose
Ok
close
You were reading a complaint about abcd.
Filing a new complaint about
The same company Another company
close
Report a bug

Help us help you!
We are trying to be better!
Your email

We need your email address to contact you if we need more bug information. Please provide a valid email address. We do not add this email address to any kind of mailing list or post it on the web
Summary*

A one-line description of the bug
Description*

What were you trying to accomplish and what is the result?
Error Messages

Any errors or messages you may have received
Cancel

close
Thank you!
We will review your report

Services

Group organizers

Group notifications

This group offers an RSS feed. Or subscribe to these personalized, sitewide feeds: