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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T22:38:16+00:00 2026-06-01T22:38:16+00:00

I have a specific array that php needs to access and write to a

  • 0

I have a specific array that php needs to access and write to a file. I also want to be able to call the php to get the array info back. I use JSON.strigify to store the array in a string, but i cant figure out how to send it to a server with php. I have very little php experience and i tried:

<script language="javascript">



var COMMENTS_FOR_DISPLAY = new Array('Have fun with this code: Chris');

// Adds a new comment, name pair to the Array feeding textualizer.
function add_comment() {
  // Retrieve values and add them to Array.
  var new_comment = $('#kwote').val();
  var new_name = $('#name').val();


   COMMENTS_FOR_DISPLAY.push(new_comment + ': ' + new_name);


  // Reset <input> fields.
  $('#kwote').val('');
  $('#name').val('');

  var arrayAsString = JSON.stringify(COMMENTS_FOR_DISPLAY);

}


$(document).ready(function() {
  var txt = $('#txtlzr');  // The container in which to render the list

  var options = {
    duration: 5,          // Time (ms) each blurb will remain on screen
    rearrangeDuration: 5, // Time a character takes to reach its position
    effect: 'random',     // Animation effect the characters use to appear
    centered: true        // Centers the text relative to its container
  }

  txt.textualizer(COMMENTS_FOR_DISPLAY); // textualize it!
  txt.textualizer('start'); // start
});
</script>

in main.php i put:

<?php
$kwoteString = $_GET["arrayAsString"];
echo $kwoteString;
?>

I used echo to see if i was getting any output,but i wasn’t. It could be a very simple fix, maybe im missing a header or something telling my html document to read main.php?? any help would be appreciated!

  • 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-01T22:38:17+00:00Added an answer on June 1, 2026 at 10:38 pm

    you can add a hiddenField and set the string to the hidden field.
    php code will read the value from hidden field.

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

Sidebar

Related Questions

i have this code that will check the array contains the specific string and
As I know, an array needs to have a specific size before compiling time
I have an array containing specific times and I want when the current time
I have a specific changeset that I want to rollback my Development branch to,
I have written a php script that returns an arbitrary number of specific ids
I have this API that requires me to have a specific array key to
I have a couple large arrays that need to be available to a specific
I have an array of ints like this: [32,128,1024,2048,4096] Given a specific value, I
I have a multidimensional array. I need to search it for a specific range
I have a specific requirement that all children of a particular JComponent have double

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.