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 6343721
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T20:30:00+00:00 2026-05-24T20:30:00+00:00

I am using zend_form to create the form that is rendered. Although there are

  • 0

I am using zend_form to create the form that is rendered. Although there are validation rules specified in the form, it is not impossible to inject new elements into the response. Thus more filtering of $this->_request->getParams() is required.

Is there a way to delete all unvalidated input before reaching the action? I am aware that I can unset() any alien manually before processing the response, but I am looking for a more elegant solution.

EDIT:

I am looking to grab the request parameters and put them into the database using Zend_Db_Table_Abstract::insert($this->_request->getParams()). This would have worked fine since the form is validated and only validated form elements where present in the request. Since that’s not the case, by default, I’d have filter out the elements prior to doing the insert.

  • 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-05-24T20:30:01+00:00Added an answer on May 24, 2026 at 8:30 pm

    Wouldn’t it be easier just to pick up the fields you need in the action (after validating them with Zend_Form), and discard the rest of the parameters?

    Unless you have many parameters in the request, this looks like the most secure way to me… You’ll only get the parameters you are actually expecting, and nothing else.

    EDIT:

    In case you need to get only the valid values using Zend_Form, would the getValidValues() method help? See http://framework.zend.com/manual/en/zend.form.quickstart.html#zend.form.quickstart.validate. You can then unset() all the parameters not in this list from the request. I don’t know if there is a way of doing it more elegant than this.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Using Zend_Form, how would I create form elements like this: <input type=text name=element[1] value=
I am having problems getting validation to work for a form built using Zend_Form.
Using Zend_Form, how would I create form elements like this <input type=text name=element[1] value=/>
I am using zend_form (part of Zend Framwork) to create a form and found
Server side extjs form validation using zend framework I have extended Zend_Form class to
I am using Zend Framework I have a form that allows me to create
I'm trying to create a form using Zend_Form (Zend_Framework component). The users should be
Using Zend_Form, how would I create form elements like this: <input type=text name=element[0][name] value=
About to create a form using Zend Form, all the form elements should have
When using a Zend_Form , the only way to validate that an input is

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.