note 126011 deleted from ref.exec by mazzanet
| From: | mazzanet@php.net | Date: | Sun, 18 Apr 2021 06:36:15 +0000 |
| Subject: | note 126011 deleted from ref.exec by mazzanet | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-216300@lists.php.net to get a copy of this message | ||
Note Submitter: ybhask at gmail dot com
----
Using Linux Ubuntu 16.04 apache2 php 7 on Lenovo laptop 32 bit.
Exec command worked only after I closed terminal.
I have tried the following command:
$output = exec( "php script.php | awk -F= '{printf \"%d %s\n\", length($1),
$0}' glossary2.snpz | sort -rn -k1,1 | sed -E -e 's/^[0-9]+ // ' " ) ;
echo $output;
I hope it will be useful to others.
Context: I have used the output as a string for my php script to design a Translation Script from
English to Telugu.