Search and Replace of CSS code in several files

Hello JetBrains!

I'm going through your excellent Fabrique tutorial (Fabrique build 649) and then point "2. Step 1. Homework" says:
--- snip ---
4.
Open the XHTML view of each application page and insert the link to the imported .css file into the section of the page, like this: --- snap --- So, no problem? I have to search all web pages (ListAll, Index, AddModifyBook) in my project an find the string "]]>" and replace that with the three lines from the tutorial. However I did not found the right tool in IDEA/Fabrique to search a simple string and replace this string with three lines of CSS code. But it's the mighty IDEA with lot's of refactoring support and so on! Is there a solution for my simple task with IDEA/Fabrique?

Thanks for help,
karlo1

4 comments

Hello IDEA Community Forum!

So much answers, i barely can try all the hints and tips!
Really no way in Fabrique/IDEA to search and replace one line of CSS code with three lines of CSS code??

Greetings,
karlo1

0

OK,

First of all, you are NOT replacing css code, you are replacing html tags.

Second, It is a trivial search and replace.

In IDEA:

- Highlight the tag in one of the files - go to the menu item "Search->]]>Replace in Path", or type
- Specify:
]]>
as the "replace with" text
- choose your desired scope, most likely a single directory
- click "Find"
- click "All Files".

Done.

0

I think he is talking about Fabrique. This is an IDEA newsgroup.
Please post to the appropriate group.

Tim Haley wrote:

OK,

>

First of all, you are NOT replacing css code, you are replacing html
tags.

>

Second, It is a trivial search and replace.

>

In IDEA:

>

- Highlight the <head /> tag in one of the files
- go to the menu item "Search->Replace in Path", or type
- Specify:
<head> <link rel="stylesheet" type="text/css" href="/laf.css"/>
</head>
as the "replace with" text
- choose your desired scope, most likely a single directory
- click "Find"
- click "All Files".

>

Done.

0

Norris Shelton wrote:

I think he is talking about Fabrique. This is an IDEA newsgroup.
Please post to the appropriate group.


True, but AFAIK Fabrique is now an IDEA plugin. So IDEA search/replace should be valid,
although there may be an alternate way provided by Fabrique.

Tim

0

Please sign in to leave a comment.