Jump to content

Simple search


kippi

Recommended Posts

Hey,

 

I am sure this is really simple to do, but not sure where to look:

 

#

What's the best way to read after the line filename and finish at ----- so the output would be Z3dvb5RAZGlynJUFDNvLnVrCg==

#

 

#

filename="sales"

#

 

#

Z3dvb5RAZGlynJUFDNvLnVrCg==

#

 

#

------=_20080407170816_24869--

#

 

#

Any help would be great!! This is so I can run base64_decode and get the attachments.

 

Many Thanks

 

Chris

Link to comment
https://forums.phpfreaks.com/topic/100024-simple-search/
Share on other sites

if it is always on the same line you can use file() and then just echo out the line number. file() will put each line into an array, then you can call the line you want. lines start with 0 so if you want line 7 it is actually 6

 

so example

 

$data = file("data.txt");

 

$encode = $data[6];

 

Ray

 

 

Link to comment
https://forums.phpfreaks.com/topic/100024-simple-search/#findComment-511504
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.