preg_match logical error


Posted on 16th Feb 2014 07:03 pm by admin

Code: <?php
$s = file_get_contents("page.html");
preg_match('/<div class="brown_box main_ge_page vertically_spaced"><div class="subsectionHeader">(.*)</div>/', $s, $m);
echo $m[1];
?>
page.html content
Code: <div class="brown_box main_ge_page vertically_spaced">
<div class="subsectionHeader">
Works
</div>
How come it doesnt get the word, "Works"

No comments posted yet

Your Answer:

Login to answer
129 Like 32 Dislike
Previous forums Next forums
Other forums

SMTP server...
I recently found a tutorial online on SMTP authentification for sending emails from webpages, here i

Parse error: syntax error, unexpected T_ELSEIF in /home/......html/item.php on l
I do not know what is wrong with this. Hope some one can help. I do nto want to post the entire site

Need help/w Page: 1,2,3,4 function!
So I have this code im working on where it's ment to display seperate pages having 20 logs each
I

natcasesort works on one server but not on another
Hi

I have a problem that I was hoping that someone can help me with.

I'm trying to use

PHP - HTTP Digest Authentication - Understanding Code Help
Hi Everyone,

This is my first time on your website and please excuse if I am asking silly que

Amend code to allow multiple attachments
Hi

I have a php page that allows the user to browse to a file (image) then sumbit, the confi

Problem related to Creation of PDF File?
Hi All,
I am facing a problem related to creation pdf file. when I am creating a pdf file of do

php libs/ browsercap.in
ok i have a host that refuses to stay current. they control my php settings and libs. is there a way

Doubles are giving me problems
Ok so, first of all i made a double = 0.05, but when running the debugger it shows up as 0.04999. I

Please Help my PHP Dating Function.
Hi everyone!

Well here is my code that displays this:

It works wonderful.


Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash