Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8996247
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T23:43:44+00:00 2026-06-15T23:43:44+00:00

In my component methods, how can I get the request data that is normally

  • 0

In my component methods, how can I get the request data that is normally read by the controller?

class MyComponent extends Component {

    public function processData() {

        // Get the data normally found in $this->request->data

    }

}
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T23:43:45+00:00Added an answer on June 15, 2026 at 11:43 pm

    Here are 2 ways to do this, second way is simpler:

    Add this in your component

    public function initialize(Controller $controller) {
        $this->controller = $controller;
    }
    

    You can then access the request data in the component by doing:

    $this->controller->request->data
    

    Or alternatively, you could just pass it through to your function.
    E.g.

    public function processData($data) {
    
    }
    

    And then call it with

    $this->MyComponent->processData($this->request->data);
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have: @Component class MyDecorator{ private Cache cache; /* some wrapped methods like get
I've a class as shown below: @Path(/myrequest) @Scope(request) @Component public class MyRESTCode implements IServicedResource<T>
I need a component/class that throttles execution of some method to maximum M calls
I have the following code in a view: def controller_details(request, object_id): controller = Controller.objects.get(pk=object_id)
I have a Silverlight Windows Phone 7 app that pulls data from a public
I am trying to extend the flex datagrid component so that I can have
Can I rerender a jsf ui component when a valuechangelistener method is run? The
We have noticed that component publishing takes a long time. The component we are
Consider the following code. public interface IFoo { } public class Bar { public
I had read this: Flex: HTTP request error #2032 And this: http://www.judahfrangipane.com/blog/2007/02/15/error-2032-stream-error/ Trying to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.