Translate Perl Code To PHP Code.
Can some one transfer this Perl into PHP? It is from the Spreadsheet-WriteExcel. PHP Code:
View Complete Forum Thread with Replies
Sponsored Links:
Related Messages:
PHP 4.4.4 Vs Perl 5.8.7 For Object Oriented Server Code
Have you run into a situation where you had to switch from PHP 4.x.x to Perl 5.x.x in order to get better performance? I am using an OO approach to PHP for my website's server code. There is one tiny script, with dozens of small objects. Each object is in a separate source file. It is a bit slow, even when the code doesn't do much DiskIO or MySQL. My webhost (NetSol) uses PHP 4.4 running on Apache 1.3 and Linux. I have to option to use Perl 5.8.7. That is the only alternative they give me at this time. Without doing the rewite, I am trying to determine if I can expect any real improvement in performance. Have you seen or do you know of such a scenario where you get better performance from Perl than from PHP?
View Replies !
View Related
System() Call Perl Script Return Code 13 ?
I run into major problem here and I still cant get it resolved ? I tried to execute a perl script using the PHP system call $haha = system('perl /home/testing/cron_scripts/generate.pl', $retval); echo "Haha is $haha<br>"; echo "Ret Val is $retval<br>"; The problem is I keep getting $retval = 13 ? But if I were to run them from Command line it works. However the script will take sometime. I am not sure if 13 means the code is running or something ? But the problem is my PHP script just exit !
View Replies !
View Related
Old Code Vs New Code - Language Syntax Change?
I've recently begun programming PHP again and have found my old code doesn't work anymore. It's been a few years since my code was written, and simple functions don't seem to be working. I've done a bit of research into the syntax again and found the following; I used to use a function as such; if ($REQUEST_METHOD=="POST") { Now I've seen alot of the syntax is if ($_SERVER($REQUEST_METHOD=="POST")) { And referencing variables from the form is as such; $_POST['variable'] Where previously I could reference them in the simple form; $variable Has there been a language syntax change that would cause my old code to be obsolete? Is there a configuration line that could be changed to allow this old code to work?
View Replies !
View Related
Regular Expression :: Format Anything Within <code> And </code>
Any regular expression wizards out their tonight? This is driving me crazy...trying to take a string full of HTML and format anything within the <code></code> tags using highlight_string(). $string = "<strong>This</strong> is some HTML!!!<code>echo "Hello, World!";</code>No more code!!!"; $pattern = "(<code>)*(</code>)"; $replacement = " |