Add subtitle in OPDS feed. suggested by Tyler J. Wagner.
This commit is contained in:
		
							parent
							
								
									1522c3c14d
								
							
						
					
					
						commit
						e7ac49244c
					
				
					 3 changed files with 12 additions and 0 deletions
				
			
		|  | @ -83,6 +83,12 @@ class OPDSRenderer | ||||||
|             self::getXmlStream ()->startElement ("title"); |             self::getXmlStream ()->startElement ("title"); | ||||||
|                 self::getXmlStream ()->text ($page->title); |                 self::getXmlStream ()->text ($page->title); | ||||||
|             self::getXmlStream ()->endElement (); |             self::getXmlStream ()->endElement (); | ||||||
|  |             if ($page->subtitle != "") | ||||||
|  |             { | ||||||
|  |                 self::getXmlStream ()->startElement ("subtitle"); | ||||||
|  |                     self::getXmlStream ()->text ($page->subtitle); | ||||||
|  |                 self::getXmlStream ()->endElement (); | ||||||
|  |             } | ||||||
|             self::getXmlStream ()->startElement ("id"); |             self::getXmlStream ()->startElement ("id"); | ||||||
|                 if ($page->idPage) |                 if ($page->idPage) | ||||||
|                 { |                 { | ||||||
|  |  | ||||||
							
								
								
									
										2
									
								
								base.php
									
										
									
									
									
								
							
							
						
						
									
										2
									
								
								base.php
									
										
									
									
									
								
							|  | @ -188,6 +188,7 @@ class EntryBook extends Entry | ||||||
| class Page | class Page | ||||||
| { | { | ||||||
|     public $title; |     public $title; | ||||||
|  |     public $subtitle = ""; | ||||||
|     public $idPage; |     public $idPage; | ||||||
|     public $idGet; |     public $idGet; | ||||||
|     public $query; |     public $query; | ||||||
|  | @ -243,6 +244,7 @@ class Page | ||||||
|     { |     { | ||||||
|         global $config; |         global $config; | ||||||
|         $this->title = $config['cops_title_default']; |         $this->title = $config['cops_title_default']; | ||||||
|  |         $this->subtitle = $config['cops_subtitle_default']; | ||||||
|         array_push ($this->entryArray, Author::getCount()); |         array_push ($this->entryArray, Author::getCount()); | ||||||
|         array_push ($this->entryArray, Serie::getCount()); |         array_push ($this->entryArray, Serie::getCount()); | ||||||
|         array_push ($this->entryArray, Tag::getCount()); |         array_push ($this->entryArray, Tag::getCount()); | ||||||
|  |  | ||||||
|  | @ -41,6 +41,10 @@ | ||||||
|      */ |      */ | ||||||
|     $config['cops_title_default'] = "Sebastien's COPS";  |     $config['cops_title_default'] = "Sebastien's COPS";  | ||||||
| 
 | 
 | ||||||
|  |     /* | ||||||
|  |      * Catalog's subtitle | ||||||
|  |      */ | ||||||
|  |     $config['cops_subtitle_default'] = "";  | ||||||
|      |      | ||||||
|     /* |     /* | ||||||
|      * Wich header to use when downloading books outside the web directory |      * Wich header to use when downloading books outside the web directory | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue