Completed
Pull Request — dev (#310)
by Alies
04:03
created
resources/views/vendor/sitemap/xml-mobile.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,7 +1,7 @@
 block discarded – undo
1 1
 <?= '<'.'?'.'xml version="1.0" encoding="UTF-8"?>'."\n" ?>
2 2
 <?php if ($style != null) echo '<'.'?'.'xml-stylesheet href="'.$style.'" type="text/xsl"?>'."\n"; ?>
3 3
 <urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9" xmlns:mobile="http://www.google.com/schemas/sitemap-mobile/1.0">
4
-<?php foreach($items as $item) : ?>
4
+<?php foreach ($items as $item) : ?>
5 5
   <url>
6 6
     <loc><?= $item['loc'] ?></loc>
7 7
     <mobile:mobile/>
Please login to merge, or discard this patch.
Braces   +4 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,5 +1,8 @@
 block discarded – undo
1 1
 <?= '<'.'?'.'xml version="1.0" encoding="UTF-8"?>'."\n" ?>
2
-<?php if ($style != null) echo '<'.'?'.'xml-stylesheet href="'.$style.'" type="text/xsl"?>'."\n"; ?>
2
+<?php if ($style != null) {
3
+    echo '<'.'?'.'xml-stylesheet href="'.$style.'" type="text/xsl"?>'."\n";
4
+}
5
+?>
3 6
 <urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9" xmlns:mobile="http://www.google.com/schemas/sitemap-mobile/1.0">
4 7
 <?php foreach($items as $item) : ?>
5 8
   <url>
Please login to merge, or discard this patch.
resources/views/vendor/sitemap/html.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -6,7 +6,7 @@
 block discarded – undo
6 6
 <body>
7 7
     <h1><a href="<?= $channel['link'] ?>"><?= $channel['title'] ?></a></h1>
8 8
     <ul>
9
-        <?php foreach($items as $item) : ?>
9
+        <?php foreach ($items as $item) : ?>
10 10
         <li>
11 11
             <a href="<?= $item['loc'] ?>"><?= (empty($item['title'])) ? $item['loc'] : $item['title'] ?></a>
12 12
             <small>(last updated: <?= date('Y-m-d\TH:i:sP', strtotime($item['lastmod'])) ?>)</small>
Please login to merge, or discard this patch.
resources/views/vendor/sitemap/sitemapindex.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -1,10 +1,10 @@
 block discarded – undo
1 1
 <?= '<'.'?'.'xml version="1.0" encoding="UTF-8"?>'."\n"; ?>
2 2
 <?php if ($style != null) echo '<'.'?'.'xml-stylesheet href="'.$style.'" type="text/xsl"?>'."\n"; ?>
3 3
 <sitemapindex xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
4
-<?php foreach($sitemaps as $sitemap) : ?>
4
+<?php foreach ($sitemaps as $sitemap) : ?>
5 5
 	<sitemap>
6 6
 		<loc><?= $sitemap['loc'] ?></loc>
7
-	<?php if($sitemap['lastmod'] !== null) : ?>
7
+	<?php if ($sitemap['lastmod'] !== null) : ?>
8 8
 		<lastmod><?= date('Y-m-d\TH:i:sP', strtotime($sitemap['lastmod'])) ?></lastmod>
9 9
 	<?php endif; ?>
10 10
 	</sitemap>
Please login to merge, or discard this patch.
Braces   +4 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,5 +1,8 @@
 block discarded – undo
1 1
 <?= '<'.'?'.'xml version="1.0" encoding="UTF-8"?>'."\n"; ?>
2
-<?php if ($style != null) echo '<'.'?'.'xml-stylesheet href="'.$style.'" type="text/xsl"?>'."\n"; ?>
2
+<?php if ($style != null) {
3
+    echo '<'.'?'.'xml-stylesheet href="'.$style.'" type="text/xsl"?>'."\n";
4
+}
5
+?>
3 6
 <sitemapindex xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
4 7
 <?php foreach($sitemaps as $sitemap) : ?>
5 8
 	<sitemap>
Please login to merge, or discard this patch.
resources/views/vendor/sitemap/google-news.php 3 patches
Indentation   +14 added lines, -14 removed lines patch added patch discarded remove patch
@@ -5,16 +5,16 @@  discard block
 block discarded – undo
5 5
   <url>
6 6
     <loc><?= $item['loc'] ?></loc>
7 7
     <?php
8
-      if ($item['lastmod'] !== null) {
8
+        if ($item['lastmod'] !== null) {
9 9
         echo '<lastmod>' . date('Y-m-d\TH:i:sP', strtotime($item['lastmod'])) . '</lastmod>' . "\n";
10
-      }
10
+        }
11 11
     ?>
12 12
     <?php
13
-      if (!empty($item['alternates'])) {
13
+        if (!empty($item['alternates'])) {
14 14
         foreach ($item['alternates'] as $alternate) {
15
-          echo '<xhtml:link rel="alternate" media="' . $alternate['media'] . '" href="' . $alternate['url'] . '" />' . "\n";
15
+            echo '<xhtml:link rel="alternate" media="' . $alternate['media'] . '" href="' . $alternate['url'] . '" />' . "\n";
16
+        }
16 17
         }
17
-      }
18 18
     ?>
19 19
     <news:news>
20 20
       <news:publication>
@@ -24,22 +24,22 @@  discard block
 block discarded – undo
24 24
       <news:publication_date><?= date('Y-m-d\TH:i:sP', strtotime($item['googlenews']['publication_date'])) ?></news:publication_date>
25 25
       <news:title><?= $item['title'] ?></news:title>
26 26
   <?php
27
-  if (isset($item['googlenews']['access'])) {
27
+    if (isset($item['googlenews']['access'])) {
28 28
     echo "\t\t" . '<news:access>' . $item['googlenews']['access'] . '</news:access>' . "\n";
29
-  }
29
+    }
30 30
 
31
-  if (isset($item['googlenews']['keywords'])) {
31
+    if (isset($item['googlenews']['keywords'])) {
32 32
     echo "\t\t" . '<news:keywords>' . implode(',', $item['googlenews']['keywords']) . '</news:keywords>' . "\n";
33
-  }
33
+    }
34 34
 
35
-  if (isset($item['googlenews']['genres'])) {
35
+    if (isset($item['googlenews']['genres'])) {
36 36
     echo "\t\t" . '<news:genres>' . implode(',', $item['googlenews']['genres']) . '</news:genres>' . "\n";
37
-  }
37
+    }
38 38
 
39
-  if (isset($item['googlenews']['stock_tickers'])) {
39
+    if (isset($item['googlenews']['stock_tickers'])) {
40 40
     echo "\t\t" . '<news:stock_tickers>' . implode(',', $item['googlenews']['stock_tickers']) . '</news:stock_tickers>' . "\n";
41
-  }
42
-  ?>
41
+    }
42
+    ?>
43 43
     </news:news>
44 44
   </url>
45 45
 <?php endforeach; ?>
Please login to merge, or discard this patch.
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -1,18 +1,18 @@  discard block
 block discarded – undo
1 1
 <?= '<'.'?'.'xml version="1.0" encoding="UTF-8"?>'."\n" ?>
2 2
 <?php if ($style != null) echo '<'.'?'.'xml-stylesheet href="'.$style.'" type="text/xsl"?>'."\n"; ?>
3 3
 <urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9" xmlns:news="http://www.google.com/schemas/sitemap-news/0.9" xmlns:xhtml="http://www.w3.org/1999/xhtml">
4
-<?php foreach($items as $item) : ?>
4
+<?php foreach ($items as $item) : ?>
5 5
   <url>
6 6
     <loc><?= $item['loc'] ?></loc>
7 7
     <?php
8 8
       if ($item['lastmod'] !== null) {
9
-        echo '<lastmod>' . date('Y-m-d\TH:i:sP', strtotime($item['lastmod'])) . '</lastmod>' . "\n";
9
+        echo '<lastmod>'.date('Y-m-d\TH:i:sP', strtotime($item['lastmod'])).'</lastmod>'."\n";
10 10
       }
11 11
     ?>
12 12
     <?php
13 13
       if (!empty($item['alternates'])) {
14 14
         foreach ($item['alternates'] as $alternate) {
15
-          echo '<xhtml:link rel="alternate" media="' . $alternate['media'] . '" href="' . $alternate['url'] . '" />' . "\n";
15
+          echo '<xhtml:link rel="alternate" media="'.$alternate['media'].'" href="'.$alternate['url'].'" />'."\n";
16 16
         }
17 17
       }
18 18
     ?>
@@ -25,19 +25,19 @@  discard block
 block discarded – undo
25 25
       <news:title><?= $item['title'] ?></news:title>
26 26
   <?php
27 27
   if (isset($item['googlenews']['access'])) {
28
-    echo "\t\t" . '<news:access>' . $item['googlenews']['access'] . '</news:access>' . "\n";
28
+    echo "\t\t".'<news:access>'.$item['googlenews']['access'].'</news:access>'."\n";
29 29
   }
30 30
 
31 31
   if (isset($item['googlenews']['keywords'])) {
32
-    echo "\t\t" . '<news:keywords>' . implode(',', $item['googlenews']['keywords']) . '</news:keywords>' . "\n";
32
+    echo "\t\t".'<news:keywords>'.implode(',', $item['googlenews']['keywords']).'</news:keywords>'."\n";
33 33
   }
34 34
 
35 35
   if (isset($item['googlenews']['genres'])) {
36
-    echo "\t\t" . '<news:genres>' . implode(',', $item['googlenews']['genres']) . '</news:genres>' . "\n";
36
+    echo "\t\t".'<news:genres>'.implode(',', $item['googlenews']['genres']).'</news:genres>'."\n";
37 37
   }
38 38
 
39 39
   if (isset($item['googlenews']['stock_tickers'])) {
40
-    echo "\t\t" . '<news:stock_tickers>' . implode(',', $item['googlenews']['stock_tickers']) . '</news:stock_tickers>' . "\n";
40
+    echo "\t\t".'<news:stock_tickers>'.implode(',', $item['googlenews']['stock_tickers']).'</news:stock_tickers>'."\n";
41 41
   }
42 42
   ?>
43 43
     </news:news>
Please login to merge, or discard this patch.
Braces   +4 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,5 +1,8 @@
 block discarded – undo
1 1
 <?= '<'.'?'.'xml version="1.0" encoding="UTF-8"?>'."\n" ?>
2
-<?php if ($style != null) echo '<'.'?'.'xml-stylesheet href="'.$style.'" type="text/xsl"?>'."\n"; ?>
2
+<?php if ($style != null) {
3
+    echo '<'.'?'.'xml-stylesheet href="'.$style.'" type="text/xsl"?>'."\n";
4
+}
5
+?>
3 6
 <urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9" xmlns:news="http://www.google.com/schemas/sitemap-news/0.9" xmlns:xhtml="http://www.w3.org/1999/xhtml">
4 7
 <?php foreach($items as $item) : ?>
5 8
   <url>
Please login to merge, or discard this patch.
resources/views/vendor/sitemap/ror-rss.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -3,7 +3,7 @@
 block discarded – undo
3 3
 <channel>
4 4
     <title><?= $channel['title'] ?></title>
5 5
     <link><?= $channel['link'] ?></link>
6
-<?php foreach($items as $item) : ?>
6
+<?php foreach ($items as $item) : ?>
7 7
     <item>
8 8
         <link><?= $item['loc'] ?></link>
9 9
         <title><?= $item['title'] ?></title>
Please login to merge, or discard this patch.
resources/views/vendor/sitemap/txt.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -1,6 +1,6 @@
 block discarded – undo
1 1
 <?php
2 2
 
3
-foreach($items as $item)
3
+foreach ($items as $item)
4 4
 {
5
-    echo $item['loc'] . "\n";
5
+    echo $item['loc']."\n";
6 6
 }
7 7
\ No newline at end of file
Please login to merge, or discard this patch.
resources/views/vendor/sitemap/xml.php 3 patches
Indentation   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -7,31 +7,31 @@  discard block
 block discarded – undo
7 7
 <?php
8 8
 
9 9
 if (!empty($item['translations'])) {
10
-  foreach ($item['translations'] as $translation) {
10
+    foreach ($item['translations'] as $translation) {
11 11
     echo "\t\t" . '<xhtml:link rel="alternate" hreflang="' . $translation['language'] . '" href="' . $translation['url'] . '" />' . "\n";
12
-  }
12
+    }
13 13
 }
14 14
 
15 15
 if (!empty($item['alternates'])) {
16
-  foreach ($item['alternates'] as $alternate) {
16
+    foreach ($item['alternates'] as $alternate) {
17 17
     echo "\t\t" . '<xhtml:link rel="alternate" media="' . $alternate['media'] . '" href="' . $alternate['url'] . '" />' . "\n";
18
-  }
18
+    }
19 19
 }
20 20
 
21 21
 if ($item['priority'] !== null) {
22
-  echo "\t\t" . '<priority>' . $item['priority'] . '</priority>' . "\n";
22
+    echo "\t\t" . '<priority>' . $item['priority'] . '</priority>' . "\n";
23 23
 }
24 24
 
25 25
 if ($item['lastmod'] !== null) {
26
-  echo "\t\t" . '<lastmod>' . date('Y-m-d\TH:i:sP', strtotime($item['lastmod'])) . '</lastmod>' . "\n";
26
+    echo "\t\t" . '<lastmod>' . date('Y-m-d\TH:i:sP', strtotime($item['lastmod'])) . '</lastmod>' . "\n";
27 27
 }
28 28
 
29 29
 if ($item['freq'] !== null) {
30
-  echo "\t\t" . '<changefreq>' . $item['freq'] . '</changefreq>' . "\n";
30
+    echo "\t\t" . '<changefreq>' . $item['freq'] . '</changefreq>' . "\n";
31 31
 }
32 32
 
33 33
 if (!empty($item['images'])) {
34
-  foreach($item['images'] as $image) {
34
+    foreach($item['images'] as $image) {
35 35
     echo "\t\t" . '<image:image>' . "\n";
36 36
     echo "\t\t\t" . '<image:loc>' . $image['url'] . '</image:loc>' . "\n";
37 37
     if (isset($image['title'])) echo "\t\t\t" . '<image:title>' . $image['title'] . '</image:title>' . "\n";
@@ -39,11 +39,11 @@  discard block
 block discarded – undo
39 39
     if (isset($image['geo_location'])) echo "\t\t\t" . '<image:geo_location>' . $image['geo_location'] . '</image:geo_location>' . "\n";
40 40
     if (isset($image['license'])) echo "\t\t\t" . '<image:license>' . $image['license'] . '</image:license>' . "\n";
41 41
     echo "\t\t" . '</image:image>' . "\n";
42
-  }
42
+    }
43 43
 }
44 44
 
45 45
 if (!empty($item['videos'])) {
46
-  foreach($item['videos'] as $video) {
46
+    foreach($item['videos'] as $video) {
47 47
     echo "\t\t" . '<video:video>' . "\n";
48 48
     if (isset($video['thumbnail_loc'])) echo "\t\t\t" . '<video:thumbnail_loc>' . $video['thumbnail_loc'] . '</video:thumbnail_loc>' . "\n";
49 49
     if (isset($video['title'])) echo "\t\t\t" . '<video:title><![CDATA[' . $video['title'] . ']]></video:title>' . "\n";
@@ -58,13 +58,13 @@  discard block
 block discarded – undo
58 58
     if (isset($video['requires_subscription'])) echo "\t\t\t" . '<video:requires_subscription>' . $video['requires_subscription'] . '</video:requires_subscription>' . "\n";
59 59
     if (isset($video['live'])) echo "\t\t\t" . '<video:live>' . $video['live'] . '</video:live>' . "\n";
60 60
     if (isset($video['player_loc'])) echo "\t\t\t" . '<video:player_loc allow_embed="'. $video['player_loc']['allow_embed'] .'" autoplay="'.
61
-      $video['player_loc']['autoplay'] .'">' . $video['player_loc']['player_loc'] . '</video:player_loc>' . "\n";
61
+        $video['player_loc']['autoplay'] .'">' . $video['player_loc']['player_loc'] . '</video:player_loc>' . "\n";
62 62
     if (isset($video['restriction'])) echo "\t\t\t" . '<video:restriction relationship="'.$video['restriction']['relationship'].'">' . $video['restriction']['restriction'] . '</video:restriction>' . "\n";
63 63
     if (isset($video['gallery_loc'])) echo "\t\t\t" . '<video:gallery_loc title="'.$video['gallery_loc']['title'].'">' . $video['gallery_loc']['gallery_loc'] . '</video:gallery_loc>' . "\n";
64 64
     if (isset($video['price'])) echo "\t\t\t" . '<video:price currency="'.$video['price']['currency'].'">' . $video['price']['price'] . '</video:price>' . "\n";
65 65
     if (isset($video['uploader'])) echo "\t\t\t" . '<video:uploader info="'.$video['uploader']['info'].'">' . $video['uploader']['uploader'] . '</video:uploader>' . "\n";
66 66
     echo "\t\t" . '</video:video>' . "\n";
67
-  }
67
+    }
68 68
 }
69 69
 
70 70
 ?>
Please login to merge, or discard this patch.
Spacing   +35 added lines, -35 removed lines patch added patch discarded remove patch
@@ -1,69 +1,69 @@
 block discarded – undo
1 1
 <?= '<'.'?'.'xml version="1.0" encoding="UTF-8"?>'."\n" ?>
2 2
 <?php if ($style != null) echo '<'.'?'.'xml-stylesheet href="'.$style.'" type="text/xsl"?>'."\n"; ?>
3 3
 <urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:image="http://www.google.com/schemas/sitemap-image/1.1" xmlns:video="http://www.google.com/schemas/sitemap-video/1.1">
4
-<?php foreach($items as $item) : ?>
4
+<?php foreach ($items as $item) : ?>
5 5
   <url>
6 6
     <loc><?= $item['loc'] ?></loc>
7 7
 <?php
8 8
 
9 9
 if (!empty($item['translations'])) {
10 10
   foreach ($item['translations'] as $translation) {
11
-    echo "\t\t" . '<xhtml:link rel="alternate" hreflang="' . $translation['language'] . '" href="' . $translation['url'] . '" />' . "\n";
11
+    echo "\t\t".'<xhtml:link rel="alternate" hreflang="'.$translation['language'].'" href="'.$translation['url'].'" />'."\n";
12 12
   }
13 13
 }
14 14
 
15 15
 if (!empty($item['alternates'])) {
16 16
   foreach ($item['alternates'] as $alternate) {
17
-    echo "\t\t" . '<xhtml:link rel="alternate" media="' . $alternate['media'] . '" href="' . $alternate['url'] . '" />' . "\n";
17
+    echo "\t\t".'<xhtml:link rel="alternate" media="'.$alternate['media'].'" href="'.$alternate['url'].'" />'."\n";
18 18
   }
19 19
 }
20 20
 
21 21
 if ($item['priority'] !== null) {
22
-  echo "\t\t" . '<priority>' . $item['priority'] . '</priority>' . "\n";
22
+  echo "\t\t".'<priority>'.$item['priority'].'</priority>'."\n";
23 23
 }
24 24
 
25 25
 if ($item['lastmod'] !== null) {
26
-  echo "\t\t" . '<lastmod>' . date('Y-m-d\TH:i:sP', strtotime($item['lastmod'])) . '</lastmod>' . "\n";
26
+  echo "\t\t".'<lastmod>'.date('Y-m-d\TH:i:sP', strtotime($item['lastmod'])).'</lastmod>'."\n";
27 27
 }
28 28
 
29 29
 if ($item['freq'] !== null) {
30
-  echo "\t\t" . '<changefreq>' . $item['freq'] . '</changefreq>' . "\n";
30
+  echo "\t\t".'<changefreq>'.$item['freq'].'</changefreq>'."\n";
31 31
 }
32 32
 
33 33
 if (!empty($item['images'])) {
34
-  foreach($item['images'] as $image) {
35
-    echo "\t\t" . '<image:image>' . "\n";
36
-    echo "\t\t\t" . '<image:loc>' . $image['url'] . '</image:loc>' . "\n";
37
-    if (isset($image['title'])) echo "\t\t\t" . '<image:title>' . $image['title'] . '</image:title>' . "\n";
38
-    if (isset($image['caption'])) echo "\t\t\t" . '<image:caption>' . $image['caption'] . '</image:caption>' . "\n";
39
-    if (isset($image['geo_location'])) echo "\t\t\t" . '<image:geo_location>' . $image['geo_location'] . '</image:geo_location>' . "\n";
40
-    if (isset($image['license'])) echo "\t\t\t" . '<image:license>' . $image['license'] . '</image:license>' . "\n";
41
-    echo "\t\t" . '</image:image>' . "\n";
34
+  foreach ($item['images'] as $image) {
35
+    echo "\t\t".'<image:image>'."\n";
36
+    echo "\t\t\t".'<image:loc>'.$image['url'].'</image:loc>'."\n";
37
+    if (isset($image['title'])) echo "\t\t\t".'<image:title>'.$image['title'].'</image:title>'."\n";
38
+    if (isset($image['caption'])) echo "\t\t\t".'<image:caption>'.$image['caption'].'</image:caption>'."\n";
39
+    if (isset($image['geo_location'])) echo "\t\t\t".'<image:geo_location>'.$image['geo_location'].'</image:geo_location>'."\n";
40
+    if (isset($image['license'])) echo "\t\t\t".'<image:license>'.$image['license'].'</image:license>'."\n";
41
+    echo "\t\t".'</image:image>'."\n";
42 42
   }
43 43
 }
44 44
 
45 45
 if (!empty($item['videos'])) {
46
-  foreach($item['videos'] as $video) {
47
-    echo "\t\t" . '<video:video>' . "\n";
48
-    if (isset($video['thumbnail_loc'])) echo "\t\t\t" . '<video:thumbnail_loc>' . $video['thumbnail_loc'] . '</video:thumbnail_loc>' . "\n";
49
-    if (isset($video['title'])) echo "\t\t\t" . '<video:title><![CDATA[' . $video['title'] . ']]></video:title>' . "\n";
50
-    if (isset($video['description'])) echo "\t\t\t" . '<video:description><![CDATA[' . $video['description'] . ']]></video:description>' . "\n";
51
-    if (isset($video['content_loc'])) echo "\t\t\t" . '<video:content_loc>' . $video['content_loc'] . '</video:content_loc>' . "\n";
52
-    if (isset($video['duration'])) echo "\t\t\t" . '<video:duration>' . $video['duration'] . '</video:duration>' . "\n";
53
-    if (isset($video['expiration_date'])) echo "\t\t\t" . '<video:expiration_date>' . $video['expiration_date'] . '</video:expiration_date>' . "\n";
54
-    if (isset($video['rating'])) echo "\t\t\t" . '<video:rating>' . $video['rating'] . '</video:rating>' . "\n";
55
-    if (isset($video['view_count'])) echo "\t\t\t" . '<video:view_count>' . $video['view_count'] . '</video:view_count>' . "\n";
56
-    if (isset($video['publication_date'])) echo "\t\t\t" . '<video:publication_date>' . $video['publication_date'] . '</video:publication_date>' . "\n";
57
-    if (isset($video['family_friendly'])) echo "\t\t\t" . '<video:family_friendly>' . $video['family_friendly'] . '</video:family_friendly>' . "\n";
58
-    if (isset($video['requires_subscription'])) echo "\t\t\t" . '<video:requires_subscription>' . $video['requires_subscription'] . '</video:requires_subscription>' . "\n";
59
-    if (isset($video['live'])) echo "\t\t\t" . '<video:live>' . $video['live'] . '</video:live>' . "\n";
60
-    if (isset($video['player_loc'])) echo "\t\t\t" . '<video:player_loc allow_embed="'. $video['player_loc']['allow_embed'] .'" autoplay="'.
61
-      $video['player_loc']['autoplay'] .'">' . $video['player_loc']['player_loc'] . '</video:player_loc>' . "\n";
62
-    if (isset($video['restriction'])) echo "\t\t\t" . '<video:restriction relationship="'.$video['restriction']['relationship'].'">' . $video['restriction']['restriction'] . '</video:restriction>' . "\n";
63
-    if (isset($video['gallery_loc'])) echo "\t\t\t" . '<video:gallery_loc title="'.$video['gallery_loc']['title'].'">' . $video['gallery_loc']['gallery_loc'] . '</video:gallery_loc>' . "\n";
64
-    if (isset($video['price'])) echo "\t\t\t" . '<video:price currency="'.$video['price']['currency'].'">' . $video['price']['price'] . '</video:price>' . "\n";
65
-    if (isset($video['uploader'])) echo "\t\t\t" . '<video:uploader info="'.$video['uploader']['info'].'">' . $video['uploader']['uploader'] . '</video:uploader>' . "\n";
66
-    echo "\t\t" . '</video:video>' . "\n";
46
+  foreach ($item['videos'] as $video) {
47
+    echo "\t\t".'<video:video>'."\n";
48
+    if (isset($video['thumbnail_loc'])) echo "\t\t\t".'<video:thumbnail_loc>'.$video['thumbnail_loc'].'</video:thumbnail_loc>'."\n";
49
+    if (isset($video['title'])) echo "\t\t\t".'<video:title><![CDATA['.$video['title'].']]></video:title>'."\n";
50
+    if (isset($video['description'])) echo "\t\t\t".'<video:description><![CDATA['.$video['description'].']]></video:description>'."\n";
51
+    if (isset($video['content_loc'])) echo "\t\t\t".'<video:content_loc>'.$video['content_loc'].'</video:content_loc>'."\n";
52
+    if (isset($video['duration'])) echo "\t\t\t".'<video:duration>'.$video['duration'].'</video:duration>'."\n";
53
+    if (isset($video['expiration_date'])) echo "\t\t\t".'<video:expiration_date>'.$video['expiration_date'].'</video:expiration_date>'."\n";
54
+    if (isset($video['rating'])) echo "\t\t\t".'<video:rating>'.$video['rating'].'</video:rating>'."\n";
55
+    if (isset($video['view_count'])) echo "\t\t\t".'<video:view_count>'.$video['view_count'].'</video:view_count>'."\n";
56
+    if (isset($video['publication_date'])) echo "\t\t\t".'<video:publication_date>'.$video['publication_date'].'</video:publication_date>'."\n";
57
+    if (isset($video['family_friendly'])) echo "\t\t\t".'<video:family_friendly>'.$video['family_friendly'].'</video:family_friendly>'."\n";
58
+    if (isset($video['requires_subscription'])) echo "\t\t\t".'<video:requires_subscription>'.$video['requires_subscription'].'</video:requires_subscription>'."\n";
59
+    if (isset($video['live'])) echo "\t\t\t".'<video:live>'.$video['live'].'</video:live>'."\n";
60
+    if (isset($video['player_loc'])) echo "\t\t\t".'<video:player_loc allow_embed="'.$video['player_loc']['allow_embed'].'" autoplay="'.
61
+      $video['player_loc']['autoplay'].'">'.$video['player_loc']['player_loc'].'</video:player_loc>'."\n";
62
+    if (isset($video['restriction'])) echo "\t\t\t".'<video:restriction relationship="'.$video['restriction']['relationship'].'">'.$video['restriction']['restriction'].'</video:restriction>'."\n";
63
+    if (isset($video['gallery_loc'])) echo "\t\t\t".'<video:gallery_loc title="'.$video['gallery_loc']['title'].'">'.$video['gallery_loc']['gallery_loc'].'</video:gallery_loc>'."\n";
64
+    if (isset($video['price'])) echo "\t\t\t".'<video:price currency="'.$video['price']['currency'].'">'.$video['price']['price'].'</video:price>'."\n";
65
+    if (isset($video['uploader'])) echo "\t\t\t".'<video:uploader info="'.$video['uploader']['info'].'">'.$video['uploader']['uploader'].'</video:uploader>'."\n";
66
+    echo "\t\t".'</video:video>'."\n";
67 67
   }
68 68
 }
69 69
 
Please login to merge, or discard this patch.
Braces   +67 added lines, -22 removed lines patch added patch discarded remove patch
@@ -1,5 +1,8 @@  discard block
 block discarded – undo
1 1
 <?= '<'.'?'.'xml version="1.0" encoding="UTF-8"?>'."\n" ?>
2
-<?php if ($style != null) echo '<'.'?'.'xml-stylesheet href="'.$style.'" type="text/xsl"?>'."\n"; ?>
2
+<?php if ($style != null) {
3
+    echo '<'.'?'.'xml-stylesheet href="'.$style.'" type="text/xsl"?>'."\n";
4
+}
5
+?>
3 6
 <urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:image="http://www.google.com/schemas/sitemap-image/1.1" xmlns:video="http://www.google.com/schemas/sitemap-video/1.1">
4 7
 <?php foreach($items as $item) : ?>
5 8
   <url>
@@ -34,10 +37,18 @@  discard block
 block discarded – undo
34 37
   foreach($item['images'] as $image) {
35 38
     echo "\t\t" . '<image:image>' . "\n";
36 39
     echo "\t\t\t" . '<image:loc>' . $image['url'] . '</image:loc>' . "\n";
37
-    if (isset($image['title'])) echo "\t\t\t" . '<image:title>' . $image['title'] . '</image:title>' . "\n";
38
-    if (isset($image['caption'])) echo "\t\t\t" . '<image:caption>' . $image['caption'] . '</image:caption>' . "\n";
39
-    if (isset($image['geo_location'])) echo "\t\t\t" . '<image:geo_location>' . $image['geo_location'] . '</image:geo_location>' . "\n";
40
-    if (isset($image['license'])) echo "\t\t\t" . '<image:license>' . $image['license'] . '</image:license>' . "\n";
40
+    if (isset($image['title'])) {
41
+        echo "\t\t\t" . '<image:title>' . $image['title'] . '</image:title>' . "\n";
42
+    }
43
+    if (isset($image['caption'])) {
44
+        echo "\t\t\t" . '<image:caption>' . $image['caption'] . '</image:caption>' . "\n";
45
+    }
46
+    if (isset($image['geo_location'])) {
47
+        echo "\t\t\t" . '<image:geo_location>' . $image['geo_location'] . '</image:geo_location>' . "\n";
48
+    }
49
+    if (isset($image['license'])) {
50
+        echo "\t\t\t" . '<image:license>' . $image['license'] . '</image:license>' . "\n";
51
+    }
41 52
     echo "\t\t" . '</image:image>' . "\n";
42 53
   }
43 54
 }
@@ -45,24 +56,58 @@  discard block
 block discarded – undo
45 56
 if (!empty($item['videos'])) {
46 57
   foreach($item['videos'] as $video) {
47 58
     echo "\t\t" . '<video:video>' . "\n";
48
-    if (isset($video['thumbnail_loc'])) echo "\t\t\t" . '<video:thumbnail_loc>' . $video['thumbnail_loc'] . '</video:thumbnail_loc>' . "\n";
49
-    if (isset($video['title'])) echo "\t\t\t" . '<video:title><![CDATA[' . $video['title'] . ']]></video:title>' . "\n";
50
-    if (isset($video['description'])) echo "\t\t\t" . '<video:description><![CDATA[' . $video['description'] . ']]></video:description>' . "\n";
51
-    if (isset($video['content_loc'])) echo "\t\t\t" . '<video:content_loc>' . $video['content_loc'] . '</video:content_loc>' . "\n";
52
-    if (isset($video['duration'])) echo "\t\t\t" . '<video:duration>' . $video['duration'] . '</video:duration>' . "\n";
53
-    if (isset($video['expiration_date'])) echo "\t\t\t" . '<video:expiration_date>' . $video['expiration_date'] . '</video:expiration_date>' . "\n";
54
-    if (isset($video['rating'])) echo "\t\t\t" . '<video:rating>' . $video['rating'] . '</video:rating>' . "\n";
55
-    if (isset($video['view_count'])) echo "\t\t\t" . '<video:view_count>' . $video['view_count'] . '</video:view_count>' . "\n";
56
-    if (isset($video['publication_date'])) echo "\t\t\t" . '<video:publication_date>' . $video['publication_date'] . '</video:publication_date>' . "\n";
57
-    if (isset($video['family_friendly'])) echo "\t\t\t" . '<video:family_friendly>' . $video['family_friendly'] . '</video:family_friendly>' . "\n";
58
-    if (isset($video['requires_subscription'])) echo "\t\t\t" . '<video:requires_subscription>' . $video['requires_subscription'] . '</video:requires_subscription>' . "\n";
59
-    if (isset($video['live'])) echo "\t\t\t" . '<video:live>' . $video['live'] . '</video:live>' . "\n";
60
-    if (isset($video['player_loc'])) echo "\t\t\t" . '<video:player_loc allow_embed="'. $video['player_loc']['allow_embed'] .'" autoplay="'.
59
+    if (isset($video['thumbnail_loc'])) {
60
+        echo "\t\t\t" . '<video:thumbnail_loc>' . $video['thumbnail_loc'] . '</video:thumbnail_loc>' . "\n";
61
+    }
62
+    if (isset($video['title'])) {
63
+        echo "\t\t\t" . '<video:title><![CDATA[' . $video['title'] . ']]></video:title>' . "\n";
64
+    }
65
+    if (isset($video['description'])) {
66
+        echo "\t\t\t" . '<video:description><![CDATA[' . $video['description'] . ']]></video:description>' . "\n";
67
+    }
68
+    if (isset($video['content_loc'])) {
69
+        echo "\t\t\t" . '<video:content_loc>' . $video['content_loc'] . '</video:content_loc>' . "\n";
70
+    }
71
+    if (isset($video['duration'])) {
72
+        echo "\t\t\t" . '<video:duration>' . $video['duration'] . '</video:duration>' . "\n";
73
+    }
74
+    if (isset($video['expiration_date'])) {
75
+        echo "\t\t\t" . '<video:expiration_date>' . $video['expiration_date'] . '</video:expiration_date>' . "\n";
76
+    }
77
+    if (isset($video['rating'])) {
78
+        echo "\t\t\t" . '<video:rating>' . $video['rating'] . '</video:rating>' . "\n";
79
+    }
80
+    if (isset($video['view_count'])) {
81
+        echo "\t\t\t" . '<video:view_count>' . $video['view_count'] . '</video:view_count>' . "\n";
82
+    }
83
+    if (isset($video['publication_date'])) {
84
+        echo "\t\t\t" . '<video:publication_date>' . $video['publication_date'] . '</video:publication_date>' . "\n";
85
+    }
86
+    if (isset($video['family_friendly'])) {
87
+        echo "\t\t\t" . '<video:family_friendly>' . $video['family_friendly'] . '</video:family_friendly>' . "\n";
88
+    }
89
+    if (isset($video['requires_subscription'])) {
90
+        echo "\t\t\t" . '<video:requires_subscription>' . $video['requires_subscription'] . '</video:requires_subscription>' . "\n";
91
+    }
92
+    if (isset($video['live'])) {
93
+        echo "\t\t\t" . '<video:live>' . $video['live'] . '</video:live>' . "\n";
94
+    }
95
+    if (isset($video['player_loc'])) {
96
+        echo "\t\t\t" . '<video:player_loc allow_embed="'. $video['player_loc']['allow_embed'] .'" autoplay="'.
61 97
       $video['player_loc']['autoplay'] .'">' . $video['player_loc']['player_loc'] . '</video:player_loc>' . "\n";
62
-    if (isset($video['restriction'])) echo "\t\t\t" . '<video:restriction relationship="'.$video['restriction']['relationship'].'">' . $video['restriction']['restriction'] . '</video:restriction>' . "\n";
63
-    if (isset($video['gallery_loc'])) echo "\t\t\t" . '<video:gallery_loc title="'.$video['gallery_loc']['title'].'">' . $video['gallery_loc']['gallery_loc'] . '</video:gallery_loc>' . "\n";
64
-    if (isset($video['price'])) echo "\t\t\t" . '<video:price currency="'.$video['price']['currency'].'">' . $video['price']['price'] . '</video:price>' . "\n";
65
-    if (isset($video['uploader'])) echo "\t\t\t" . '<video:uploader info="'.$video['uploader']['info'].'">' . $video['uploader']['uploader'] . '</video:uploader>' . "\n";
98
+    }
99
+    if (isset($video['restriction'])) {
100
+        echo "\t\t\t" . '<video:restriction relationship="'.$video['restriction']['relationship'].'">' . $video['restriction']['restriction'] . '</video:restriction>' . "\n";
101
+    }
102
+    if (isset($video['gallery_loc'])) {
103
+        echo "\t\t\t" . '<video:gallery_loc title="'.$video['gallery_loc']['title'].'">' . $video['gallery_loc']['gallery_loc'] . '</video:gallery_loc>' . "\n";
104
+    }
105
+    if (isset($video['price'])) {
106
+        echo "\t\t\t" . '<video:price currency="'.$video['price']['currency'].'">' . $video['price']['price'] . '</video:price>' . "\n";
107
+    }
108
+    if (isset($video['uploader'])) {
109
+        echo "\t\t\t" . '<video:uploader info="'.$video['uploader']['info'].'">' . $video['uploader']['uploader'] . '</video:uploader>' . "\n";
110
+    }
66 111
     echo "\t\t" . '</video:video>' . "\n";
67 112
   }
68 113
 }
Please login to merge, or discard this patch.
routes/widget.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -19,6 +19,6 @@
 block discarded – undo
19 19
 Route::post('campaign/{campaignId}/recurrent/donate', 'Widget\CampaignController@donateRecurrent')->name('campaign.recurrent.donate')->where('campaignId', '[0-9]+');
20 20
 
21 21
 /** @todo @fr0zen will remove it */
22
-Route::get('about', function () {})->name('about');
23
-Route::get('contact', function () {})->name('contact');
24
-Route::get('legal-mentions', function () {})->name('legal-mentions');
22
+Route::get('about', function() {})->name('about');
23
+Route::get('contact', function() {})->name('contact');
24
+Route::get('legal-mentions', function() {})->name('legal-mentions');
Please login to merge, or discard this patch.
laravel/helpers.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -2,7 +2,7 @@  discard block
 block discarded – undo
2 2
 
3 3
 use Illuminate\Database\Eloquent\Model;
4 4
 
5
-if (! function_exists('home_route')) {
5
+if (!function_exists('home_route')) {
6 6
     /**
7 7
      * Return the route to the "home" page depending on authentication/authorization status.
8 8
      *
@@ -18,7 +18,7 @@  discard block
 block discarded – undo
18 18
     }
19 19
 }
20 20
 
21
-if (! function_exists('is_admin_route')) {
21
+if (!function_exists('is_admin_route')) {
22 22
     /**
23 23
      * @param \Illuminate\Http\Request $request
24 24
      *
@@ -32,7 +32,7 @@  discard block
 block discarded – undo
32 32
     }
33 33
 }
34 34
 
35
-if (! function_exists('image_template_url')) {
35
+if (!function_exists('image_template_url')) {
36 36
     /**
37 37
      * @param $template
38 38
      * @param $imagePath
@@ -47,7 +47,7 @@  discard block
 block discarded – undo
47 47
     }
48 48
 }
49 49
 
50
-if (! function_exists('localize_url')) {
50
+if (!function_exists('localize_url')) {
51 51
     function localize_url($locale = null, $attributes = [], Model $translatable = null)
52 52
     {
53 53
         $url = null;
Please login to merge, or discard this patch.