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

  • SEARCH
  • Home
  • 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 896793
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 15, 20262026-05-15T14:47:10+00:00 2026-05-15T14:47:10+00:00

I got an Array like this: array(‘Testing’=>array( ‘topic’=>$data[‘Testing’][‘topic’], ‘content’=>$data[‘Testing’]’content’]) ); Now I have got

  • 0

I got an Array like this:

array('Testing'=>array(
'topic'=>$data['Testing']['topic'], 
'content'=>$data['Testing']'content'])
             ); 

Now I have got some new data to add into the Array shown aboved,
how can I do it so that the new Array will look like this:

array('Testing'=>array(
'topic'=>$data['Testing']['topic'], 
'content'=>$data['Testing']['content']),
'new'=>$data['Testing']['new'])
                 ); 

Could you help me please?

  • 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-15T14:47:11+00:00Added an answer on May 15, 2026 at 2:47 pm

    In the same way that you can access arrays values by key, you can set by key, as well.

    <?php
    $array = array('foo' => array('bar' => 'baz'));
    $array['foo']['spam'] = 'eggs';
    var_export($array);
    

    Output:

    array (
      'foo' => 
      array (
        'bar' => 'baz',
        'spam' => 'eggs',
      ),
    )
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I got an array which contains some data like this: $arrs = Array(ABC_efg, @@zzAG,
I've got an array of objects defined like this: var editionsObj = new Array();
I got an array that outputs data into an xml. It looks like this:
At the moment I have an array constructed like this: Car[] garage = new
I've got an array of strings that looks like this: [noindex,nofollow] or [index, follow,
I've got an unsorted array of keys like this: keys = [ccc, ddd, ggg,
I've got an array like this array 2 => string 'Member forum 1' 5
I've got a 2-dimensional array like this (it represents a timetable): alt text http://www.shrani.si/f/28/L6/37YvFye/timetable.png
ive got an array like this: $display_related_tags[0][20] = 'text1'; $display_related_tags[1][21] = 'text2'; $display_related_tags[2][22] =
I've got an multidimensional array like this: Array ( [thursday] => Array ( [0]

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.