Web Analytics Made Easy -
StatCounter Problem with system function and zip file - CodingForum

Announcement

Collapse
No announcement yet.

Problem with system function and zip file

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Problem with system function and zip file

    Hi i am using Solaris 9 with php and apache. i have a code in which i am using System function to run an Executable, It works fine on my system with current configuration. It is placed in my /var/apache/htdocs directory. Now problem is that when i zip this folder using this command

    cd /var/apache

    zip -r htdocs.zip htdocs/

    It makes a zip file, and if i move old htdocs folder to somewhere else and unzip htdocs.zip to /var/apache, now it runs my application in browser but now my system function is not working. My executable is running fine using command line. Now if i replace this htdocs folder with my old one, it runs my executable using system function.

    Is thee any thing which i am getting wrong.

    I want this zip file for making an installation package, Also it does not make work on other systems. I have the same installation on other system with same .dtprofile, php.ini and httpd.conf configuration files. Is there any thing i am missing.

    Please urgent help is required.

    Thanks

    -Waqas Habib

  • #2
    have you considered using PHP's built-in ZIP functions rather than calling the ZIP exe?

    Comment


    • #3
      Are you extracting the files as a different user than the one that created them? Zip is going to extract the new files as being owned by the current user.

      Check with 'ls -lR htdocs' for both copies.

      Comment

      Working...
      X