0

I need to unarchive *.rar file and extracte with password on PHP. I found many decisions on PHP, but all they don't provide password in archive. Should it do so through the exec ()?

My OS: Windows 8

serezha93
  • 125
  • 1
  • 1
  • 10
  • @JohnConde : I disagree that it is a duplicate. First of all the related answer deals with a ZIP archive and second there are ways to extract RAR archive without using `system()` function, which may be disabled on some secure systems. – i-- Apr 22 '14 at 13:15

1 Answers1

0

Have you tried using rar_open()? It has an argument for password. I personally never used it, so can not vouch if it works well.

For Windows you need to have php_rar.dll enabled in php.ini.

i--
  • 4,349
  • 2
  • 27
  • 35