|
|
Read file twice and modify content
Hello,
I want to modify content of multiple files.
Example file looks like this:
include("top.php");
..
..
..
include("menu[diffrent text in diffrent files]");
What I want to achive:
$menu = menu[diffrent text in diffrent files];
include("top.php);
..
..
..
#include("menu[diffrent text in diffrent files]");
Submitted via EggHeadCafe
SharePoint 2010 Using External List
http://www.eggheadcafe.com/tutorials/aspnet/71ee360f-d781-48d6-8243-769d96b45064/sharepoint-2010-using-external-list.aspx
|
|
0
|
|
|
|
Reply
|
zoozik (1)
|
3/16/2011 9:45:26 AM |
|
Wed, 16 Mar 2011 09:45:26 +0000, Marek Podlesny did cat :
> Hello,
> I want to modify content of multiple files. Example file looks like
> this:
> include("top.php");
> .
> .
> .
> include("menu[diffrent text in diffrent files]");
>
> What I want to achive:
> $menu = menu[diffrent text in diffrent files]; include("top.php);
> .
> .
> .
> #include("menu[diffrent text in diffrent files]");
>
> Submitted via EggHeadCafe
> SharePoint 2010 Using External List
> http://www.eggheadcafe.com/tutorials/aspnet/71ee360f-d781-48d6-8243-769d96b45064/sharepoint-2010-using-external-list.aspx
not really sure of what you really want, this looks a lot like what you described
but maybe not what you meant :
----------
awk '
FNR==NR{f[n=NR]=$0; next}
NR==(1+n){sub(/^.[^\(]*\(./,"$menu = ",f[n]);sub(/\"/,"",f[n]);print f[n]}
FNR==n{sub(/^/,"#")}
1' file file
----------
|
|
0
|
|
|
|
Reply
|
Loki
|
3/16/2011 5:40:03 PM
|
|
|
1 Replies
649 Views
(page loaded in 0.244 seconds)
Similiar Articles: Read file twice and modify content - comp.lang.awkHello, I want to modify content of multiple files. Example file looks like this: include("top.php"); .. .. .. include("menu[diffrent text in di... How to read a text (txt) file, modify and save - comp.soft-sys ...Read file twice and modify content - comp.lang.awk open file, change content, save file ... of java code to read data from a txt file. with the contents as ... double y ... using awk to modify xml file - comp.lang.awkRead file twice and modify content - comp.lang.awk... to modify content of multiple files. ... Split file using awk - The UNIX and Linux Forums I am trying to read a ... Reading and modifying XML file using MATLAB - comp.soft-sys.matlab ...How to read a text (txt) file, modify and save - comp.soft-sys ... I think Matlab can help me but I never did something with reading/modifying file before, I really need ... Read a .zip file from MS Access? - comp.compressionRead file twice and modify content - comp.lang.awk Read a .zip file from MS Access? - comp.compression From within Access, is it ... open file, change content, save file ... To compare the content in two files.. - comp.lang.perl.misc ...Read file twice and modify content - comp.lang.awk JDBC compare the content of two tables - comp.lang.java.help ... Read file twice and modify content - comp.lang.awk ... awk script to split text file content to multiple files - comp ...Read file twice and modify content - comp.lang.awk awk script to split text file content to multiple files - comp ... Read file twice and modify content - comp.lang.awk ... delete columns csv file - comp.lang.awkmakeing changes to a file with awk - comp.lang.awk Read file twice and modify content - comp.lang.awk delete columns csv file - comp.lang.awk Readers, I ... change 'file ... Compare contents of Zip files for changes. - comp.unix.solaris ...Read file twice and modify content - comp.lang.awk Compare contents of Zip files for changes. - comp.unix.solaris ... Read file twice and modify content - comp.lang.awk ... Read LabView binary file timestamp into Matlab - comp.soft-sys ...In case it is useful to someone: If you need to read a LabView binary data file into Matlab, it ... reshape(b',[],1), 'double') ; % Now we can can convert to double time ... Read file twice and modify content - comp.lang.awk | Computer GroupHello, I want to modify content of multiple files. Example file looks like this: include("top.php"); .. .. .. include("menu[diffrent text in di... How to Read the Contents of a Text File Using VBScript | eHow.comHow to Read the Contents of a Text File Using VBScript. ... right-click on the file and choose Edit ... You double-click the VBScript file, and... How to Read Text Files with ... 7/23/2012 10:10:42 AM
|
|
|
|
|
|
|
|
|