View Single Post
Old 05-24-2010, 04:05 AM   #1977
DoctorOhh
US Navy, Retired
DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.
 
DoctorOhh's Avatar
 
Posts: 7,421
Karma: 11289119
Join Date: Feb 2009
Location: North Carolina
Device: Nexus 7, Sony PRS-950, Sony PRS-505, PRS-300
Quote:
Originally Posted by TouchToneTommy View Post
Code:
http://www.sanluisobispo.com/2010/05/22/1150793/mixed-martial-arts-comes-to-poly.html
and

Code:
http://www.sanluisobispo.com/2010/05/22/v-print/1150793/mixed-martial-arts-comes-to-poly.html
You can see the "/v-print/ is inserted between the date and the article name.
Is there the option of using wildcards when subbing out for the print version?

Something like this

Code:
    def print_version(self, url):
        return url.replace('http://www.sanluisobispo.com/*/*/*/', 'http://www.sanluisobispo.com/*/*/*/v-print/')
That's my guess.

Good Luck
__________________
-- Good Reading, Walt --

20GB of free CLOUD STORAGE: Use this link to sign up for a free 15GB Copy.com cloud storage account and we both get an extra 5GB of free space.

Last edited by DoctorOhh; 05-24-2010 at 04:30 AM.
DoctorOhh is offline