Page Menu
Home
DevCentral
Search
Configure Global Search
Log In
Files
F3766368
D738.id1851.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Referenced Files
None
Subscribers
None
D738.id1851.diff
View Options
diff --git a/pages/index.dat b/pages/index.dat
--- a/pages/index.dat
+++ b/pages/index.dat
@@ -13,6 +13,7 @@
http://www.jstor.org/ JSTOR
http://www.lalibre.be/ LaLibreBelgique
http://www.latimes.com/ LosAngelesTimes
+http://www.lavenir.net/ LAvenir
http://www.lefigaro.fr/ LeFigaro
http://www.lemonde.fr/ LeMonde
http://www.leparisien.fr/ LeParisien
diff --git a/pages/lavenir.php b/pages/lavenir.php
new file mode 100644
--- /dev/null
+++ b/pages/lavenir.php
@@ -0,0 +1,31 @@
+<?php
+
+require_once('helpers/namecase.php');
+
+/**
+ * Represents a page from the http://www.lavenir.net/ site.
+ */
+class LAvenirPage extends Page {
+ /**
+ * Analyses the page and extracts metadata
+ */
+ function analyse () {
+ parent::analyse();
+
+ $author = self::between('<span itemprop="author">', '</span>');
+ $this->author = name_case($author);
+
+ $this->extractDate();
+
+ $this->site = "[[L'Avenir (Belgique)|L'Avenir]]";
+ }
+
+ function extractDate () {
+ $pattern = "/dmf([12][0-9]{3})([0-9]{2})([0-9]{2})/";
+ if (preg_match($pattern, $this->url, $matches)) {
+ $this->yyyy = $matches[1];
+ $this->mm = $matches[2];
+ $this->dd = $matches[3];
+ }
+ }
+}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sat, Nov 23, 17:54 (18 h, 56 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2257991
Default Alt Text
D738.id1851.diff (1 KB)
Attached To
Mode
D738: Analyze L'Avenir
Attached
Detach File
Event Timeline
Log In to Comment