douou9094747 2014-07-18 07:09
浏览 110

将PHP与SAP数据库连接

So, I already followed all the steps below for saprfc windows installation.

1) Extract zip file saprfc-$VERSION$-$PHP_VERSION$.zip
2) Copy php-saprfc.dll to your extensions directory (e.g. C:\PHP\extensions)
3) Edit php.ini file (in windows system dircetory, e.g. C:\WINNT, C:\WINDOWS)
         and add line: 'extension=php_saprfc.dll'
4) Copy librfc32.dll (from SAPGUI install CD) to the windows system
         directory or simple install SAPGUI on your machine.

Another source said we will we need SAP SDK. Is it really needed for Windows? Also, will it be possible to code PHP connect to SAP in a computer that doesn't have SAP program? Or we only can do those installations in computer that has SAP application?

Then after the installation, what do I have to do next? I am trying to do steps below, yet still confused....

  1) Extract php sources to C:\PHP-x.y.z
  2) Extract php win support files to C:\PHP-x.y.z\win32
  3) Install RFCSDK to C:\PHP-x.y.zfcsdk
  4) Copy SAPRFC sources to C:\PHP-x.y.z\ext\saprfc
  5) Copy php4ts.lib or php5ts.lib (from PHP binaries) to C:\PHP-x.y.z\win32
  6) For PHP5 copy saprfc.dsp5 to saprfc.dsp
  6) Open project C:\PHP-x.y.z\ext\saprfc\saprfc.dsp in Microsoft Visual C++ 6.0
  7) Under Tools|Option|Directory set path for Include files and for Library files
     (C:\PHP-x.y.z\win32\include; C:\PHP-x.y.zfcsdk\include;
      C:\PHP-x.y.z\win32\lib; C:\PHP-x.y.zfcsdk\lib)
  8) Set active configuration to "saprfc - Windows_TS" (under Build menu)
  9) Build php_saprfc.dll.
  10) Compiled DLL you find in C:\PHP-x.y.z\Release_TS directory

Where to get PHP sources, PHP win support, and how to compile the program?

Sorry, I am totally new to this. Looking for the answers. Thank you very much!

  • 写回答

1条回答 默认 最新

  • 普通网友 2015-02-05 09:49
    关注

    Building "windows extensions" is explained in general here: https://wiki.php.net/internals/windows/stepbystepbuild

    There is also explained which version of VS you need for which PHP version.

    I also tried to build the sapnwrfc extension for PHP 5.5 on windows, but failed at some part...my progress/documentation is here: https://github.com/piersharding/php-sapnwrfc/issues/6

    Maybe you can progress further :-)

    评论

报告相同问题?

悬赏问题

  • ¥15 python的qt5界面
  • ¥15 无线电能传输系统MATLAB仿真问题
  • ¥50 如何用脚本实现输入法的热键设置
  • ¥20 我想使用一些网络协议或者部分协议也行,主要想实现类似于traceroute的一定步长内的路由拓扑功能
  • ¥30 深度学习,前后端连接
  • ¥15 孟德尔随机化结果不一致
  • ¥15 apm2.8飞控罗盘bad health,加速度计校准失败
  • ¥15 求解O-S方程的特征值问题给出边界层布拉休斯平行流的中性曲线
  • ¥15 谁有desed数据集呀
  • ¥20 手写数字识别运行c仿真时,程序报错错误代码sim211-100