![]() |
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !! |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| find and replace | javeed7 | Shell Programming and Scripting | 1 | 04-02-2008 09:00 AM |
| find and replace | rakshit | Shell Programming and Scripting | 4 | 01-24-2008 03:52 AM |
| find and replace | mahabunta | UNIX for Dummies Questions & Answers | 7 | 09-21-2006 12:05 PM |
| find and replace | valhutch | UNIX for Dummies Questions & Answers | 4 | 07-29-2006 05:20 PM |
| Find & Replace | gagansharma | Shell Programming and Scripting | 3 | 11-27-2001 04:17 PM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
||||
|
Hi
In our html pages, we have the image path as "/dir1/dir2/image.gif". We are changing the location of the image directory. So now we wish to do a global search and replace the path. I think we are having trouble with forward slash character. Please help Thanks in advance Vikas a newbie |
|
||||
|
If you're going to use vi for this then instead of using a / character for separations...use another character such as =
For example...instead of :%s/\/dir1\/dir2\/image.gif/<new file> use: :%s=/dir1/dir2/image.gif=<new file> or :1,$ s=/dir1/dir2/image.gif=<new file>=g Using the = for the separator will avoid having to specify the backslash to tell the substitution that the / is part of the substitution. ![]() |
| Sponsored Links | ||
|
|
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|