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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T12:43:33+00:00 2026-06-12T12:43:33+00:00

From the topic itself, how am i supposed to do that?… I’m getting the

  • 0

From the topic itself, how am i supposed to do that?… I’m getting the output from linux to Php using pipes.

e.g

echo "<textarea cols='100' rows='20' readonly='readonly' style='resize:none;'>";

       $dev = stream_get_contents($pipes[1]);

       echo $dev;

       echo "</textarea>";

       fclose($pipes[1]);

Here is my form.

<form method="post">
<input type="radio" name="cmd" value="./iodev scan">Scan<br />
<input type="radio" name="cmd" value="./monitor">Enable Monitoring<br />
<input type="submit" value="GO">
</form>

Now when i got the data i need it to retain in the textarea when loaded into a new tab or page or on page reload it will sit there and not disappear.

Thanks,

  • 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-12T12:43:34+00:00Added an answer on June 12, 2026 at 12:43 pm

    You can try something like amusing your textarea name is textPipes

    if (!isset($_POST['textPipes']) || empty($_POST['textPipes'])) {
        $_POST['textPipes'] = stream_get_contents($pipes[1]);
        fclose($pipes[1]);
    }
    
    echo "<textarea cols='100' rows='20' readonly='readonly' style='resize:none;' name='textPipes' >";
    echo $_POST['textPipes'];
    echo "</textarea>";
    

    * EDIT ! *

    Based on your request you can also sore it in Memcache

    $mem = new Memcache();
    $mem->connect("localhost",11211);
    
    #Identify current user
    $currentUser = "demic0de";
    
    #Create Unique Key
    $key = $currentUser . sha1($pipes[1]);
    
    if(!$mem->get($key))
    {
        #set value and expire every 10 mins 
        $mem->set($key,stream_get_contents($pipes[1]) ,null,600);
        fclose($pipes[1]);
    }
    
    
    echo "<textarea cols='100' rows='20' readonly='readonly' style='resize:none;' name='textPipes' >";
    echo $mem->get($key);
    echo "</textarea>";
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

topic.php $id = isset($_GET['id']) ? intval($_GET['id']) : 0; $query = mysql_query(SELECT * FROM topics
From the topic itself, I need to compare a string to a line of
I found out how to retreive the html page of a topic from google
In our application, we receive messages from JMS Topic. First I want to know
From the Mojolicious wiki on the topic of Database support: Although SQL::Abstract looks like
as the topic says, my upper div starts from the margin of the lower
I have downloaded some files from the internet related to a particular topic. Now
Sorry for opening this topic again, but thinking about this topic itself has started
Im building a customized comments app for django, using django comments itself. Ive followed
I have encountered MySQL itself recently and the topic of Composite Primary Keys in

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.