Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

Coding Forum


You are currently viewing our Coding Forum as a guest. Please register to participate.
Login



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

Posts: 880
Location: Leeds UK
Trades: 0
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
__________________

Please login or register to view this content. Registration is FREE

Please login or register to view this content. Registration is FREE

Please login or register to view this content. Registration is FREE

Please login or register to view this content. Registration is FREE

Linux user #349545 :
(GNU/Linux)iD8DBQBAzWjX+MZAIjBWXGURAmflAKCntuBbuKCWenpm XoA7LNydllVQOwCf
ibbo is offline
Reply With Quote
View Public Profile Visit ibbo's homepage!
 
 
Register now for full access!
Reply     « Reply to 404
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

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

BB 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.08034 seconds with 12 queries