开发者

PHP string comparison VIEW DIFF PEAR

开发者 https://www.devze.com 2023-04-03 09:50 出处:网络
I am trying to compare two strings, and I want to know if something from string 1 is deleted or replaced in string 开发者_开发技巧2.

I am trying to compare two strings, and I want to know if something from string 1 is deleted or replaced in string 开发者_开发技巧2.

I tried using the following: http://pear.php.net/manual/en/package.text.text-diff.intro.php http://www.raymondhill.net/finediff/viewdiff-ex.php

But I can't get it to work.


Is http://pear.php.net/manual/en/package.text.text-diff.usage-examples.shell.php not enough?

If you installed the Text_Diff package, you will also have an example installed automatically:

$ pear list-files text_diff|grep doc
doc  /usr/share/php/docs/Text_Diff/docs/examples/1.txt
doc  /usr/share/php/docs/Text_Diff/docs/examples/2.txt
doc  /usr/share/php/docs/Text_Diff/docs/examples/diff.php
0

精彩评论

暂无评论...
验证码 换一张
取 消