Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Matthew.txt 1:1 The book of the generation of Jesus Christ, the son of David, the son of Abraham. 1:2 Abraham begat Isaac; and Isaac begat
Matthew.txt
1:1 The book of the generation of Jesus Christ, the son of David, the son of Abraham.
1:2 Abraham begat Isaac; and Isaac begat Jacob; and Jacob begat Judas and his brethren; 1:3 And
Judas begat Phares and Zara of Thamar; and Phares begat Esrom; and Esrom begat Aram; 1:4 And
1. Create "mysearch.php" and read "Matthew.txt" into a string, such as $strMatthew. 2. Figure out the basic regular expression for "nn:nn" (i.e., chapter:vese pattern.) 3. 3. Explore "preg match" and "print_r functions: Find out the position of the first and the next pattern of "nn:nn" so that you can use the substring function to extract each verse. .Print the substring, which is a verse and ontinue the whole process until the whole long string is exhausted. After the above is done, try to put all verses into an array of strings, like Smatthew. (Each entry of this array is a verse.) Then move all code that need to read the file into an array of string to a form of function called "readMyFile" in a separate file named "readmyfile.php" (i.e., this PHP file consists of only one function called "readMyFile".) 4. ? ? O ? 1? localhostesc264/a0-1/mysearch.php Book of Matthew Length of book 132914 Bytes Total Verses- 1071 1:1 The book of the generation of Jesus Christ, the son of David, the son of Abraham. 1:2 Abraharm begat Isaac, and Isaac begat Jacob; and Jacob begat Judas and his brethren; 13 And Judas begat Phaes and Zara af Tharn, and Phares begat Eso and Estom begat AramStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started