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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T14:53:26+00:00 2026-05-16T14:53:26+00:00

Form: $headerValues=array(); $headerValues[1][2]=Test; … …. echo <input type=\hidden\ name=\ArrayData\ value=\$headerValues\/>; echo <input type=\submit\ name=\submit\

  • 0

Form:
$headerValues=array();

$headerValues[1][2]="Test";
... 
....
echo "<input type=\"hidden\" name=\"ArrayData\" value=\"$headerValues\"/>";
echo "<input type=\"submit\" name=\"submit\" value=\"Submit\" />"; 

How do I read headerValues on FORM POST , I see as ARRAY when I use this code

foreach (array_keys($_POST) as $key) { 
   $$key = $_POST[$key]; 
   print "$key is ${$key}<br />";
   print_r(${$key}); 
} 
  • 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-16T14:53:27+00:00Added an answer on May 16, 2026 at 2:53 pm

    You can use:

    $headerValues=htmlspecialchars(serialize(array('blah','test')));
    echo "<input type=\"hidden\" name=\"ArrayData\" value=\"$headerValues\"/>";
    echo "<input type=\"submit\" name=\"submit\" value=\"Submit\" />"; 
    

    to get

    $value = unserialize($_POST['ArrayData']);
    

    Reference:
    http://php.net/manual/en/function.serialize.php

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

Sidebar

Related Questions

My form <form action=saveProfile.php method=post name=ProfileUpdate id=ProfileUpdate > <input name=Smeknamn id=Smeknamn type=text value=<?php echo
form: <form id=defineForm method=POST action=api/test> <fieldset> <legend>Generale</legend> <input type=text name=id size=60 maxlength=60/> <input type=text
I have a form like this: <form name=mine> <input type=text name=one> <input type=text name=two>
Form by example. $fullname = 'John Travolta'; <input type=text name=fullname /> <input name=same type=checkbox
In handling a form post I have something like public ActionResult Insert() { Order
my form is passing the String name of the country to the action. how
Form validation plugin: http://bassistance.de/jquery-plugins/jquery-plugin-validation/ Test url: http://docs.jquery.com/Plugins/Validation How to reproduce: 1.) Click on the
HTML: form input:radio 1 input:radio 2 input:radio 3 If one of these is clicked,
On form 1, I have a formtastic date_select field. = f.input :date_from, :discard_day =>
if (form.a.value !=&&form.b.value!= &&form.c.value !=) is there a shorter way for this condition?

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.