mirror of
				https://github.com/kovidgoyal/calibre.git
				synced 2025-10-30 18:22:25 -04:00 
			
		
		
		
	EPUB Output: Remove <img> tags that point to the internet for their images as this causes the ever delicate ADE to crash. Fixes #4692 (epub file from NY Times (subscription) site crashes Sony PRS-700)
This commit is contained in:
		
							parent
							
								
									79bb3ba005
								
							
						
					
					
						commit
						d2b721e678
					
				| @ -269,7 +269,7 @@ class EPUBOutput(OutputFormatPlugin): | ||||
|                 bad = [] | ||||
|                 for x in XPath('//h:img')(body): | ||||
|                     src = x.get('src', '').strip() | ||||
|                     if src in ('', '#'): | ||||
|                     if src in ('', '#') or src.startswith('http:'): | ||||
|                         bad.append(x) | ||||
|                 for img in bad: | ||||
|                     img.getparent().remove(img) | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user