Jump to content

Parsing a string from a file


dryaquaman

Recommended Posts

Here's what I need to do:

I have a page that reads file and simply echos it.

$mystring = file_get_contents($file);  echo "$mystring";

 

There is one piece of info I need to parse out and then use as part of my page title.

The phrase I need to parse is an HTML comment field and looks like this: <!--PageTitle=<some text here> -->

 

I'm sure this is simple but I'm clueless as you can tell.

How can I do this?

 

DryAquaman

 

Link to comment
https://forums.phpfreaks.com/topic/212128-parsing-a-string-from-a-file/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.