Reply
Old 12-15-2005, 10:47 AM 404
ibbo's Avatar
Super Spam Talker

Posts: 880
Location: Leeds UK
You all come across these from time to time and whats the odds its because of a typo and not a missing page.

But whats worse is it could be in more than one file which means you have to drag your way through them all and find the offending link and then fix it.

So a solution was begging to be found/ created and here is one

Code:
perl -p -i -e 's/<bad_link>/<good_link>/g'  `grep -rI <bad_link> * | awk -F : '{print $1 }' | sort | uniq | xargs`
So ok it needs NIX to work its magic but hey its not my fault if you dont use it.

Hope its usefull for any of you's that need it.

Ibbo
__________________
www.nationalclubgolfer.com www.sportspub.co.uk www.bespokecc.co.uk www.centralmarquees.co.uk
Linux user #349545 :
(GNU/Linux)iD8DBQBAzWjX+MZAIjBWXGURAmflAKCntuBbuKCWenpm XoA7LNydllVQOwCf
ibbo is offline
Reply With Quote
View Public Profile Visit ibbo's homepage!
 
When You Register, These Ads Go Away!
Reply     « Reply to 404
 

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off




   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML

 


Page generated in 0.10728 seconds with 12 queries