]> BookStack Code Mirror - bookstack/commitdiff
Updated all application urls to allow path prefix. 165/head
authorDan Brown <redacted>
Sun, 14 Aug 2016 11:29:35 +0000 (12:29 +0100)
committerDan Brown <redacted>
Sun, 14 Aug 2016 11:29:35 +0000 (12:29 +0100)
Allows BookStack to be installed at a non-root location on a domain.
Closes #40.

81 files changed:
.env.example
app/Book.php
app/Chapter.php
app/Exceptions/Handler.php
app/Http/Controllers/Auth/AuthController.php
app/Http/Controllers/PageController.php
app/Http/Middleware/Authenticate.php
app/Page.php
app/Providers/PaginationServiceProvider.php [new file with mode: 0644]
app/Repos/ImageRepo.php
app/Services/ImageService.php
app/Services/SocialAuthService.php
app/User.php
app/helpers.php
bootstrap/autoload.php
composer.json
config/app.php
config/setting-defaults.php
readme.md
resources/assets/js/controllers.js
resources/assets/js/directives.js
resources/assets/js/global.js
resources/assets/js/pages/page-form.js
resources/assets/js/pages/page-show.js
resources/assets/sass/_fonts.scss
resources/views/auth/forms/login/standard.blade.php
resources/views/auth/login.blade.php
resources/views/auth/password.blade.php
resources/views/auth/register-confirm.blade.php
resources/views/auth/register.blade.php
resources/views/auth/reset.blade.php
resources/views/auth/user-unconfirmed.blade.php
resources/views/base.blade.php
resources/views/books/create.blade.php
resources/views/books/edit.blade.php
resources/views/books/index.blade.php
resources/views/books/show.blade.php
resources/views/books/sort.blade.php
resources/views/chapters/create.blade.php
resources/views/chapters/delete.blade.php
resources/views/chapters/edit.blade.php
resources/views/chapters/list-item.blade.php
resources/views/chapters/move.blade.php
resources/views/chapters/restrictions.blade.php
resources/views/chapters/show.blade.php
resources/views/emails/email-confirmation.blade.php
resources/views/emails/password.blade.php
resources/views/errors/404.blade.php
resources/views/errors/503.blade.php
resources/views/form/restriction-form.blade.php
resources/views/home.blade.php
resources/views/pages/delete.blade.php
resources/views/pages/edit.blade.php
resources/views/pages/form-toolbox.blade.php
resources/views/pages/form.blade.php
resources/views/pages/move.blade.php
resources/views/pages/page-display.blade.php
resources/views/pages/restrictions.blade.php
resources/views/pages/revisions.blade.php
resources/views/pages/show.blade.php
resources/views/pages/sidebar-tree-list.blade.php
resources/views/partials/activity-item.blade.php
resources/views/partials/custom-styles.blade.php
resources/views/partials/highlight.blade.php
resources/views/public.blade.php
resources/views/search/all.blade.php
resources/views/search/entity-search-list.blade.php
resources/views/settings/index.blade.php
resources/views/settings/navbar.blade.php
resources/views/settings/roles/create.blade.php
resources/views/settings/roles/delete.blade.php
resources/views/settings/roles/edit.blade.php
resources/views/settings/roles/form.blade.php
resources/views/settings/roles/index.blade.php
resources/views/users/create.blade.php
resources/views/users/delete.blade.php
resources/views/users/edit.blade.php
resources/views/users/forms/ldap.blade.php
resources/views/users/forms/standard.blade.php
resources/views/users/index.blade.php
resources/views/users/profile.blade.php

index 5661cda2209f753c3827e58a14d73a5f69445fd1..e44a46ef3d54ef58860ced0abe789826ebda43c8 100644 (file)
@@ -3,6 +3,10 @@ APP_ENV=production
 APP_DEBUG=false
 APP_KEY=SomeRandomString
 
 APP_DEBUG=false
 APP_KEY=SomeRandomString
 
+# The below url has to be set if using social auth options
+# or if you are not using BookStack at the root path of your domain.
+# APP_URL=http://bookstack.dev
+
 # Database details
 DB_HOST=localhost
 DB_DATABASE=database_database
 # Database details
 DB_HOST=localhost
 DB_DATABASE=database_database
@@ -42,8 +46,6 @@ GITHUB_APP_ID=false
 GITHUB_APP_SECRET=false
 GOOGLE_APP_ID=false
 GOOGLE_APP_SECRET=false
 GITHUB_APP_SECRET=false
 GOOGLE_APP_ID=false
 GOOGLE_APP_SECRET=false
-# URL used for social login redirects, NO TRAILING SLASH
-APP_URL=http://bookstack.dev
 
 # External services such as Gravatar
 DISABLE_EXTERNAL_SERVICES=false
 
 # External services such as Gravatar
 DISABLE_EXTERNAL_SERVICES=false
index af6d59bfd8f28b35150ee45af9c73d42baaa3e3c..aa2dee9c0a4540f018857e0d7fcb8693c630250b 100644 (file)
@@ -7,10 +7,14 @@ class Book extends Entity
 
     /**
      * Get the url for this book.
 
     /**
      * Get the url for this book.
+     * @param string|bool $path
      * @return string
      */
      * @return string
      */
-    public function getUrl()
+    public function getUrl($path = false)
     {
     {
+        if ($path !== false) {
+            return baseUrl('/books/' . $this->slug . '/' . trim($path, '/'));
+        }
         return baseUrl('/books/' . $this->slug);
     }
 
         return baseUrl('/books/' . $this->slug);
     }
 
index 250e323f5246557c4180481fda27392f00e6643b..8f0453172ff17447e9f86eef125cad7d8c12b445 100644 (file)
@@ -25,11 +25,15 @@ class Chapter extends Entity
 
     /**
      * Get the url of this chapter.
 
     /**
      * Get the url of this chapter.
+     * @param string|bool $path
      * @return string
      */
      * @return string
      */
-    public function getUrl()
+    public function getUrl($path = false)
     {
         $bookSlug = $this->getAttribute('bookSlug') ? $this->getAttribute('bookSlug') : $this->book->slug;
     {
         $bookSlug = $this->getAttribute('bookSlug') ? $this->getAttribute('bookSlug') : $this->book->slug;
+        if ($path !== false) {
+            return baseUrl('/books/' . $bookSlug. '/chapter/' . $this->slug . '/' . trim($path, '/'));
+        }
         return baseUrl('/books/' . $bookSlug. '/chapter/' . $this->slug);
     }
 
         return baseUrl('/books/' . $bookSlug. '/chapter/' . $this->slug);
     }
 
index 14d553ed0bb359b200dfc91a95bdc05ff92501ba..40dd1ec105d3c150a6579ffef095001f3e5a959a 100644 (file)
@@ -48,8 +48,8 @@ class Handler extends ExceptionHandler
         // Handle notify exceptions which will redirect to the
         // specified location then show a notification message.
         if ($e instanceof NotifyException) {
         // Handle notify exceptions which will redirect to the
         // specified location then show a notification message.
         if ($e instanceof NotifyException) {
-            \Session::flash('error', $e->message);
-            return response()->redirectTo($e->redirectLocation);
+            session()->flash('error', $e->message);
+            return redirect($e->redirectLocation);
         }
 
         // Handle pretty exceptions which will show a friendly application-fitting page
         }
 
         // Handle pretty exceptions which will show a friendly application-fitting page
index beb191d624f1841169a17b5467aff9e28c9f3e4d..2cbc047ce75621a20029bf31fa7409601cfe1e87 100644 (file)
@@ -1,9 +1,6 @@
-<?php
-
-namespace BookStack\Http\Controllers\Auth;
+<?php namespace BookStack\Http\Controllers\Auth;
 
 use BookStack\Exceptions\AuthException;
 
 use BookStack\Exceptions\AuthException;
-use BookStack\Exceptions\PrettyException;
 use Illuminate\Contracts\Auth\Authenticatable;
 use Illuminate\Http\Request;
 use BookStack\Exceptions\SocialSignInException;
 use Illuminate\Contracts\Auth\Authenticatable;
 use Illuminate\Http\Request;
 use BookStack\Exceptions\SocialSignInException;
@@ -36,7 +33,6 @@ class AuthController extends Controller
     protected $redirectAfterLogout = '/login';
     protected $username = 'email';
 
     protected $redirectAfterLogout = '/login';
     protected $username = 'email';
 
-
     protected $socialAuthService;
     protected $emailConfirmationService;
     protected $userRepo;
     protected $socialAuthService;
     protected $emailConfirmationService;
     protected $userRepo;
@@ -53,6 +49,8 @@ class AuthController extends Controller
         $this->socialAuthService = $socialAuthService;
         $this->emailConfirmationService = $emailConfirmationService;
         $this->userRepo = $userRepo;
         $this->socialAuthService = $socialAuthService;
         $this->emailConfirmationService = $emailConfirmationService;
         $this->userRepo = $userRepo;
+        $this->redirectPath = baseUrl('/');
+        $this->redirectAfterLogout = baseUrl('/login');
         $this->username = config('auth.method') === 'standard' ? 'email' : 'username';
         parent::__construct();
     }
         $this->username = config('auth.method') === 'standard' ? 'email' : 'username';
         parent::__construct();
     }
index f35834e6221ea73332b7e88b9187c73b899fb8a5..1509ace9563b7aee65fe3b8c167f5e07117bacf6 100644 (file)
@@ -412,7 +412,7 @@ class PageController extends Controller
      */
     public function showRecentlyCreated()
     {
      */
     public function showRecentlyCreated()
     {
-        $pages = $this->pageRepo->getRecentlyCreatedPaginated(20);
+        $pages = $this->pageRepo->getRecentlyCreatedPaginated(20)->setPath(baseUrl('/pages/recently-created'));
         return view('pages/detailed-listing', [
             'title' => 'Recently Created Pages',
             'pages' => $pages
         return view('pages/detailed-listing', [
             'title' => 'Recently Created Pages',
             'pages' => $pages
@@ -425,7 +425,7 @@ class PageController extends Controller
      */
     public function showRecentlyUpdated()
     {
      */
     public function showRecentlyUpdated()
     {
-        $pages = $this->pageRepo->getRecentlyUpdatedPaginated(20);
+        $pages = $this->pageRepo->getRecentlyUpdatedPaginated(20)->setPath(baseUrl('/pages/recently-updated'));
         return view('pages/detailed-listing', [
             'title' => 'Recently Updated Pages',
             'pages' => $pages
         return view('pages/detailed-listing', [
             'title' => 'Recently Updated Pages',
             'pages' => $pages
index 599f40c84a7f61ccf9bf497d152dfb39726a0e81..ee5144e6c7c4edbe95721669a7f89c704a8e8ec0 100644 (file)
@@ -33,7 +33,7 @@ class Authenticate
     public function handle($request, Closure $next)
     {
         if ($this->auth->check() && setting('registration-confirmation') && !$this->auth->user()->email_confirmed) {
     public function handle($request, Closure $next)
     {
         if ($this->auth->check() && setting('registration-confirmation') && !$this->auth->user()->email_confirmed) {
-            return redirect()->guest('/register/confirm/awaiting');
+            return redirect()->guest(baseUrl('/register/confirm/awaiting'));
         }
 
         if ($this->auth->guest() && !setting('app-public')) {
         }
 
         if ($this->auth->guest() && !setting('app-public')) {
index 5902f4f5abed53370ec146eaf15569df20895038..1961a4f7f6bc2ec0e66824397df51c2ec8652f8e 100644 (file)
@@ -56,13 +56,19 @@ class Page extends Entity
 
     /**
      * Get the url for this page.
 
     /**
      * Get the url for this page.
+     * @param string|bool $path
      * @return string
      */
      * @return string
      */
-    public function getUrl()
+    public function getUrl($path = false)
     {
         $bookSlug = $this->getAttribute('bookSlug') ? $this->getAttribute('bookSlug') : $this->book->slug;
         $midText = $this->draft ? '/draft/' : '/page/';
         $idComponent = $this->draft ? $this->id : $this->slug;
     {
         $bookSlug = $this->getAttribute('bookSlug') ? $this->getAttribute('bookSlug') : $this->book->slug;
         $midText = $this->draft ? '/draft/' : '/page/';
         $idComponent = $this->draft ? $this->id : $this->slug;
+
+        if ($path !== false) {
+            return baseUrl('/books/' . $bookSlug . $midText . $idComponent . '/' . trim($path, '/'));
+        }
+
         return baseUrl('/books/' . $bookSlug . $midText . $idComponent);
     }
 
         return baseUrl('/books/' . $bookSlug . $midText . $idComponent);
     }
 
diff --git a/app/Providers/PaginationServiceProvider.php b/app/Providers/PaginationServiceProvider.php
new file mode 100644 (file)
index 0000000..a0e97f7
--- /dev/null
@@ -0,0 +1,30 @@
+<?php namespace BookStack\Providers;
+
+
+use Illuminate\Support\ServiceProvider;
+use Illuminate\Pagination\Paginator;
+
+class PaginationServiceProvider extends ServiceProvider
+{
+    /**
+     * Register the service provider.
+     *
+     * @return void
+     */
+    public function register()
+    {
+        Paginator::currentPathResolver(function () {
+            return baseUrl($this->app['request']->path());
+        });
+
+        Paginator::currentPageResolver(function ($pageName = 'page') {
+            $page = $this->app['request']->input($pageName);
+
+            if (filter_var($page, FILTER_VALIDATE_INT) !== false && (int) $page >= 1) {
+                return $page;
+            }
+
+            return 1;
+        });
+    }
+}
\ No newline at end of file
index 916ebd3e10de5c95ae98bd1defeb8dbd39744144..435b8bbd795666bddc12d1b8e0e687eecb4bcb8b 100644 (file)
@@ -13,7 +13,7 @@ class ImageRepo
 
     protected $image;
     protected $imageService;
 
     protected $image;
     protected $imageService;
-    protected $restictionService;
+    protected $restrictionService;
     protected $page;
 
     /**
     protected $page;
 
     /**
@@ -27,7 +27,7 @@ class ImageRepo
     {
         $this->image = $image;
         $this->imageService = $imageService;
     {
         $this->image = $image;
         $this->imageService = $imageService;
-        $this->restictionService = $permissionService;
+        $this->restrictionService = $permissionService;
         $this->page = $page;
     }
 
         $this->page = $page;
     }
 
@@ -52,7 +52,7 @@ class ImageRepo
      */
     private function returnPaginated($query, $page = 0, $pageSize = 24)
     {
      */
     private function returnPaginated($query, $page = 0, $pageSize = 24)
     {
-        $images = $this->restictionService->filterRelatedPages($query, 'images', 'uploaded_to');
+        $images = $this->restrictionService->filterRelatedPages($query, 'images', 'uploaded_to');
         $images = $images->orderBy('created_at', 'desc')->skip($pageSize * $page)->take($pageSize + 1)->get();
         $hasMore = count($images) > $pageSize;
 
         $images = $images->orderBy('created_at', 'desc')->skip($pageSize * $page)->take($pageSize + 1)->get();
         $hasMore = count($images) > $pageSize;
 
index dd965c90fb449368f92a787d5f9b58d2eedf609d..d9bd61e9fb4ef79cf0174f610a1122d751e6adf1 100644 (file)
@@ -265,7 +265,7 @@ class ImageService
             $this->storageUrl = $storageUrl;
         }
 
             $this->storageUrl = $storageUrl;
         }
 
-        return ($this->storageUrl == false ? '' : rtrim($this->storageUrl, '/')) . $filePath;
+        return ($this->storageUrl == false ? rtrim(baseUrl(''), '/') : rtrim($this->storageUrl, '/')) . $filePath;
     }
 
 
     }
 
 
index ba3479349c4158d80479752daeaff0ec8af204f4..4b99df789c9f3c744a4d75c71b78971e34d663ac 100644 (file)
@@ -113,20 +113,20 @@ class SocialAuthService
         if ($isLoggedIn && $socialAccount === null) {
             $this->fillSocialAccount($socialDriver, $socialUser);
             $currentUser->socialAccounts()->save($this->socialAccount);
         if ($isLoggedIn && $socialAccount === null) {
             $this->fillSocialAccount($socialDriver, $socialUser);
             $currentUser->socialAccounts()->save($this->socialAccount);
-            \Session::flash('success', title_case($socialDriver) . ' account was successfully attached to your profile.');
+            session()->flash('success', title_case($socialDriver) . ' account was successfully attached to your profile.');
             return redirect($currentUser->getEditUrl());
         }
 
         // When a user is logged in and the social account exists and is already linked to the current user.
         if ($isLoggedIn && $socialAccount !== null && $socialAccount->user->id === $currentUser->id) {
             return redirect($currentUser->getEditUrl());
         }
 
         // When a user is logged in and the social account exists and is already linked to the current user.
         if ($isLoggedIn && $socialAccount !== null && $socialAccount->user->id === $currentUser->id) {
-            \Session::flash('error', 'This ' . title_case($socialDriver) . ' account is already attached to your profile.');
+            session()->flash('error', 'This ' . title_case($socialDriver) . ' account is already attached to your profile.');
             return redirect($currentUser->getEditUrl());
         }
 
         // When a user is logged in, A social account exists but the users do not match.
         // Change the user that the social account is assigned to.
         if ($isLoggedIn && $socialAccount !== null && $socialAccount->user->id != $currentUser->id) {
             return redirect($currentUser->getEditUrl());
         }
 
         // When a user is logged in, A social account exists but the users do not match.
         // Change the user that the social account is assigned to.
         if ($isLoggedIn && $socialAccount !== null && $socialAccount->user->id != $currentUser->id) {
-            \Session::flash('success', 'This ' . title_case($socialDriver) . ' account is already used by another user.');
+            session()->flash('success', 'This ' . title_case($socialDriver) . ' account is already used by another user.');
             return redirect($currentUser->getEditUrl());
         }
 
             return redirect($currentUser->getEditUrl());
         }
 
@@ -135,6 +135,7 @@ class SocialAuthService
         if (setting('registration-enabled')) {
             $message .= ' or, If you do not yet have an account, You can register an account using the ' . $socialDriver . ' option';
         }
         if (setting('registration-enabled')) {
             $message .= ' or, If you do not yet have an account, You can register an account using the ' . $socialDriver . ' option';
         }
+        
         throw new SocialSignInException($message . '.', '/login');
     }
 
         throw new SocialSignInException($message . '.', '/login');
     }
 
index 6ab7ad3bf45cd314fe39e188cfcc100c5fdc0449..32449971d7847f8e4d0dc880d3868fd8eb2c528a 100644 (file)
@@ -160,6 +160,15 @@ class User extends Model implements AuthenticatableContract, CanResetPasswordCon
         return baseUrl('/settings/users/' . $this->id);
     }
 
         return baseUrl('/settings/users/' . $this->id);
     }
 
+    /**
+     * Get the url that links to this user's profile.
+     * @return mixed
+     */
+    public function getProfileUrl()
+    {
+        return baseUrl('/user/' . $this->id);
+    }
+
     /**
      * Get a shortened version of the user's name.
      * @param int $chars
     /**
      * Get a shortened version of the user's name.
      * @param int $chars
index 0b9a6afc6347a420185e917d6a7547921bd0fd84..541f23fbe046b4842e8c5df780e7ace8cbc0032d 100644 (file)
@@ -69,10 +69,33 @@ function setting($key, $default = false)
  */
 function baseUrl($path)
 {
  */
 function baseUrl($path)
 {
+    if (strpos($path, 'http') === 0) return $path;
     $path = trim($path, '/');
     return rtrim(config('app.url'), '/') . '/' . $path;
 }
 
     $path = trim($path, '/');
     return rtrim(config('app.url'), '/') . '/' . $path;
 }
 
+/**
+ * Get an instance of the redirector.
+ * Overrides the default laravel redirect helper.
+ * Ensures it redirects even when the app is in a subdirectory.
+ *
+ * @param  string|null  $to
+ * @param  int     $status
+ * @param  array   $headers
+ * @param  bool    $secure
+ * @return \Illuminate\Routing\Redirector|\Illuminate\Http\RedirectResponse
+ */
+function redirect($to = null, $status = 302, $headers = [], $secure = null)
+{
+    if (is_null($to)) {
+        return app('redirect');
+    }
+
+    $to = baseUrl($to);
+
+    return app('redirect')->to($to, $status, $headers, $secure);
+}
+
 /**
  * Generate a url with multiple parameters for sorting purposes.
  * Works out the logic to set the correct sorting direction
 /**
  * Generate a url with multiple parameters for sorting purposes.
  * Works out the logic to set the correct sorting direction
@@ -102,5 +125,5 @@ function sortUrl($path, $data, $overrideData = [])
 
     if (count($queryStringSections) === 0) return $path;
 
 
     if (count($queryStringSections) === 0) return $path;
 
-    return $path . '?' . implode('&', $queryStringSections);
+    return baseUrl($path . '?' . implode('&', $queryStringSections));
 }
\ No newline at end of file
 }
\ No newline at end of file
index 383013796f3c2041b20081e8dc93bddb4ccde0ad..29f66ace473825fd1be89f60468ce572eca9ac46 100644 (file)
@@ -14,6 +14,7 @@ define('LARAVEL_START', microtime(true));
 |
 */
 
 |
 */
 
+require __DIR__.'/../app/helpers.php';
 require __DIR__.'/../vendor/autoload.php';
 
 /*
 require __DIR__.'/../vendor/autoload.php';
 
 /*
index 8f375a279bb2cb3de339dc0924dd51b461528ceb..5c77a68c4afd3de50cd34e2ffd1d5f51d2cd0cbb 100644 (file)
         ],
         "psr-4": {
             "BookStack\\": "app/"
         ],
         "psr-4": {
             "BookStack\\": "app/"
-        },
-        "files": [
-            "app/helpers.php"
-        ]
+        }
     },
     "autoload-dev": {
         "classmap": [
     },
     "autoload-dev": {
         "classmap": [
index 6819fa4814e84477a3980878a1f144ff36397533..0d6f6f2b0744dd8ad37eda1196ac6de239263337 100644 (file)
@@ -130,7 +130,6 @@ return [
         Illuminate\Foundation\Providers\FoundationServiceProvider::class,
         Illuminate\Hashing\HashServiceProvider::class,
         Illuminate\Mail\MailServiceProvider::class,
         Illuminate\Foundation\Providers\FoundationServiceProvider::class,
         Illuminate\Hashing\HashServiceProvider::class,
         Illuminate\Mail\MailServiceProvider::class,
-        Illuminate\Pagination\PaginationServiceProvider::class,
         Illuminate\Pipeline\PipelineServiceProvider::class,
         Illuminate\Queue\QueueServiceProvider::class,
         Illuminate\Redis\RedisServiceProvider::class,
         Illuminate\Pipeline\PipelineServiceProvider::class,
         Illuminate\Queue\QueueServiceProvider::class,
         Illuminate\Redis\RedisServiceProvider::class,
@@ -153,6 +152,8 @@ return [
         /*
          * Application Service Providers...
          */
         /*
          * Application Service Providers...
          */
+        BookStack\Providers\PaginationServiceProvider::class,
+
         BookStack\Providers\AuthServiceProvider::class,
         BookStack\Providers\AppServiceProvider::class,
         BookStack\Providers\EventServiceProvider::class,
         BookStack\Providers\AuthServiceProvider::class,
         BookStack\Providers\AppServiceProvider::class,
         BookStack\Providers\EventServiceProvider::class,
index 6a55a0dc33b6d12be2fde9099d72947bcb1ec769..24a49c364195ca03985f1fae198da59ed52069d9 100644 (file)
@@ -5,8 +5,9 @@
  */
 return [
 
  */
 return [
 
-    'app-editor' => 'wysiwyg',
-    'app-color'  => '#0288D1',
+    'app-name'        => 'BookStack',
+    'app-editor'      => 'wysiwyg',
+    'app-color'       => '#0288D1',
     'app-color-light' => 'rgba(21, 101, 192, 0.15)'
 
 ];
\ No newline at end of file
     'app-color-light' => 'rgba(21, 101, 192, 0.15)'
 
 ];
\ No newline at end of file
index 29ac44f5e50c2ad5cc87cf10b5bb23d480a01e89..3a745beb11ad293919f4db1096253f27b36f48e6 100644 (file)
--- a/readme.md
+++ b/readme.md
@@ -50,3 +50,4 @@ These are the great projects used to help build BookStack:
 * [ZeroClipboard](http://zeroclipboard.org/)
 * [TinyColorPicker](http://www.dematte.at/tinyColorPicker/index.html)
 * [Marked](https://github.com/chjj/marked)
 * [ZeroClipboard](http://zeroclipboard.org/)
 * [TinyColorPicker](http://www.dematte.at/tinyColorPicker/index.html)
 * [Marked](https://github.com/chjj/marked)
+* [Moment.js](http://momentjs.com/)
index 406fd7e77ee30b639cb5426a8efeca8450d452be..9067f6ca42995e187b792c54e6ccbedb50ddaf49 100644 (file)
@@ -1,6 +1,6 @@
 "use strict";
 
 "use strict";
 
-var moment = require('moment');
+const moment = require('moment');
 
 module.exports = function (ngApp, events) {
 
 
 module.exports = function (ngApp, events) {
 
@@ -35,7 +35,7 @@ module.exports = function (ngApp, events) {
              * @returns {string}
              */
             $scope.getUploadUrl = function () {
              * @returns {string}
              */
             $scope.getUploadUrl = function () {
-                return '/images/' + $scope.imageType + '/upload';
+                return window.baseUrl('/images/' + $scope.imageType + '/upload');
             };
 
             /**
             };
 
             /**
@@ -133,7 +133,7 @@ module.exports = function (ngApp, events) {
                 $scope.showing = false;
             };
 
                 $scope.showing = false;
             };
 
-            var baseUrl = '/images/' + $scope.imageType + '/all/'
+            var baseUrl = window.baseUrl('/images/' + $scope.imageType + '/all/');
 
             /**
              * Fetch the list image data from the server.
 
             /**
              * Fetch the list image data from the server.
@@ -178,7 +178,7 @@ module.exports = function (ngApp, events) {
                 $scope.images = [];
                 $scope.hasMore = false;
                 page = 0;
                 $scope.images = [];
                 $scope.hasMore = false;
                 page = 0;
-                baseUrl = '/images/' + $scope.imageType + '/search/';
+                baseUrl = window.baseUrl('/images/' + $scope.imageType + '/search/');
                 fetchData();
             };
 
                 fetchData();
             };
 
@@ -192,7 +192,7 @@ module.exports = function (ngApp, events) {
                 $scope.hasMore = false;
                 page = 0;
                 $scope.view = viewName;
                 $scope.hasMore = false;
                 page = 0;
                 $scope.view = viewName;
-                baseUrl = '/images/' + $scope.imageType  + '/' + viewName + '/';
+                baseUrl = window.baseUrl('/images/' + $scope.imageType  + '/' + viewName + '/');
                 fetchData();
             }
 
                 fetchData();
             }
 
@@ -202,7 +202,7 @@ module.exports = function (ngApp, events) {
              */
             $scope.saveImageDetails = function (event) {
                 event.preventDefault();
              */
             $scope.saveImageDetails = function (event) {
                 event.preventDefault();
-                var url = '/images/update/' + $scope.selectedImage.id;
+                var url = window.baseUrl('/images/update/' + $scope.selectedImage.id);
                 $http.put(url, this.selectedImage).then((response) => {
                     events.emit('success', 'Image details updated');
                 }, (response) => {
                 $http.put(url, this.selectedImage).then((response) => {
                     events.emit('success', 'Image details updated');
                 }, (response) => {
@@ -228,7 +228,7 @@ module.exports = function (ngApp, events) {
             $scope.deleteImage = function (event) {
                 event.preventDefault();
                 var force = $scope.dependantPages !== false;
             $scope.deleteImage = function (event) {
                 event.preventDefault();
                 var force = $scope.dependantPages !== false;
-                var url = '/images/' + $scope.selectedImage.id;
+                var url = window.baseUrl('/images/' + $scope.selectedImage.id);
                 if (force) url += '?force=true';
                 $http.delete(url).then((response) => {
                     $scope.images.splice($scope.images.indexOf($scope.selectedImage), 1);
                 if (force) url += '?force=true';
                 $http.delete(url).then((response) => {
                     $scope.images.splice($scope.images.indexOf($scope.selectedImage), 1);
@@ -267,7 +267,7 @@ module.exports = function (ngApp, events) {
             if (term.length == 0) return;
             $scope.searching = true;
             $scope.searchResults = '';
             if (term.length == 0) return;
             $scope.searching = true;
             $scope.searchResults = '';
-            var searchUrl = '/search/book/' + $attrs.bookId;
+            var searchUrl = window.baseUrl('/search/book/' + $attrs.bookId);
             searchUrl += '?term=' + encodeURIComponent(term);
             $http.get(searchUrl).then((response) => {
                 $scope.searchResults = $sce.trustAsHtml(response.data);
             searchUrl += '?term=' + encodeURIComponent(term);
             $http.get(searchUrl).then((response) => {
                 $scope.searchResults = $sce.trustAsHtml(response.data);
@@ -368,7 +368,8 @@ module.exports = function (ngApp, events) {
 
             if (isMarkdown) data.markdown = $scope.editContent;
 
 
             if (isMarkdown) data.markdown = $scope.editContent;
 
-            $http.put('/ajax/page/' + pageId + '/save-draft', data).then((responseData) => {
+            let url = window.baseUrl('/ajax/page/' + pageId + '/save-draft');
+            $http.put(url, data).then((responseData) => {
                 var updateTime = moment.utc(moment.unix(responseData.data.timestamp)).toDate();
                 $scope.draftText = responseData.data.message + moment(updateTime).format('HH:mm');
                 if (!$scope.isNewPageDraft) $scope.isUpdateDraft = true;
                 var updateTime = moment.utc(moment.unix(responseData.data.timestamp)).toDate();
                 $scope.draftText = responseData.data.message + moment(updateTime).format('HH:mm');
                 if (!$scope.isNewPageDraft) $scope.isUpdateDraft = true;
@@ -393,7 +394,8 @@ module.exports = function (ngApp, events) {
          * content from the system via an AJAX request.
          */
         $scope.discardDraft = function () {
          * content from the system via an AJAX request.
          */
         $scope.discardDraft = function () {
-            $http.get('/ajax/page/' + pageId).then((responseData) => {
+            let url = window.baseUrl('/ajax/page/' + pageId);
+            $http.get(url).then((responseData) => {
                 if (autoSave) $interval.cancel(autoSave);
                 $scope.draftText = 'Editing Page';
                 $scope.isUpdateDraft = false;
                 if (autoSave) $interval.cancel(autoSave);
                 $scope.draftText = 'Editing Page';
                 $scope.isUpdateDraft = false;
@@ -437,7 +439,8 @@ module.exports = function (ngApp, events) {
              * Get all tags for the current book and add into scope.
              */
             function getTags() {
              * Get all tags for the current book and add into scope.
              */
             function getTags() {
-                $http.get('/ajax/tags/get/page/' + pageId).then((responseData) => {
+                let url = window.baseUrl('/ajax/tags/get/page/' + pageId);
+                $http.get(url).then((responseData) => {
                     $scope.tags = responseData.data;
                     addEmptyTag();
                 });
                     $scope.tags = responseData.data;
                     addEmptyTag();
                 });
@@ -486,7 +489,8 @@ module.exports = function (ngApp, events) {
             $scope.saveTags = function() {
                 setTagOrder();
                 let postData = {tags: $scope.tags};
             $scope.saveTags = function() {
                 setTagOrder();
                 let postData = {tags: $scope.tags};
-                $http.post('/ajax/tags/update/page/' + pageId, postData).then((responseData) => {
+                let url = window.baseUrl('/ajax/tags/update/page/' + pageId);
+                $http.post(url, postData).then((responseData) => {
                     $scope.tags = responseData.data.tags;
                     addEmptyTag();
                     events.emit('success', responseData.data.message);
                     $scope.tags = responseData.data.tags;
                     addEmptyTag();
                     events.emit('success', responseData.data.message);
index 8554da9f8d2b70f6a81c6989d858277a94b58d92..897707af56df79481ff61df42e873fed75324598 100644 (file)
@@ -1,10 +1,10 @@
 "use strict";
 "use strict";
-var DropZone = require('dropzone');
-var markdown = require('marked');
+const DropZone = require('dropzone');
+const markdown = require('marked');
 
 
-var toggleSwitchTemplate = require('./components/toggle-switch.html');
-var imagePickerTemplate = require('./components/image-picker.html');
-var dropZoneTemplate = require('./components/drop-zone.html');
+const toggleSwitchTemplate = require('./components/toggle-switch.html');
+const imagePickerTemplate = require('./components/image-picker.html');
+const dropZoneTemplate = require('./components/drop-zone.html');
 
 module.exports = function (ngApp, events) {
 
 
 module.exports = function (ngApp, events) {
 
@@ -54,7 +54,7 @@ module.exports = function (ngApp, events) {
                 imageClass: '@'
             },
             link: function (scope, element, attrs) {
                 imageClass: '@'
             },
             link: function (scope, element, attrs) {
-                var usingIds = typeof scope.currentId !== 'undefined' || scope.currentId === 'false';
+                let usingIds = typeof scope.currentId !== 'undefined' || scope.currentId === 'false';
                 scope.image = scope.currentImage;
                 scope.value = scope.currentImage || '';
                 if (usingIds) scope.value = scope.currentId;
                 scope.image = scope.currentImage;
                 scope.value = scope.currentImage || '';
                 if (usingIds) scope.value = scope.currentId;
@@ -80,7 +80,7 @@ module.exports = function (ngApp, events) {
                 };
 
                 scope.updateImageFromModel = function (model) {
                 };
 
                 scope.updateImageFromModel = function (model) {
-                    var isResized = scope.resizeWidth && scope.resizeHeight;
+                    let isResized = scope.resizeWidth && scope.resizeHeight;
 
                     if (!isResized) {
                         scope.$apply(() => {
 
                     if (!isResized) {
                         scope.$apply(() => {
@@ -89,8 +89,9 @@ module.exports = function (ngApp, events) {
                         return;
                     }
 
                         return;
                     }
 
-                    var cropped = scope.resizeCrop ? 'true' : 'false';
-                    var requestString = '/images/thumb/' + model.id + '/' + scope.resizeWidth + '/' + scope.resizeHeight + '/' + cropped;
+                    let cropped = scope.resizeCrop ? 'true' : 'false';
+                    let requestString = '/images/thumb/' + model.id + '/' + scope.resizeWidth + '/' + scope.resizeHeight + '/' + cropped;
+                    requestString = window.baseUrl(requestString);
                     $http.get(requestString).then((response) => {
                         setImage(model, response.data.url);
                     });
                     $http.get(requestString).then((response) => {
                         setImage(model, response.data.url);
                     });
@@ -332,9 +333,9 @@ module.exports = function (ngApp, events) {
                     // Insert image shortcut
                     if (event.which === 73 && event.ctrlKey && event.shiftKey) {
                         event.preventDefault();
                     // Insert image shortcut
                     if (event.which === 73 && event.ctrlKey && event.shiftKey) {
                         event.preventDefault();
-                        var caretPos = input[0].selectionStart;
-                        var currentContent = input.val();
-                        var mdImageText = "![](http://)";
+                        let caretPos = input[0].selectionStart;
+                        let currentContent = input.val();
+                        const mdImageText = "![](http://)";
                         input.val(currentContent.substring(0, caretPos) + mdImageText + currentContent.substring(caretPos));
                         input.focus();
                         input[0].selectionStart = caretPos + ("![](".length);
                         input.val(currentContent.substring(0, caretPos) + mdImageText + currentContent.substring(caretPos));
                         input.focus();
                         input[0].selectionStart = caretPos + ("![](".length);
@@ -348,9 +349,9 @@ module.exports = function (ngApp, events) {
                 // Insert image from image manager
                 insertImage.click(event => {
                     window.ImageManager.showExternal(image => {
                 // Insert image from image manager
                 insertImage.click(event => {
                     window.ImageManager.showExternal(image => {
-                        var caretPos = currentCaretPos;
-                        var currentContent = input.val();
-                        var mdImageText = "![" + image.name + "](" + image.url + ")";
+                        let caretPos = currentCaretPos;
+                        let currentContent = input.val();
+                        let mdImageText = "![" + image.name + "](" + image.url + ")";
                         input.val(currentContent.substring(0, caretPos) + mdImageText + currentContent.substring(caretPos));
                         input.change();
                     });
                         input.val(currentContent.substring(0, caretPos) + mdImageText + currentContent.substring(caretPos));
                         input.change();
                     });
@@ -624,7 +625,7 @@ module.exports = function (ngApp, events) {
                 // Get search url with correct types
                 function getSearchUrl() {
                     let types = (attrs.entityTypes) ? encodeURIComponent(attrs.entityTypes) : encodeURIComponent('page,book,chapter');
                 // Get search url with correct types
                 function getSearchUrl() {
                     let types = (attrs.entityTypes) ? encodeURIComponent(attrs.entityTypes) : encodeURIComponent('page,book,chapter');
-                    return `/ajax/search/entities?types=${types}`;
+                    return window.baseUrl(`/ajax/search/entities?types=${types}`);
                 }
 
                 // Get initial contents
                 }
 
                 // Get initial contents
index 44562abd03806b7742e49d29112c45e87d11ba40..1c300ad26b209a671146bc657e2176308823c2bb 100644 (file)
@@ -7,6 +7,14 @@ var ngAnimate = require('angular-animate');
 var ngSanitize = require('angular-sanitize');
 require('angular-ui-sortable');
 
 var ngSanitize = require('angular-sanitize');
 require('angular-ui-sortable');
 
+// Url retrieval function
+window.baseUrl = function(path) {
+    let basePath = document.querySelector('meta[name="base-url"]').getAttribute('content');
+    if (basePath[basePath.length-1] === '/') basePath = basePath.slice(0, basePath.length-1);
+    if (path[0] === '/') path = path.slice(1);
+    return basePath + '/' + path;
+};
+
 var ngApp = angular.module('bookStack', ['ngResource', 'ngAnimate', 'ngSanitize', 'ui.sortable']);
 
 // Global Event System
 var ngApp = angular.module('bookStack', ['ngResource', 'ngAnimate', 'ngSanitize', 'ui.sortable']);
 
 // Global Event System
@@ -29,6 +37,7 @@ var Events = {
 };
 window.Events = Events;
 
 };
 window.Events = Events;
 
+
 var services = require('./services')(ngApp, Events);
 var directives = require('./directives')(ngApp, Events);
 var controllers = require('./controllers')(ngApp, Events);
 var services = require('./services')(ngApp, Events);
 var directives = require('./directives')(ngApp, Events);
 var controllers = require('./controllers')(ngApp, Events);
index 611d2e78298b0445b277aa29ef187462854db4bb..f8b314e9cb914e49ddbc214054af04988d086237 100644 (file)
@@ -1,8 +1,8 @@
 var mceOptions = module.exports = {
     selector: '#html-editor',
     content_css: [
 var mceOptions = module.exports = {
     selector: '#html-editor',
     content_css: [
-        '/css/styles.css',
-        '/libs/material-design-iconic-font/css/material-design-iconic-font.min.css'
+        window.baseUrl('/css/styles.css'),
+        window.baseUrl('/libs/material-design-iconic-font/css/material-design-iconic-font.min.css')
     ],
     body_class: 'page-content',
     relative_urls: false,
     ],
     body_class: 'page-content',
     relative_urls: false,
@@ -148,7 +148,7 @@ var mceOptions = module.exports = {
                             formData.append('file', file, remoteFilename);
                             formData.append('_token', document.querySelector('meta[name="token"]').getAttribute('content'));
 
                             formData.append('file', file, remoteFilename);
                             formData.append('_token', document.querySelector('meta[name="token"]').getAttribute('content'));
 
-                            xhr.open('POST', '/images/gallery/upload');
+                            xhr.open('POST', window.baseUrl('/images/gallery/upload'));
                             xhr.onload = function () {
                                 if (xhr.status === 200 || xhr.status === 201) {
                                     var result = JSON.parse(xhr.responseText);
                             xhr.onload = function () {
                                 if (xhr.status === 200 || xhr.status === 201) {
                                     var result = JSON.parse(xhr.responseText);
index b037612bec540354ff78ba9635e0f892d8f93fa1..41b92453f6cc785f1fb79c404b6c5eb071839fa7 100644 (file)
@@ -2,7 +2,7 @@
 // Configure ZeroClipboard
 var zeroClipBoard = require('zeroclipboard');
 zeroClipBoard.config({
 // Configure ZeroClipboard
 var zeroClipBoard = require('zeroclipboard');
 zeroClipBoard.config({
-    swfPath: '/ZeroClipboard.swf'
+    swfPath: window.baseUrl('/ZeroClipboard.swf')
 });
 
 window.setupPageShow = module.exports = function (pageId) {
 });
 
 window.setupPageShow = module.exports = function (pageId) {
@@ -36,7 +36,8 @@ window.setupPageShow = module.exports = function (pageId) {
 
         // Show pointer and set link
         var $elem = $(this);
 
         // Show pointer and set link
         var $elem = $(this);
-        var link = window.location.protocol + "//" + window.location.host + '/link/' + pageId + '#' + $elem.attr('id');
+        let link = window.baseUrl('/link/' + pageId + '#' + $elem.attr('id'));
+        if (link.indexOf('http') !== 0) link = window.location.protocol + "//" + window.location.host + link;
         $pointer.find('input').val(link);
         $pointer.find('button').first().attr('data-clipboard-text', link);
         $elem.before($pointer);
         $pointer.find('input').val(link);
         $pointer.find('button').first().attr('data-clipboard-text', link);
         $elem.before($pointer);
index c9dff31e19ad7ccfc607c1e1cd1c93c481b2e3eb..c8e8ea833482d56a751b48b925a04f2f1c35537b 100644 (file)
@@ -6,8 +6,8 @@
   font-style: normal;
   font-weight: 100;
   src: local('Roboto Thin'), local('Roboto-Thin'),
   font-style: normal;
   font-weight: 100;
   src: local('Roboto Thin'), local('Roboto-Thin'),
-  url('/fonts/roboto-v15-cyrillic_latin-100.woff2') format('woff2'), /* Chrome 26+, Opera 23+ */
-  url('/fonts/roboto-v15-cyrillic_latin-100.woff') format('woff'); /* Chrome 6+, Firefox 3.6+, IE 9+, Safari 5.1+ */
+  url('../fonts/roboto-v15-cyrillic_latin-100.woff2') format('woff2'), /* Chrome 26+, Opera 23+ */
+  url('../fonts/roboto-v15-cyrillic_latin-100.woff') format('woff'); /* Chrome 6+, Firefox 3.6+, IE 9+, Safari 5.1+ */
 }
 /* roboto-100italic - cyrillic_latin */
 @font-face {
 }
 /* roboto-100italic - cyrillic_latin */
 @font-face {
@@ -15,8 +15,8 @@
   font-style: italic;
   font-weight: 100;
   src: local('Roboto Thin Italic'), local('Roboto-ThinItalic'),
   font-style: italic;
   font-weight: 100;
   src: local('Roboto Thin Italic'), local('Roboto-ThinItalic'),
-  url('/fonts/roboto-v15-cyrillic_latin-100italic.woff2') format('woff2'), /* Chrome 26+, Opera 23+ */
-  url('/fonts/roboto-v15-cyrillic_latin-100italic.woff') format('woff'); /* Chrome 6+, Firefox 3.6+, IE 9+, Safari 5.1+ */
+  url('../fonts/roboto-v15-cyrillic_latin-100italic.woff2') format('woff2'), /* Chrome 26+, Opera 23+ */
+  url('../fonts/roboto-v15-cyrillic_latin-100italic.woff') format('woff'); /* Chrome 6+, Firefox 3.6+, IE 9+, Safari 5.1+ */
 }
 /* roboto-300 - cyrillic_latin */
 @font-face {
 }
 /* roboto-300 - cyrillic_latin */
 @font-face {
@@ -24,8 +24,8 @@
   font-style: normal;
   font-weight: 300;
   src: local('Roboto Light'), local('Roboto-Light'),
   font-style: normal;
   font-weight: 300;
   src: local('Roboto Light'), local('Roboto-Light'),
-  url('/fonts/roboto-v15-cyrillic_latin-300.woff2') format('woff2'), /* Chrome 26+, Opera 23+ */
-  url('/fonts/roboto-v15-cyrillic_latin-300.woff') format('woff'); /* Chrome 6+, Firefox 3.6+, IE 9+, Safari 5.1+ */
+  url('../fonts/roboto-v15-cyrillic_latin-300.woff2') format('woff2'), /* Chrome 26+, Opera 23+ */
+  url('../fonts/roboto-v15-cyrillic_latin-300.woff') format('woff'); /* Chrome 6+, Firefox 3.6+, IE 9+, Safari 5.1+ */
 }
 /* roboto-300italic - cyrillic_latin */
 @font-face {
 }
 /* roboto-300italic - cyrillic_latin */
 @font-face {
@@ -33,8 +33,8 @@
   font-style: italic;
   font-weight: 300;
   src: local('Roboto Light Italic'), local('Roboto-LightItalic'),
   font-style: italic;
   font-weight: 300;
   src: local('Roboto Light Italic'), local('Roboto-LightItalic'),
-  url('/fonts/roboto-v15-cyrillic_latin-300italic.woff2') format('woff2'), /* Chrome 26+, Opera 23+ */
-  url('/fonts/roboto-v15-cyrillic_latin-300italic.woff') format('woff'); /* Chrome 6+, Firefox 3.6+, IE 9+, Safari 5.1+ */
+  url('../fonts/roboto-v15-cyrillic_latin-300italic.woff2') format('woff2'), /* Chrome 26+, Opera 23+ */
+  url('../fonts/roboto-v15-cyrillic_latin-300italic.woff') format('woff'); /* Chrome 6+, Firefox 3.6+, IE 9+, Safari 5.1+ */
 }
 /* roboto-regular - cyrillic_latin */
 @font-face {
 }
 /* roboto-regular - cyrillic_latin */
 @font-face {
@@ -42,8 +42,8 @@
   font-style: normal;
   font-weight: 400;
   src: local('Roboto'), local('Roboto-Regular'),
   font-style: normal;
   font-weight: 400;
   src: local('Roboto'), local('Roboto-Regular'),
-  url('/fonts/roboto-v15-cyrillic_latin-regular.woff2') format('woff2'), /* Chrome 26+, Opera 23+ */
-  url('/fonts/roboto-v15-cyrillic_latin-regular.woff') format('woff'); /* Chrome 6+, Firefox 3.6+, IE 9+, Safari 5.1+ */
+  url('../fonts/roboto-v15-cyrillic_latin-regular.woff2') format('woff2'), /* Chrome 26+, Opera 23+ */
+  url('../fonts/roboto-v15-cyrillic_latin-regular.woff') format('woff'); /* Chrome 6+, Firefox 3.6+, IE 9+, Safari 5.1+ */
 }
 /* roboto-italic - cyrillic_latin */
 @font-face {
 }
 /* roboto-italic - cyrillic_latin */
 @font-face {
@@ -51,8 +51,8 @@
   font-style: italic;
   font-weight: 400;
   src: local('Roboto Italic'), local('Roboto-Italic'),
   font-style: italic;
   font-weight: 400;
   src: local('Roboto Italic'), local('Roboto-Italic'),
-  url('/fonts/roboto-v15-cyrillic_latin-italic.woff2') format('woff2'), /* Chrome 26+, Opera 23+ */
-  url('/fonts/roboto-v15-cyrillic_latin-italic.woff') format('woff'); /* Chrome 6+, Firefox 3.6+, IE 9+, Safari 5.1+ */
+  url('../fonts/roboto-v15-cyrillic_latin-italic.woff2') format('woff2'), /* Chrome 26+, Opera 23+ */
+  url('../fonts/roboto-v15-cyrillic_latin-italic.woff') format('woff'); /* Chrome 6+, Firefox 3.6+, IE 9+, Safari 5.1+ */
 }
 /* roboto-500 - cyrillic_latin */
 @font-face {
 }
 /* roboto-500 - cyrillic_latin */
 @font-face {
@@ -60,8 +60,8 @@
   font-style: normal;
   font-weight: 500;
   src: local('Roboto Medium'), local('Roboto-Medium'),
   font-style: normal;
   font-weight: 500;
   src: local('Roboto Medium'), local('Roboto-Medium'),
-  url('/fonts/roboto-v15-cyrillic_latin-500.woff2') format('woff2'), /* Chrome 26+, Opera 23+ */
-  url('/fonts/roboto-v15-cyrillic_latin-500.woff') format('woff'); /* Chrome 6+, Firefox 3.6+, IE 9+, Safari 5.1+ */
+  url('../fonts/roboto-v15-cyrillic_latin-500.woff2') format('woff2'), /* Chrome 26+, Opera 23+ */
+  url('../fonts/roboto-v15-cyrillic_latin-500.woff') format('woff'); /* Chrome 6+, Firefox 3.6+, IE 9+, Safari 5.1+ */
 }
 /* roboto-500italic - cyrillic_latin */
 @font-face {
 }
 /* roboto-500italic - cyrillic_latin */
 @font-face {
@@ -69,8 +69,8 @@
   font-style: italic;
   font-weight: 500;
   src: local('Roboto Medium Italic'), local('Roboto-MediumItalic'),
   font-style: italic;
   font-weight: 500;
   src: local('Roboto Medium Italic'), local('Roboto-MediumItalic'),
-  url('/fonts/roboto-v15-cyrillic_latin-500italic.woff2') format('woff2'), /* Chrome 26+, Opera 23+ */
-  url('/fonts/roboto-v15-cyrillic_latin-500italic.woff') format('woff'); /* Chrome 6+, Firefox 3.6+, IE 9+, Safari 5.1+ */
+  url('../fonts/roboto-v15-cyrillic_latin-500italic.woff2') format('woff2'), /* Chrome 26+, Opera 23+ */
+  url('../fonts/roboto-v15-cyrillic_latin-500italic.woff') format('woff'); /* Chrome 6+, Firefox 3.6+, IE 9+, Safari 5.1+ */
 }
 /* roboto-700 - cyrillic_latin */
 @font-face {
 }
 /* roboto-700 - cyrillic_latin */
 @font-face {
@@ -78,8 +78,8 @@
   font-style: normal;
   font-weight: 700;
   src: local('Roboto Bold'), local('Roboto-Bold'),
   font-style: normal;
   font-weight: 700;
   src: local('Roboto Bold'), local('Roboto-Bold'),
-  url('/fonts/roboto-v15-cyrillic_latin-700.woff2') format('woff2'), /* Chrome 26+, Opera 23+ */
-  url('/fonts/roboto-v15-cyrillic_latin-700.woff') format('woff'); /* Chrome 6+, Firefox 3.6+, IE 9+, Safari 5.1+ */
+  url('../fonts/roboto-v15-cyrillic_latin-700.woff2') format('woff2'), /* Chrome 26+, Opera 23+ */
+  url('../fonts/roboto-v15-cyrillic_latin-700.woff') format('woff'); /* Chrome 6+, Firefox 3.6+, IE 9+, Safari 5.1+ */
 }
 /* roboto-700italic - cyrillic_latin */
 @font-face {
 }
 /* roboto-700italic - cyrillic_latin */
 @font-face {
@@ -87,8 +87,8 @@
   font-style: italic;
   font-weight: 700;
   src: local('Roboto Bold Italic'), local('Roboto-BoldItalic'),
   font-style: italic;
   font-weight: 700;
   src: local('Roboto Bold Italic'), local('Roboto-BoldItalic'),
-  url('/fonts/roboto-v15-cyrillic_latin-700italic.woff2') format('woff2'), /* Chrome 26+, Opera 23+ */
-  url('/fonts/roboto-v15-cyrillic_latin-700italic.woff') format('woff'); /* Chrome 6+, Firefox 3.6+, IE 9+, Safari 5.1+ */
+  url('../fonts/roboto-v15-cyrillic_latin-700italic.woff2') format('woff2'), /* Chrome 26+, Opera 23+ */
+  url('../fonts/roboto-v15-cyrillic_latin-700italic.woff') format('woff'); /* Chrome 6+, Firefox 3.6+, IE 9+, Safari 5.1+ */
 }
 
 /* roboto-mono-regular - latin */
 }
 
 /* roboto-mono-regular - latin */
@@ -97,6 +97,6 @@
   font-style: normal;
   font-weight: 400;
   src: local('Roboto Mono'), local('RobotoMono-Regular'),
   font-style: normal;
   font-weight: 400;
   src: local('Roboto Mono'), local('RobotoMono-Regular'),
-  url('/fonts/roboto-mono-v4-latin-regular.woff2') format('woff2'), /* Chrome 26+, Opera 23+ */
-  url('/fonts/roboto-mono-v4-latin-regular.woff') format('woff'); /* Chrome 6+, Firefox 3.6+, IE 9+, Safari 5.1+ */
+  url('../fonts/roboto-mono-v4-latin-regular.woff2') format('woff2'), /* Chrome 26+, Opera 23+ */
+  url('../fonts/roboto-mono-v4-latin-regular.woff') format('woff'); /* Chrome 6+, Firefox 3.6+, IE 9+, Safari 5.1+ */
 }
\ No newline at end of file
 }
\ No newline at end of file
index d9be2935aeacd73d5963be530f2fec0201dfe8a3..abefd21a1b6cc5e6064ff61ca0b29bfac5c65893 100644 (file)
@@ -6,5 +6,5 @@
 <div class="form-group">
     <label for="password">Password</label>
     @include('form/password', ['name' => 'password', 'tabindex' => 2])
 <div class="form-group">
     <label for="password">Password</label>
     @include('form/password', ['name' => 'password', 'tabindex' => 2])
-    <span class="block small"><a href="/password/email">Forgot Password?</a></span>
+    <span class="block small"><a href="{{ baseUrl('/password/email') }}">Forgot Password?</a></span>
 </div>
\ No newline at end of file
 </div>
\ No newline at end of file
index d1239b52c5730a969e4a6d9916f42ff2bcfa4a76..4fa97c1d5bba0b0303c2ec56cf675ea0e890b2bb 100644 (file)
@@ -1,8 +1,8 @@
 @extends('public')
 
 @section('header-buttons')
 @extends('public')
 
 @section('header-buttons')
-    @if(Setting::get('registration-enabled'))
-        <a href="/register"><i class="zmdi zmdi-account-add"></i>Sign up</a>
+    @if(setting('registration-enabled', false))
+        <a href="{{ baseUrl("/register") }}"><i class="zmdi zmdi-account-add"></i>Sign up</a>
     @endif
 @stop
 
     @endif
 @stop
 
@@ -12,7 +12,7 @@
         <div class="center-box">
             <h1>Log In</h1>
 
         <div class="center-box">
             <h1>Log In</h1>
 
-            <form action="/login" method="POST" id="login-form">
+            <form action="{{ baseUrl("/login") }}" method="POST" id="login-form">
                 {!! csrf_field() !!}
 
 
                 {!! csrf_field() !!}
 
 
                 <hr class="margin-top">
                 <h3 class="text-muted">Social Login</h3>
                 @if(isset($socialDrivers['google']))
                 <hr class="margin-top">
                 <h3 class="text-muted">Social Login</h3>
                 @if(isset($socialDrivers['google']))
-                    <a href="/login/service/google" style="color: #DC4E41;"><i class="zmdi zmdi-google-plus-box zmdi-hc-4x"></i></a>
+                    <a href="{{ baseUrl("/login/service/google") }}" style="color: #DC4E41;"><i class="zmdi zmdi-google-plus-box zmdi-hc-4x"></i></a>
                 @endif
                 @if(isset($socialDrivers['github']))
                 @endif
                 @if(isset($socialDrivers['github']))
-                    <a href="/login/service/github" style="color:#444;"><i class="zmdi zmdi-github zmdi-hc-4x"></i></a>
+                    <a href="{{ baseUrl("/login/service/github") }}" style="color:#444;"><i class="zmdi zmdi-github zmdi-hc-4x"></i></a>
                 @endif
             @endif
         </div>
                 @endif
             @endif
         </div>
index d3ea08e1c257686340d4a9d6a197ad3176d9935f..d8536efa723bebef008e1feb194c682fd773a394 100644 (file)
@@ -1,7 +1,5 @@
 @extends('public')
 
 @extends('public')
 
-@section('body-class', 'image-cover login')
-
 @section('content')
 
 
 @section('content')
 
 
@@ -11,7 +9,7 @@
 
             <p class="muted small">Enter your email below and you will be sent an email with a password reset link.</p>
 
 
             <p class="muted small">Enter your email below and you will be sent an email with a password reset link.</p>
 
-            <form action="/password/email" method="POST">
+            <form action="{{ baseUrl("/password/email") }}" method="POST">
                 {!! csrf_field() !!}
 
                 <div class="form-group">
                 {!! csrf_field() !!}
 
                 <div class="form-group">
index 2f70b9ffdc3a41b6808035058eaaf6d7c91c4d47..97fd65ab51238f3df8e6ceca5c0b9593dcc37b0f 100644 (file)
@@ -2,7 +2,7 @@
 
 @section('header-buttons')
     @if(!$signedIn)
 
 @section('header-buttons')
     @if(!$signedIn)
-        <a href="/login"><i class="zmdi zmdi-sign-in"></i>Sign in</a>
+        <a href="{{ baseUrl("/login") }}"><i class="zmdi zmdi-sign-in"></i>Sign in</a>
     @endif
 @stop
 
     @endif
 @stop
 
@@ -11,7 +11,7 @@
     <div class="text-center">
         <div class="center-box">
             <h2>Thanks for registering!</h2>
     <div class="text-center">
         <div class="center-box">
             <h2>Thanks for registering!</h2>
-            <p>Please check your email and click the confirmation button to access {{ \Setting::get('app-name') }}.</p>
+            <p>Please check your email and click the confirmation button to access {{ setting('app-name', 'BookStack') }}.</p>
         </div>
     </div>
 
         </div>
     </div>
 
index f85440e7f7cf666c2e83cb1cc648d5913712c003..8ae5fcf5067725e00c64d30867fd163db3dbf807 100644 (file)
@@ -1,7 +1,7 @@
 @extends('public')
 
 @section('header-buttons')
 @extends('public')
 
 @section('header-buttons')
-    <a href="/login"><i class="zmdi zmdi-sign-in"></i>Sign in</a>
+    <a href="{{ baseUrl("/login") }}"><i class="zmdi zmdi-sign-in"></i>Sign in</a>
 @stop
 
 @section('content')
 @stop
 
 @section('content')
@@ -10,7 +10,7 @@
         <div class="center-box">
             <h1>Sign Up</h1>
 
         <div class="center-box">
             <h1>Sign Up</h1>
 
-            <form action="/register" method="POST">
+            <form action="{{ baseUrl("/register") }}" method="POST">
                 {!! csrf_field() !!}
 
                 <div class="form-group">
                 {!! csrf_field() !!}
 
                 <div class="form-group">
                 <h3 class="text-muted">Social Registration</h3>
                 <p class="text-small">Register and sign in using another service.</p>
                 @if(isset($socialDrivers['google']))
                 <h3 class="text-muted">Social Registration</h3>
                 <p class="text-small">Register and sign in using another service.</p>
                 @if(isset($socialDrivers['google']))
-                    <a href="/register/service/google" style="color: #DC4E41;"><i class="zmdi zmdi-google-plus-box zmdi-hc-4x"></i></a>
+                    <a href="{{ baseUrl("/register/service/google") }}" style="color: #DC4E41;"><i class="zmdi zmdi-google-plus-box zmdi-hc-4x"></i></a>
                 @endif
                 @if(isset($socialDrivers['github']))
                 @endif
                 @if(isset($socialDrivers['github']))
-                    <a href="/register/service/github" style="color:#444;"><i class="zmdi zmdi-github zmdi-hc-4x"></i></a>
+                    <a href="{{ baseUrl("/register/service/github") }}" style="color:#444;"><i class="zmdi zmdi-github zmdi-hc-4x"></i></a>
                 @endif
             @endif
         </div>
                 @endif
             @endif
         </div>
index c440f64e7a04e154eecf9eef202fcead20ff5d8c..9a9a65ff094516af8ac142e3b898222f0c2589fd 100644 (file)
@@ -9,7 +9,7 @@
         <div class="center-box text-left">
             <h1>Reset Password</h1>
 
         <div class="center-box text-left">
             <h1>Reset Password</h1>
 
-            <form action="/password/reset" method="POST">
+            <form action="{{ baseUrl("/password/reset") }}" method="POST">
                 {!! csrf_field() !!}
                 <input type="hidden" name="token" value="{{ $token }}">
 
                 {!! csrf_field() !!}
                 <input type="hidden" name="token" value="{{ $token }}">
 
index 1b0a20a697732eb730988292b63156c6947c933b..08178e891a633b6af530601d9eb2d589f8e4dcee 100644 (file)
@@ -10,7 +10,7 @@
                 If you cannot find the email you can re-send the confirmation email by submitting the form below.
             </p>
             <hr>
                 If you cannot find the email you can re-send the confirmation email by submitting the form below.
             </p>
             <hr>
-            <form action="/register/confirm/resend" method="POST">
+            <form action="{{ baseUrl("/register/confirm/resend") }}" method="POST">
                 {!! csrf_field() !!}
                 <div class="form-group">
                     <label for="email">Email Address</label>
                 {!! csrf_field() !!}
                 <div class="form-group">
                     <label for="email">Email Address</label>
index e9ed436c5e8058b226715a381cc9ba23565307ee..be47abdcaaf3e23903c63e03884f790433d3ac6a 100644 (file)
@@ -1,11 +1,12 @@
 <!DOCTYPE html>
 <html class="@yield('body-class')">
 <head>
 <!DOCTYPE html>
 <html class="@yield('body-class')">
 <head>
-    <title>{{ isset($pageTitle) ? $pageTitle . ' | ' : '' }}{{ setting('app-name', 'BookStack') }}</title>
+    <title>{{ isset($pageTitle) ? $pageTitle . ' | ' : '' }}{{ setting('app-name') }}</title>
 
     <!-- Meta -->
     <meta name="viewport" content="width=device-width">
     <meta name="token" content="{{ csrf_token() }}">
 
     <!-- Meta -->
     <meta name="viewport" content="width=device-width">
     <meta name="token" content="{{ csrf_token() }}">
+    <meta name="base-url" content="{{ baseUrl('/') }}">
     <meta charset="utf-8">
 
     <!-- Styles and Fonts -->
     <meta charset="utf-8">
 
     <!-- Styles and Fonts -->
@@ -38,7 +39,7 @@
                         @if(setting('app-logo', '') !== 'none')
                             <img class="logo-image" src="{{ setting('app-logo', '') === '' ? baseUrl('/logo.png') : baseUrl(setting('app-logo', '')) }}" alt="Logo">
                         @endif
                         @if(setting('app-logo', '') !== 'none')
                             <img class="logo-image" src="{{ setting('app-logo', '') === '' ? baseUrl('/logo.png') : baseUrl(setting('app-logo', '')) }}" alt="Logo">
                         @endif
-                        <span class="logo-text">{{ setting('app-name', 'BookStack') }}</span>
+                        <span class="logo-text">{{ setting('app-name') }}</span>
                     </a>
                 </div>
                 <div class="col-lg-4 col-sm-3 text-center">
                     </a>
                 </div>
                 <div class="col-lg-4 col-sm-3 text-center">
index dd2de574d70b0b6ad5743dad2e82456fbb09f425..60f4f65bde588e3c00037bc65cd8fd315a92ca6d 100644 (file)
@@ -4,7 +4,7 @@
 
 <div class="container small" ng-non-bindable>
     <h1>Create New Book</h1>
 
 <div class="container small" ng-non-bindable>
     <h1>Create New Book</h1>
-    <form action="/books" method="POST">
+    <form action="{{ baseUrl("/books") }}" method="POST">
         @include('books/form')
     </form>
 </div>
         @include('books/form')
     </form>
 </div>
index 5bd8917c7c880a8267b1e3e0d977ae8b309c24c3..e67e6f459844bb24f7632cf63581ea727fe87f1c 100644 (file)
@@ -4,7 +4,7 @@
 
     <div class="container small" ng-non-bindable>
         <h1>Edit Book</h1>
 
     <div class="container small" ng-non-bindable>
         <h1>Edit Book</h1>
-        <form action="/books/{{$book->slug}}" method="POST">
+        <form action="{{ $book->getUrl() }}" method="POST">
             <input type="hidden" name="_method" value="PUT">
             @include('books/form', ['model' => $book])
         </form>
             <input type="hidden" name="_method" value="PUT">
             @include('books/form', ['model' => $book])
         </form>
index 7b5c92b5a9dfd0d5f0f9b399c925ff507737f813..91906e7b809650ec9c06cd49352155074cf5879a 100644 (file)
@@ -9,7 +9,7 @@
                 <div class="col-xs-11 faded">
                     <div class="action-buttons">
                         @if($currentUser->can('book-create-all'))
                 <div class="col-xs-11 faded">
                     <div class="action-buttons">
                         @if($currentUser->can('book-create-all'))
-                            <a href="/books/create" class="text-pos text-button"><i class="zmdi zmdi-plus"></i>Add new book</a>
+                            <a href="{{ baseUrl("/books/create") }}" class="text-pos text-button"><i class="zmdi zmdi-plus"></i>Add new book</a>
                         @endif
                     </div>
                 </div>
                         @endif
                     </div>
                 </div>
@@ -31,7 +31,7 @@
                 @else
                     <p class="text-muted">No books have been created.</p>
                     @if(userCan('books-create-all'))
                 @else
                     <p class="text-muted">No books have been created.</p>
                     @if(userCan('books-create-all'))
-                        <a href="/books/create" class="text-pos"><i class="zmdi zmdi-edit"></i>Create one now</a>
+                        <a href="{{ baseUrl("/books/create") }}" class="text-pos"><i class="zmdi zmdi-edit"></i>Create one now</a>
                     @endif
                 @endif
             </div>
                     @endif
                 @endif
             </div>
index 12c36ba419b4a27d3e68304c48bebf1b8bf5afe3..129851d5e78ce2f725be11712c9b034b1928600e 100644 (file)
@@ -8,10 +8,10 @@
                 <div class="col-md-12">
                     <div class="action-buttons faded">
                         @if(userCan('page-create', $book))
                 <div class="col-md-12">
                     <div class="action-buttons faded">
                         @if(userCan('page-create', $book))
-                            <a href="{{$book->getUrl() . '/page/create'}}" class="text-pos text-button"><i class="zmdi zmdi-plus"></i> New Page</a>
+                            <a href="{{ $book->getUrl('/page/create') }}" class="text-pos text-button"><i class="zmdi zmdi-plus"></i> New Page</a>
                         @endif
                         @if(userCan('chapter-create', $book))
                         @endif
                         @if(userCan('chapter-create', $book))
-                            <a href="{{$book->getUrl() . '/chapter/create'}}" class="text-pos text-button"><i class="zmdi zmdi-plus"></i> New Chapter</a>
+                            <a href="{{ $book->getUrl('/chapter/create') }}" class="text-pos text-button"><i class="zmdi zmdi-plus"></i> New Chapter</a>
                         @endif
                         @if(userCan('book-update', $book))
                             <a href="{{$book->getEditUrl()}}" class="text-primary text-button"><i class="zmdi zmdi-edit"></i>Edit</a>
                         @endif
                         @if(userCan('book-update', $book))
                             <a href="{{$book->getEditUrl()}}" class="text-primary text-button"><i class="zmdi zmdi-edit"></i>Edit</a>
                                 <a dropdown-toggle class="text-primary text-button"><i class="zmdi zmdi-more-vert"></i></a>
                                 <ul>
                                     @if(userCan('book-update', $book))
                                 <a dropdown-toggle class="text-primary text-button"><i class="zmdi zmdi-more-vert"></i></a>
                                 <ul>
                                     @if(userCan('book-update', $book))
-                                        <li><a href="{{ $book->getUrl() }}/sort" class="text-primary"><i class="zmdi zmdi-sort"></i>Sort</a></li>
+                                        <li><a href="{{ $book->getUrl('/sort') }}" class="text-primary"><i class="zmdi zmdi-sort"></i>Sort</a></li>
                                     @endif
                                     @if(userCan('restrictions-manage', $book))
                                     @endif
                                     @if(userCan('restrictions-manage', $book))
-                                        <li><a href="{{$book->getUrl()}}/permissions" class="text-primary"><i class="zmdi zmdi-lock-outline"></i>Permissions</a></li>
+                                        <li><a href="{{ $book->getUrl('/permissions') }}" class="text-primary"><i class="zmdi zmdi-lock-outline"></i>Permissions</a></li>
                                     @endif
                                     @if(userCan('book-delete', $book))
                                     @endif
                                     @if(userCan('book-delete', $book))
-                                        <li><a href="{{ $book->getUrl() }}/delete" class="text-neg"><i class="zmdi zmdi-delete"></i>Delete</a></li>
+                                        <li><a href="{{ $book->getUrl('/delete') }}" class="text-neg"><i class="zmdi zmdi-delete"></i>Delete</a></li>
                                     @endif
                                 </ul>
                             </div>
                                     @endif
                                 </ul>
                             </div>
                         @else
                             <p class="text-muted">No pages or chapters have been created for this book.</p>
                             <p>
                         @else
                             <p class="text-muted">No pages or chapters have been created for this book.</p>
                             <p>
-                                <a href="{{$book->getUrl() . '/page/create'}}" class="text-page"><i class="zmdi zmdi-file-text"></i>Create a new page</a>
+                                <a href="{{ $book->getUrl('/page/create') }}" class="text-page"><i class="zmdi zmdi-file-text"></i>Create a new page</a>
                                 &nbsp;&nbsp;<em class="text-muted">-or-</em>&nbsp;&nbsp;&nbsp;
                                 &nbsp;&nbsp;<em class="text-muted">-or-</em>&nbsp;&nbsp;&nbsp;
-                                <a href="{{$book->getUrl() . '/chapter/create'}}" class="text-chapter"><i class="zmdi zmdi-collection-bookmark"></i>Add a chapter</a>
+                                <a href="{{ $book->getUrl('/chapter/create') }}" class="text-chapter"><i class="zmdi zmdi-collection-bookmark"></i>Add a chapter</a>
                             </p>
                             <hr>
                         @endif
                         <p class="text-muted small">
                             </p>
                             <hr>
                         @endif
                         <p class="text-muted small">
-                            Created {{$book->created_at->diffForHumans()}} @if($book->createdBy) by <a href="/user/{{ $book->createdBy->id }}">{{$book->createdBy->name}}</a> @endif
+                            Created {{$book->created_at->diffForHumans()}} @if($book->createdBy) by <a href="{{ $book->createdBy->getProfileUrl() }}">{{$book->createdBy->name}}</a> @endif
                             <br>
                             <br>
-                            Last Updated {{$book->updated_at->diffForHumans()}} @if($book->updatedBy) by <a href="/user/{{ $book->updatedBy->id }}">{{$book->updatedBy->name}}</a> @endif
+                            Last Updated {{$book->updated_at->diffForHumans()}} @if($book->updatedBy) by <a href="{{ $book->updatedBy->getProfileUrl() }}">{{$book->updatedBy->name}}</a> @endif
                         </p>
                     </div>
                 </div>
                         </p>
                     </div>
                 </div>
@@ -90,7 +90,7 @@
                 @if($book->restricted)
                     <p class="text-muted">
                         @if(userCan('restrictions-manage', $book))
                 @if($book->restricted)
                     <p class="text-muted">
                         @if(userCan('restrictions-manage', $book))
-                            <a href="{{ $book->getUrl() }}/permissions"><i class="zmdi zmdi-lock-outline"></i>Book Permissions Active</a>
+                            <a href="{{ $book->getUrl('/permissions') }}"><i class="zmdi zmdi-lock-outline"></i>Book Permissions Active</a>
                         @else
                             <i class="zmdi zmdi-lock-outline"></i>Book Permissions Active
                         @endif
                         @else
                             <i class="zmdi zmdi-lock-outline"></i>Book Permissions Active
                         @endif
index af4f1825bb9d0579e9b6cf15c7a8168cc6c63a7d..3849dfcfce5f0de8f3a0d019cd7d570a39fdcb58 100644 (file)
@@ -1,7 +1,7 @@
 @extends('base')
 
 @section('head')
 @extends('base')
 
 @section('head')
-    <script src="/libs/jquery-sortable/jquery-sortable.min.js"></script>
+    <script src="{{ baseUrl("/libs/jquery-sortable/jquery-sortable.min.js") }}"></script>
 @stop
 
 @section('content')
 @stop
 
 @section('content')
@@ -22,7 +22,7 @@
                     @foreach($books as $otherBook)
                         @if($otherBook->id !== $book->id)
                         <div>
                     @foreach($books as $otherBook)
                         @if($otherBook->id !== $book->id)
                         <div>
-                            <a href="/books/{{ $otherBook->slug }}/sort-item" class="text-book"><i class="zmdi zmdi-book"></i>{{ $otherBook->name }}</a>
+                            <a href="{{ $otherBook->getUrl('/sort-item') }}" class="text-book"><i class="zmdi zmdi-book"></i>{{ $otherBook->name }}</a>
                         </div>
                         @endif
                     @endforeach
                         </div>
                         @endif
                     @endforeach
 
         </div>
 
 
         </div>
 
-        <form action="{{$book->getUrl()}}/sort" method="POST">
+        <form action="{{ $book->getUrl('/sort') }}" method="POST">
             {!! csrf_field() !!}
             <input type="hidden" name="_method" value="PUT">
             <input type="hidden" id="sort-tree-input" name="sort-tree">
             <div class="list">
             {!! csrf_field() !!}
             <input type="hidden" name="_method" value="PUT">
             <input type="hidden" id="sort-tree-input" name="sort-tree">
             <div class="list">
-                <a href="{{$book->getUrl()}}" class="button muted">Cancel</a>
+                <a href="{{ $book->getUrl() }}" class="button muted">Cancel</a>
                 <button class="button pos" type="submit">Save Order</button>
             </div>
         </form>
                 <button class="button pos" type="submit">Save Order</button>
             </div>
         </form>
index 7195e76fc2aa8caf4aaa56105ee714f404dfee2f..b81cb15d7956054971fd7e32f307d8a7ad50837f 100644 (file)
@@ -4,7 +4,7 @@
 
     <div class="container small" ng-non-bindable>
         <h1>Create New Chapter</h1>
 
     <div class="container small" ng-non-bindable>
         <h1>Create New Chapter</h1>
-        <form action="{{$book->getUrl()}}/chapter/create" method="POST">
+        <form action="{{ $book->getUrl('/chapter/create') }}" method="POST">
             @include('chapters/form')
         </form>
     </div>
             @include('chapters/form')
         </form>
     </div>
index ac7c7ccde36697b1a86b915e97e7fd63dc62f5e8..e9573f22843820a87f775f0882817b5a716bf408 100644 (file)
@@ -8,10 +8,10 @@
         and added directly to the book.</p>
         <p class="text-neg">Are you sure you want to delete this chapter?</p>
 
         and added directly to the book.</p>
         <p class="text-neg">Are you sure you want to delete this chapter?</p>
 
-        <form action="{{$chapter->getUrl()}}" method="POST">
+        <form action="{{ $chapter->getUrl() }}" method="POST">
             {!! csrf_field() !!}
             <input type="hidden" name="_method" value="DELETE">
             {!! csrf_field() !!}
             <input type="hidden" name="_method" value="DELETE">
-            <a href="{{$chapter->getUrl()}}" class="button primary">Cancel</a>
+            <a href="{{ $chapter->getUrl() }}" class="button primary">Cancel</a>
             <button type="submit" class="button neg">Confirm</button>
         </form>
     </div>
             <button type="submit" class="button neg">Confirm</button>
         </form>
     </div>
index aa76d5ca78e7d939e855bf3326d67815df528961..0363da96d7817fc777641eb2380d27694cf7ca19 100644 (file)
@@ -4,7 +4,7 @@
 
     <div class="container small" ng-non-bindable>
         <h1>Edit Chapter</h1>
 
     <div class="container small" ng-non-bindable>
         <h1>Edit Chapter</h1>
-        <form action="{{$chapter->getUrl()}}" method="POST">
+        <form action="{{  $chapter->getUrl() }}" method="POST">
             <input type="hidden" name="_method" value="PUT">
             @include('chapters/form', ['model' => $chapter])
         </form>
             <input type="hidden" name="_method" value="PUT">
             @include('chapters/form', ['model' => $chapter])
         </form>
index 1567557d2cef48f6bdf8d77ce3047ba3f993d415..3677851df77dc712b0faa200de480e0b757c0cf2 100644 (file)
@@ -20,7 +20,7 @@
         <p class="text-muted chapter-toggle"><i class="zmdi zmdi-caret-right"></i> <i class="zmdi zmdi-file-text"></i> <span>{{ count($chapter->pages) }} Pages</span></p>
         <div class="inset-list">
             @foreach($chapter->pages as $page)
         <p class="text-muted chapter-toggle"><i class="zmdi zmdi-caret-right"></i> <i class="zmdi zmdi-file-text"></i> <span>{{ count($chapter->pages) }} Pages</span></p>
         <div class="inset-list">
             @foreach($chapter->pages as $page)
-                <h4 class="@if($page->draft) draft @endif"><a href="{{$page->getUrl()}}" class="text-page @if($page->draft) draft @endif"><i class="zmdi zmdi-file-text"></i>{{$page->name}}</a></h4>
+                <h4 class="@if($page->draft) draft @endif"><a href="{{ $page->getUrl() }}" class="text-page @if($page->draft) draft @endif"><i class="zmdi zmdi-file-text"></i>{{$page->name}}</a></h4>
             @endforeach
         </div>
     @endif
             @endforeach
         </div>
     @endif
index c14dd692324549e6eac2650b34b35daf69fc1272..37d56d30dd0e243dae4ea94fc4fea6afac45bbef 100644 (file)
@@ -7,9 +7,9 @@
             <div class="row">
                 <div class="col-sm-12 faded">
                     <div class="breadcrumbs">
             <div class="row">
                 <div class="col-sm-12 faded">
                     <div class="breadcrumbs">
-                        <a href="{{$book->getUrl()}}" class="text-book text-button"><i class="zmdi zmdi-book"></i>{{ $book->getShortName() }}</a>
+                        <a href="{{ $book->getUrl() }}" class="text-book text-button"><i class="zmdi zmdi-book"></i>{{ $book->getShortName() }}</a>
                         <span class="sep">&raquo;</span>
                         <span class="sep">&raquo;</span>
-                        <a href="{{$chapter->getUrl()}}" class="text-chapter text-button"><i class="zmdi zmdi-collection-bookmark"></i>{{ $chapter->getShortName() }}</a>
+                        <a href="{{ $chapter->getUrl() }}" class="text-chapter text-button"><i class="zmdi zmdi-collection-bookmark"></i>{{ $chapter->getShortName() }}</a>
                     </div>
                 </div>
             </div>
                     </div>
                 </div>
             </div>
@@ -19,7 +19,7 @@
     <div class="container">
         <h1>Move Chapter <small class="subheader">{{$chapter->name}}</small></h1>
 
     <div class="container">
         <h1>Move Chapter <small class="subheader">{{$chapter->name}}</small></h1>
 
-        <form action="{{ $chapter->getUrl() }}/move" method="POST">
+        <form action="{{ $chapter->getUrl('/move') }}" method="POST">
             {!! csrf_field() !!}
             <input type="hidden" name="_method" value="PUT">
 
             {!! csrf_field() !!}
             <input type="hidden" name="_method" value="PUT">
 
index c25c0755db9c955f9d218885d6151bf038a67592..771665037f543492e45586683e9ead2eef97e136 100644 (file)
@@ -7,7 +7,7 @@
             <div class="row">
                 <div class="col-sm-12 faded">
                     <div class="breadcrumbs">
             <div class="row">
                 <div class="col-sm-12 faded">
                     <div class="breadcrumbs">
-                        <a href="{{$chapter->book->getUrl()}}" class="text-book text-button"><i class="zmdi zmdi-book"></i>{{ $chapter->book->getShortName() }}</a>
+                        <a href="{{ $chapter->book->getUrl() }}" class="text-book text-button"><i class="zmdi zmdi-book"></i>{{ $chapter->book->getShortName() }}</a>
                         <span class="sep">&raquo;</span>
                         <a href="{{ $chapter->getUrl() }}" class="text-chapter text-button"><i class="zmdi zmdi-collection-bookmark"></i>{{$chapter->getShortName()}}</a>
                     </div>
                         <span class="sep">&raquo;</span>
                         <a href="{{ $chapter->getUrl() }}" class="text-chapter text-button"><i class="zmdi zmdi-collection-bookmark"></i>{{$chapter->getShortName()}}</a>
                     </div>
index b79cd8415fffd8d2fd1e0d463b56fc1784d0d852..70b09e9ce49266805d650dcd6c364b4ba695cd18 100644 (file)
@@ -7,29 +7,29 @@
             <div class="row">
                 <div class="col-sm-8 faded" ng-non-bindable>
                     <div class="breadcrumbs">
             <div class="row">
                 <div class="col-sm-8 faded" ng-non-bindable>
                     <div class="breadcrumbs">
-                        <a href="{{$book->getUrl()}}" class="text-book text-button"><i class="zmdi zmdi-book"></i>{{ $book->getShortName() }}</a>
+                        <a href="{{ $book->getUrl() }}" class="text-book text-button"><i class="zmdi zmdi-book"></i>{{ $book->getShortName() }}</a>
                     </div>
                 </div>
                 <div class="col-sm-4 faded">
                     <div class="action-buttons">
                         @if(userCan('page-create', $chapter))
                     </div>
                 </div>
                 <div class="col-sm-4 faded">
                     <div class="action-buttons">
                         @if(userCan('page-create', $chapter))
-                            <a href="{{$chapter->getUrl() . '/create-page'}}" class="text-pos text-button"><i class="zmdi zmdi-plus"></i>New Page</a>
+                            <a href="{{ $chapter->getUrl('/create-page') }}" class="text-pos text-button"><i class="zmdi zmdi-plus"></i>New Page</a>
                         @endif
                         @if(userCan('chapter-update', $chapter))
                         @endif
                         @if(userCan('chapter-update', $chapter))
-                            <a href="{{$chapter->getUrl() . '/edit'}}" class="text-primary text-button"><i class="zmdi zmdi-edit"></i>Edit</a>
+                            <a href="{{ $chapter->getUrl('/edit') }}" class="text-primary text-button"><i class="zmdi zmdi-edit"></i>Edit</a>
                         @endif
                         @if(userCan('chapter-update', $chapter) || userCan('restrictions-manage', $chapter) || userCan('chapter-delete', $chapter))
                             <div dropdown class="dropdown-container">
                                 <a dropdown-toggle class="text-primary text-button"><i class="zmdi zmdi-more-vert"></i></a>
                                 <ul>
                                     @if(userCan('chapter-update', $chapter))
                         @endif
                         @if(userCan('chapter-update', $chapter) || userCan('restrictions-manage', $chapter) || userCan('chapter-delete', $chapter))
                             <div dropdown class="dropdown-container">
                                 <a dropdown-toggle class="text-primary text-button"><i class="zmdi zmdi-more-vert"></i></a>
                                 <ul>
                                     @if(userCan('chapter-update', $chapter))
-                                        <li><a href="{{$chapter->getUrl() . '/move'}}" class="text-primary"><i class="zmdi zmdi-folder"></i>Move</a></li>
+                                        <li><a href="{{ $chapter->getUrl('/move') }}" class="text-primary"><i class="zmdi zmdi-folder"></i>Move</a></li>
                                     @endif
                                     @if(userCan('restrictions-manage', $chapter))
                                     @endif
                                     @if(userCan('restrictions-manage', $chapter))
-                                        <li><a href="{{$chapter->getUrl()}}/permissions" class="text-primary"><i class="zmdi zmdi-lock-outline"></i>Permissions</a></li>
+                                        <li><a href="{{ $chapter->getUrl('/permissions') }}" class="text-primary"><i class="zmdi zmdi-lock-outline"></i>Permissions</a></li>
                                     @endif
                                     @if(userCan('chapter-delete', $chapter))
                                     @endif
                                     @if(userCan('chapter-delete', $chapter))
-                                        <li><a href="{{$chapter->getUrl() . '/delete'}}" class="text-neg"><i class="zmdi zmdi-delete"></i>Delete</a></li>
+                                        <li><a href="{{ $chapter->getUrl('/delete') }}" class="text-neg"><i class="zmdi zmdi-delete"></i>Delete</a></li>
                                     @endif
                                 </ul>
                             </div>
                                     @endif
                                 </ul>
                             </div>
                     <p class="text-muted">No pages are currently in this chapter.</p>
                     <p>
                         @if(userCan('page-create', $chapter))
                     <p class="text-muted">No pages are currently in this chapter.</p>
                     <p>
                         @if(userCan('page-create', $chapter))
-                            <a href="{{$chapter->getUrl() . '/create-page'}}" class="text-page"><i class="zmdi zmdi-file-text"></i>Create a new page</a>
+                            <a href="{{ $chapter->getUrl('/create-page') }}" class="text-page"><i class="zmdi zmdi-file-text"></i>Create a new page</a>
                         @endif
                         @if(userCan('page-create', $chapter) && userCan('book-update', $book))
                             &nbsp;&nbsp;<em class="text-muted">-or-</em>&nbsp;&nbsp;&nbsp;
                         @endif
                         @if(userCan('book-update', $book))
                         @endif
                         @if(userCan('page-create', $chapter) && userCan('book-update', $book))
                             &nbsp;&nbsp;<em class="text-muted">-or-</em>&nbsp;&nbsp;&nbsp;
                         @endif
                         @if(userCan('book-update', $book))
-                            <a href="{{$book->getUrl() . '/sort'}}" class="text-book"><i class="zmdi zmdi-book"></i>Sort the current book</a>
+                            <a href="{{ $book->getUrl('/sort') }}" class="text-book"><i class="zmdi zmdi-book"></i>Sort the current book</a>
                         @endif
                     </p>
                     <hr>
                 @endif
 
                 <p class="text-muted small">
                         @endif
                     </p>
                     <hr>
                 @endif
 
                 <p class="text-muted small">
-                    Created {{$chapter->created_at->diffForHumans()}} @if($chapter->createdBy) by <a href="/user/{{ $chapter->createdBy->id }}">{{ $chapter->createdBy->name}}</a> @endif
+                    Created {{ $chapter->created_at->diffForHumans() }} @if($chapter->createdBy) by <a href="{{ $chapter->createdBy->getProfileUrl() }}">{{ $chapter->createdBy->name}}</a> @endif
                     <br>
                     <br>
-                    Last Updated {{$chapter->updated_at->diffForHumans()}} @if($chapter->updatedBy) by <a href="/user/{{ $chapter->updatedBy->id }}">{{  $chapter->updatedBy->name}}</a> @endif
+                    Last Updated {{ $chapter->updated_at->diffForHumans() }} @if($chapter->updatedBy) by <a href="{{ $chapter->updatedBy->getProfileUrl() }}">{{  $chapter->updatedBy->name}}</a> @endif
                 </p>
             </div>
             <div class="col-md-3 col-md-offset-1">
                 </p>
             </div>
             <div class="col-md-3 col-md-offset-1">
@@ -85,7 +85,7 @@
 
                         @if($book->restricted)
                             @if(userCan('restrictions-manage', $book))
 
                         @if($book->restricted)
                             @if(userCan('restrictions-manage', $book))
-                                <a href="{{ $book->getUrl() }}/permissions"><i class="zmdi zmdi-lock-outline"></i>Book Permissions Active</a>
+                                <a href="{{ $book->getUrl('/permissions') }}"><i class="zmdi zmdi-lock-outline"></i>Book Permissions Active</a>
                             @else
                                 <i class="zmdi zmdi-lock-outline"></i>Book Permissions Active
                             @endif
                             @else
                                 <i class="zmdi zmdi-lock-outline"></i>Book Permissions Active
                             @endif
@@ -94,7 +94,7 @@
 
                         @if($chapter->restricted)
                             @if(userCan('restrictions-manage', $chapter))
 
                         @if($chapter->restricted)
                             @if(userCan('restrictions-manage', $chapter))
-                                <a href="{{ $chapter->getUrl() }}/permissions"><i class="zmdi zmdi-lock-outline"></i>Chapter Permissions Active</a>
+                                <a href="{{ $chapter->getUrl('/permissions') }}"><i class="zmdi zmdi-lock-outline"></i>Chapter Permissions Active</a>
                             @else
                                 <i class="zmdi zmdi-lock-outline"></i>Chapter Permissions Active
                             @endif
                             @else
                                 <i class="zmdi zmdi-lock-outline"></i>Chapter Permissions Active
                             @endif
index 6187100418bc5a3c4a1b1240c3c142d0a81920da..6a0dc03789e5ae07a3260fd6336f64c8f9a90fb2 100644 (file)
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml" style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;">
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
+        "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+      style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;">
 
 <head style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;">
 
 <head style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;">
-    <meta name="viewport" content="width=device-width" style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;" />
-    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;" />
-    <title>Confirm Your Email At {{ Setting::get('app-name')}}</title>
+    <meta name="viewport" content="width=device-width"
+          style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;"/>
+    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+          style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;"/>
+    <title>Confirm Your Email At {{ setting('app-name')}}</title>
     <style style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;">
         * {
     <style style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;">
         * {
-        margin: 0;
-        padding: 0;
-        font-family: "Helvetica Neue", "Helvetica", Helvetica, Arial, sans-serif;
-        font-size: 100%;
-        line-height: 1.6;
+            margin: 0;
+            padding: 0;
+            font-family: "Helvetica Neue", "Helvetica", Helvetica, Arial, sans-serif;
+            font-size: 100%;
+            line-height: 1.6;
         }
 
         img {
         }
 
         img {
-        max-width: 100%;
+            max-width: 100%;
         }
 
         body {
         }
 
         body {
-        -webkit-font-smoothing: antialiased;
-        -webkit-text-size-adjust: none;
-        width: 100%!important;
-        height: 100%;
+            -webkit-font-smoothing: antialiased;
+            -webkit-text-size-adjust: none;
+            width: 100% !important;
+            height: 100%;
         }
 
         a {
         }
 
         a {
-        color: #348eda;
+            color: #348eda;
         }
 
         .btn-primary {
         }
 
         .btn-primary {
-        text-decoration: none;
-        color: #FFF;
-        background-color: #348eda;
-        border: solid #348eda;
-        border-width: 10px 20px;
-        line-height: 2;
-        font-weight: bold;
-        margin-right: 10px;
-        text-align: center;
-        cursor: pointer;
-        display: inline-block;
-        border-radius: 4px;
+            text-decoration: none;
+            color: #FFF;
+            background-color: #348eda;
+            border: solid #348eda;
+            border-width: 10px 20px;
+            line-height: 2;
+            font-weight: bold;
+            margin-right: 10px;
+            text-align: center;
+            cursor: pointer;
+            display: inline-block;
+            border-radius: 4px;
         }
 
         .btn-secondary {
         }
 
         .btn-secondary {
-        text-decoration: none;
-        color: #FFF;
-        background-color: #aaa;
-        border: solid #aaa;
-        border-width: 10px 20px;
-        line-height: 2;
-        font-weight: bold;
-        margin-right: 10px;
-        text-align: center;
-        cursor: pointer;
-        display: inline-block;
-        border-radius: 25px;
+            text-decoration: none;
+            color: #FFF;
+            background-color: #aaa;
+            border: solid #aaa;
+            border-width: 10px 20px;
+            line-height: 2;
+            font-weight: bold;
+            margin-right: 10px;
+            text-align: center;
+            cursor: pointer;
+            display: inline-block;
+            border-radius: 25px;
         }
 
         .last {
         }
 
         .last {
-        margin-bottom: 0;
+            margin-bottom: 0;
         }
 
         .first {
         }
 
         .first {
-        margin-top: 0;
+            margin-top: 0;
         }
 
         .padding {
         }
 
         .padding {
-        padding: 10px 0;
+            padding: 10px 0;
         }
 
         table.body-wrap {
         }
 
         table.body-wrap {
-        width: 100%;
-        padding: 20px;
+            width: 100%;
+            padding: 20px;
         }
 
         table.body-wrap .container {
         }
 
         table.body-wrap .container {
-        border: 1px solid #f0f0f0;
+            border: 1px solid #f0f0f0;
         }
 
         h1,
         h2,
         h3 {
         }
 
         h1,
         h2,
         h3 {
-        font-family: "Helvetica Neue", Helvetica, Arial, "Lucida Grande", sans-serif;
-        color: #444;
-        margin: 10px 0 10px;
-        line-height: 1.2;
-        font-weight: 200;
+            font-family: "Helvetica Neue", Helvetica, Arial, "Lucida Grande", sans-serif;
+            color: #444;
+            margin: 10px 0 10px;
+            line-height: 1.2;
+            font-weight: 200;
         }
 
         h1 {
         }
 
         h1 {
-        font-size: 36px;
+            font-size: 36px;
         }
 
         h2 {
         }
 
         h2 {
-        font-size: 28px;
+            font-size: 28px;
         }
 
         h3 {
         }
 
         h3 {
-        font-size: 22px;
+            font-size: 22px;
         }
 
         p,
         ul,
         ol {
         }
 
         p,
         ul,
         ol {
-        margin-bottom: 10px;
-        font-weight: normal;
-        font-size: 14px;
-        color: #888888;
+            margin-bottom: 10px;
+            font-weight: normal;
+            font-size: 14px;
+            color: #888888;
         }
 
         ul li,
         ol li {
         }
 
         ul li,
         ol li {
-        margin-left: 5px;
-        list-style-position: inside;
+            margin-left: 5px;
+            list-style-position: inside;
         }
 
         .container {
         }
 
         .container {
-        display: block!important;
-        max-width: 600px!important;
-        margin: 0 auto!important;
-        clear: both!important;
+            display: block !important;
+            max-width: 600px !important;
+            margin: 0 auto !important;
+            clear: both !important;
         }
 
         .body-wrap .container {
         }
 
         .body-wrap .container {
-        padding: 20px;
+            padding: 20px;
         }
 
         .content {
         }
 
         .content {
-        max-width: 600px;
-        margin: 0 auto;
-        display: block;
+            max-width: 600px;
+            margin: 0 auto;
+            display: block;
         }
 
         .content table {
         }
 
         .content table {
-        width: 100%;
+            width: 100%;
         }
     </style>
         }
     </style>
-    </head>
+</head>
 
 
-    <body bgcolor="#f6f6f6" style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;-webkit-font-smoothing:antialiased;-webkit-text-size-adjust:none;width:100%!important;height:100%;">
-    <!-- body -->
-    <table class="body-wrap" bgcolor="#f6f6f6" style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;width:100%;padding-top:20px;padding-bottom:20px;padding-right:20px;padding-left:20px;">
+<body bgcolor="#f6f6f6"
+      style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;-webkit-font-smoothing:antialiased;-webkit-text-size-adjust:none;width:100%!important;height:100%;">
+<!-- body -->
+<table class="body-wrap" bgcolor="#f6f6f6"
+       style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;width:100%;padding-top:20px;padding-bottom:20px;padding-right:20px;padding-left:20px;">
     <tr style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;">
     <tr style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;">
-    <td style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;"></td>
-                                                                                                                                                                                                                                                  <td class="container" bgcolor="#FFFFFF" style="font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;display:block!important;max-width:600px!important;margin-top:0 !important;margin-bottom:0 !important;margin-right:auto !important;margin-left:auto !important;clear:both!important;padding-top:20px;padding-bottom:20px;padding-right:20px;padding-left:20px;border-width:1px;border-style:solid;border-color:#f0f0f0;">
-    <!-- content -->
-    <div class="content" style="padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;max-width:600px;margin-top:0;margin-bottom:0;margin-right:auto;margin-left:auto;display:block;">
-    <table style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;width:100%;">
-    <tr style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;">
-    <td style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;">
-    <h1 style="padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;color:#444;margin-top:10px;margin-bottom:10px;margin-right:0;margin-left:0;line-height:1.2;font-weight:200;font-size:36px;">Email Confirmation</h1>
-                                                                                                                                                                                                                                                                                                         <p style="margin-top:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;line-height:1.6;margin-bottom:10px;font-weight:normal;font-size:14px;color:#888888;">Thanks for joining <a href="{{ url('/') }}">{{ Setting::get('app-name')}}</a>. <br />
-    Please confirm your email address by clicking the button below.</p>
-                                                                     <table style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;width:100%;">
-    <tr style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;">
-    <td class="padding" style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;padding-top:10px;padding-bottom:10px;padding-right:0;padding-left:0;">
-    <p style="margin-top:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;line-height:1.6;margin-bottom:10px;font-weight:normal;font-size:14px;color:#888888;"><a class="btn-primary" href="{{ url('/register/confirm/'.$token) }}" style="margin-top:0;margin-bottom:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;text-decoration:none;color:#FFF;background-color:#348eda;border-style:solid;border-color:#348eda;border-width:10px 20px;line-height:2;font-weight:bold;margin-right:10px;text-align:center;cursor:pointer;display:inline-block;border-radius:4px;">Confirm Email</a></p>
-                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                </td>
-                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  </tr>
-                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    </table>
-                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      </td>
-                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        </tr>
-                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          </table>
-                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            </div>
-    <!-- /content -->
-    </td>
-      <td style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;"></td>
-                                                                                                                                                                                                                                                    </tr>
-                                                                                                                                                                                                                                                      </table>
-    <!-- /body -->
-    </body>
-
-      </html>
+        <td style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;"></td>
+        <td class="container" bgcolor="#FFFFFF"
+            style="font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;display:block!important;max-width:600px!important;margin-top:0 !important;margin-bottom:0 !important;margin-right:auto !important;margin-left:auto !important;clear:both!important;padding-top:20px;padding-bottom:20px;padding-right:20px;padding-left:20px;border-width:1px;border-style:solid;border-color:#f0f0f0;">
+            <!-- content -->
+            <div class="content"
+                 style="padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;max-width:600px;margin-top:0;margin-bottom:0;margin-right:auto;margin-left:auto;display:block;">
+                <table style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;width:100%;">
+                    <tr style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;">
+                        <td style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;">
+                            <h1 style="padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;color:#444;margin-top:10px;margin-bottom:10px;margin-right:0;margin-left:0;line-height:1.2;font-weight:200;font-size:36px;">
+                                Email Confirmation</h1>
+                            <p style="margin-top:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;line-height:1.6;margin-bottom:10px;font-weight:normal;font-size:14px;color:#888888;">
+                                Thanks for joining <a href="{{ baseUrl('/') }}">{{ setting('app-name')}}</a>. <br/>
+                                Please confirm your email address by clicking the button below.</p>
+                            <table style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;width:100%;">
+                                <tr style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;">
+                                    <td class="padding"
+                                        style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;padding-top:10px;padding-bottom:10px;padding-right:0;padding-left:0;">
+                                        <p style="margin-top:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;line-height:1.6;margin-bottom:10px;font-weight:normal;font-size:14px;color:#888888;">
+                                            <a class="btn-primary" href="{{ baseUrl('/register/confirm/' . $token) }}"
+                                               style="margin-top:0;margin-bottom:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;text-decoration:none;color:#FFF;background-color:#348eda;border-style:solid;border-color:#348eda;border-width:10px 20px;line-height:2;font-weight:bold;margin-right:10px;text-align:center;cursor:pointer;display:inline-block;border-radius:4px;">Confirm
+                                                Email</a></p>
+                                    </td>
+                                </tr>
+                            </table>
+                        </td>
+                    </tr>
+                </table>
+            </div>
+            <!-- /content -->
+        </td>
+        <td style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;"></td>
+    </tr>
+</table>
+<!-- /body -->
+</body>
+
+</html>
index 95fe012ebe2537ab899466603aed0186dfebce90..dfd8f3db5bed658079c0fdfc968c0b8e6494f67d 100644 (file)
@@ -1 +1 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">\r<html xmlns="http://www.w3.org/1999/xhtml" style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;">\r\r<head style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;">\r    <meta name="viewport" content="width=device-width" style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;" />\r    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;" />\r    <title>Password Reset From {{ Setting::get('app-name')}}</title>\r    <style style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;">\r        * {\r        margin: 0;\r        padding: 0;\r        font-family: "Helvetica Neue", "Helvetica", Helvetica, Arial, sans-serif;\r        font-size: 100%;\r        line-height: 1.6;\r        }\r\r        img {\r        max-width: 100%;\r        }\r\r        body {\r        -webkit-font-smoothing: antialiased;\r        -webkit-text-size-adjust: none;\r        width: 100%!important;\r        height: 100%;\r        }\r\r        a {\r        color: #348eda;\r        }\r\r        .btn-primary {\r        text-decoration: none;\r        color: #FFF;\r        background-color: #348eda;\r        border: solid #348eda;\r        border-width: 10px 20px;\r        line-height: 2;\r        font-weight: bold;\r        margin-right: 10px;\r        text-align: center;\r        cursor: pointer;\r        display: inline-block;\r        border-radius: 4px;\r        }\r\r        .btn-secondary {\r        text-decoration: none;\r        color: #FFF;\r        background-color: #aaa;\r        border: solid #aaa;\r        border-width: 10px 20px;\r        line-height: 2;\r        font-weight: bold;\r        margin-right: 10px;\r        text-align: center;\r        cursor: pointer;\r        display: inline-block;\r        border-radius: 25px;\r        }\r\r        .last {\r        margin-bottom: 0;\r        }\r\r        .first {\r        margin-top: 0;\r        }\r\r        .padding {\r        padding: 10px 0;\r        }\r\r        table.body-wrap {\r        width: 100%;\r        padding: 20px;\r        }\r\r        table.body-wrap .container {\r        border: 1px solid #f0f0f0;\r        }\r\r        h1,\r        h2,\r        h3 {\r        font-family: "Helvetica Neue", Helvetica, Arial, "Lucida Grande", sans-serif;\r        color: #444;\r        margin: 10px 0 10px;\r        line-height: 1.2;\r        font-weight: 200;\r        }\r\r        h1 {\r        font-size: 36px;\r        }\r\r        h2 {\r        font-size: 28px;\r        }\r\r        h3 {\r        font-size: 22px;\r        }\r\r        p,\r        ul,\r        ol {\r        margin-bottom: 10px;\r        font-weight: normal;\r        font-size: 14px;\r        color: #888888;\r        }\r\r        ul li,\r        ol li {\r        margin-left: 5px;\r        list-style-position: inside;\r        }\r\r        .container {\r        display: block!important;\r        max-width: 600px!important;\r        margin: 0 auto!important;\r        clear: both!important;\r        }\r\r        .body-wrap .container {\r        padding: 20px;\r        }\r\r        .content {\r        max-width: 600px;\r        margin: 0 auto;\r        display: block;\r        }\r\r        .content table {\r        width: 100%;\r        }\r    </style>\r    </head>\r\r    <body bgcolor="#f6f6f6" style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;-webkit-font-smoothing:antialiased;-webkit-text-size-adjust:none;width:100%!important;height:100%;">\r    <!-- body -->\r    <table class="body-wrap" bgcolor="#f6f6f6" style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;width:100%;padding-top:20px;padding-bottom:20px;padding-right:20px;padding-left:20px;">\r    <tr style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;">\r    <td style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;"></td>\r                                                                                                                                                                                                                                                  <td class="container" bgcolor="#FFFFFF" style="font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;display:block!important;max-width:600px!important;margin-top:0 !important;margin-bottom:0 !important;margin-right:auto !important;margin-left:auto !important;clear:both!important;padding-top:20px;padding-bottom:20px;padding-right:20px;padding-left:20px;border-width:1px;border-style:solid;border-color:#f0f0f0;">\r    <!-- content -->\r    <div class="content" style="padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;max-width:600px;margin-top:0;margin-bottom:0;margin-right:auto;margin-left:auto;display:block;">\r    <table style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;width:100%;">\r    <tr style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;">\r    <td style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;">\r    <h1 style="padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;color:#444;margin-top:10px;margin-bottom:10px;margin-right:0;margin-left:0;line-height:1.2;font-weight:200;font-size:36px;">Password Reset</h1>\r                                                                                                                                                                                                                                                                                                     <p style="margin-top:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;line-height:1.6;margin-bottom:10px;font-weight:normal;font-size:14px;color:#888888;">A password reset was requested for this email address on <a href="{{ url('/') }}">{{ Setting::get('app-name')}}</a>. If you did not request a password change please ignore this email.</p>\r                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             <table style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;width:100%;">\r    <tr style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;">\r    <td class="padding" style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;padding-top:10px;padding-bottom:10px;padding-right:0;padding-left:0;">\r    <p style="margin-top:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;line-height:1.6;margin-bottom:10px;font-weight:normal;font-size:14px;color:#888888;"><a class="btn-primary" href="{{ url('password/reset/'.$token) }}" style="margin-top:0;margin-bottom:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;text-decoration:none;color:#FFF;background-color:#348eda;border-style:solid;border-color:#348eda;border-width:10px 20px;line-height:2;font-weight:bold;margin-right:10px;text-align:center;cursor:pointer;display:inline-block;border-radius:4px;">Click here to reset your password</a></p>\r                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      </td>\r                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        </tr>\r                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          </table>\r                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            </td>\r                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              </tr>\r                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                </table>\r                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  </div>\r    <!-- /content -->\r    </td>\r      <td style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;"></td>\r                                                                                                                                                                                                                                                    </tr>\r                                                                                                                                                                                                                                                      </table>\r    <!-- /body -->\r    </body>\r\r      </html>\r
\ No newline at end of file
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"\r        "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">\r<html xmlns="http://www.w3.org/1999/xhtml"\r      style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;">\r\r<head style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;">\r    <meta name="viewport" content="width=device-width"\r          style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;"/>\r    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"\r          style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;"/>\r    <title>Password Reset From {{ setting('app-name')}}</title>\r    <style style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;">\r        * {\r            margin: 0;\r            padding: 0;\r            font-family: "Helvetica Neue", "Helvetica", Helvetica, Arial, sans-serif;\r            font-size: 100%;\r            line-height: 1.6;\r        }\r\r        img {\r            max-width: 100%;\r        }\r\r        body {\r            -webkit-font-smoothing: antialiased;\r            -webkit-text-size-adjust: none;\r            width: 100% !important;\r            height: 100%;\r        }\r\r        a {\r            color: #348eda;\r        }\r\r        .btn-primary {\r            text-decoration: none;\r            color: #FFF;\r            background-color: #348eda;\r            border: solid #348eda;\r            border-width: 10px 20px;\r            line-height: 2;\r            font-weight: bold;\r            margin-right: 10px;\r            text-align: center;\r            cursor: pointer;\r            display: inline-block;\r            border-radius: 4px;\r        }\r\r        .btn-secondary {\r            text-decoration: none;\r            color: #FFF;\r            background-color: #aaa;\r            border: solid #aaa;\r            border-width: 10px 20px;\r            line-height: 2;\r            font-weight: bold;\r            margin-right: 10px;\r            text-align: center;\r            cursor: pointer;\r            display: inline-block;\r            border-radius: 25px;\r        }\r\r        .last {\r            margin-bottom: 0;\r        }\r\r        .first {\r            margin-top: 0;\r        }\r\r        .padding {\r            padding: 10px 0;\r        }\r\r        table.body-wrap {\r            width: 100%;\r            padding: 20px;\r        }\r\r        table.body-wrap .container {\r            border: 1px solid #f0f0f0;\r        }\r\r        h1,\r        h2,\r        h3 {\r            font-family: "Helvetica Neue", Helvetica, Arial, "Lucida Grande", sans-serif;\r            color: #444;\r            margin: 10px 0 10px;\r            line-height: 1.2;\r            font-weight: 200;\r        }\r\r        h1 {\r            font-size: 36px;\r        }\r\r        h2 {\r            font-size: 28px;\r        }\r\r        h3 {\r            font-size: 22px;\r        }\r\r        p,\r        ul,\r        ol {\r            margin-bottom: 10px;\r            font-weight: normal;\r            font-size: 14px;\r            color: #888888;\r        }\r\r        ul li,\r        ol li {\r            margin-left: 5px;\r            list-style-position: inside;\r        }\r\r        .container {\r            display: block !important;\r            max-width: 600px !important;\r            margin: 0 auto !important;\r            clear: both !important;\r        }\r\r        .body-wrap .container {\r            padding: 20px;\r        }\r\r        .content {\r            max-width: 600px;\r            margin: 0 auto;\r            display: block;\r        }\r\r        .content table {\r            width: 100%;\r        }\r    </style>\r</head>\r\r<body bgcolor="#f6f6f6"\r      style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;-webkit-font-smoothing:antialiased;-webkit-text-size-adjust:none;width:100%!important;height:100%;">\r<!-- body -->\r<table class="body-wrap" bgcolor="#f6f6f6"\r       style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;width:100%;padding-top:20px;padding-bottom:20px;padding-right:20px;padding-left:20px;">\r    <tr style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;">\r        <td style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;"></td>\r        <td class="container" bgcolor="#FFFFFF"\r            style="font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;display:block!important;max-width:600px!important;margin-top:0 !important;margin-bottom:0 !important;margin-right:auto !important;margin-left:auto !important;clear:both!important;padding-top:20px;padding-bottom:20px;padding-right:20px;padding-left:20px;border-width:1px;border-style:solid;border-color:#f0f0f0;">\r            <!-- content -->\r            <div class="content"\r                 style="padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;max-width:600px;margin-top:0;margin-bottom:0;margin-right:auto;margin-left:auto;display:block;">\r                <table style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;width:100%;">\r                    <tr style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;">\r                        <td style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;">\r                            <h1 style="padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;color:#444;margin-top:10px;margin-bottom:10px;margin-right:0;margin-left:0;line-height:1.2;font-weight:200;font-size:36px;">\r                                Password Reset</h1>\r                            <p style="margin-top:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;line-height:1.6;margin-bottom:10px;font-weight:normal;font-size:14px;color:#888888;">\r                                A password reset was requested for this email address on <a\r                                        href="{{ baseUrl('/') }}">{{ setting('app-name')}}</a>. If you did not request\r                                a password change please ignore this email.</p>\r                            <table style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;width:100%;">\r                                <tr style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;">\r                                    <td class="padding"\r                                        style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;padding-top:10px;padding-bottom:10px;padding-right:0;padding-left:0;">\r                                        <p style="margin-top:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;line-height:1.6;margin-bottom:10px;font-weight:normal;font-size:14px;color:#888888;">\r                                            <a class="btn-primary" href="{{ baseUrl('/password/reset/' . $token) }}"\r                                               style="margin-top:0;margin-bottom:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;text-decoration:none;color:#FFF;background-color:#348eda;border-style:solid;border-color:#348eda;border-width:10px 20px;line-height:2;font-weight:bold;margin-right:10px;text-align:center;cursor:pointer;display:inline-block;border-radius:4px;">Click\r                                                here to reset your password</a></p>\r                                    </td>\r                                </tr>\r                            </table>\r                        </td>\r                    </tr>\r                </table>\r            </div>\r            <!-- /content -->\r        </td>\r        <td style="margin-top:0;margin-bottom:0;margin-right:0;margin-left:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;font-size:100%;line-height:1.6;"></td>\r    </tr>\r</table>\r<!-- /body -->\r</body>\r\r</html>\r
\ No newline at end of file
index a9294c7cf4cf80c0f909e03cc011c29e257611f9..19565bccbe534d13c469ecf63a8a7699211d681c 100644 (file)
@@ -6,7 +6,7 @@
 <div class="container">
     <h1 class="text-muted">{{ $message or 'Page Not Found' }}</h1>
     <p>Sorry, The page you were looking for could not be found.</p>
 <div class="container">
     <h1 class="text-muted">{{ $message or 'Page Not Found' }}</h1>
     <p>Sorry, The page you were looking for could not be found.</p>
-    <a href="/" class="button">Return To Home</a>
+    <a href="{{ baseUrl('/') }}" class="button">Return To Home</a>
 </div>
 
 @stop
\ No newline at end of file
 </div>
 
 @stop
\ No newline at end of file
index 0380666a82d6612c0ab0f5955744affb6f319e26..c79d0f68b8d877aade1b659b5904c5e6ea9c58c4 100644 (file)
@@ -1,47 +1,10 @@
-<!DOCTYPE html>
-<html>
-    <head>
-        <title>Be right back.</title>
+@extends('public')
 
 
-        <link href="//fonts.googleapis.com/css?family=Lato:100" rel="stylesheet" type="text/css">
+@section('content')
 
 
-        <style>
-            html, body {
-                height: 100%;
-            }
+    <div class="container">
+        <h1 class="text-muted">{{ setting('app-name') }} is down right now</h1>
+        <p>It will be back up soon.</p>
+    </div>
 
 
-            body {
-                margin: 0;
-                padding: 0;
-                width: 100%;
-                color: #B0BEC5;
-                display: table;
-                font-weight: 100;
-                font-family: 'Lato';
-            }
-
-            .container {
-                text-align: center;
-                display: table-cell;
-                vertical-align: middle;
-            }
-
-            .content {
-                text-align: center;
-                display: inline-block;
-            }
-
-            .title {
-                font-size: 72px;
-                margin-bottom: 40px;
-            }
-        </style>
-    </head>
-    <body>
-        <div class="container">
-            <div class="content">
-                <div class="title">Be right back.</div>
-            </div>
-        </div>
-    </body>
-</html>
+@stop
\ No newline at end of file
index f61a535e7044215b581d849c50fd43f05ad74663..7472fe65ebd1f4cbcbaf35664998ca74ce101bd9 100644 (file)
@@ -1,4 +1,4 @@
-<form action="{{ $model->getUrl() }}/permissions" method="POST">
+<form action="{{ $model->getUrl('/permissions') }}" method="POST">
     {!! csrf_field() !!}
     <input type="hidden" name="_method" value="PUT">
 
     {!! csrf_field() !!}
     <input type="hidden" name="_method" value="PUT">
 
index 88319738e1630892121da89a241ede4aaef4df81..2529c39c7f77fb81b5b3cc082ade0b2ec422bd28 100644 (file)
@@ -42,7 +42,7 @@
             </div>
 
             <div class="col-sm-4">
             </div>
 
             <div class="col-sm-4">
-                <h3><a class="no-color" href="/pages/recently-created">Recently Created Pages</a></h3>
+                <h3><a class="no-color" href="{{ baseUrl("/pages/recently-created") }}">Recently Created Pages</a></h3>
                 <div id="recently-created-pages">
                     @include('partials/entity-list', [
                     'entities' => $recentlyCreatedPages,
                 <div id="recently-created-pages">
                     @include('partials/entity-list', [
                     'entities' => $recentlyCreatedPages,
@@ -51,7 +51,7 @@
                     ])
                 </div>
 
                     ])
                 </div>
 
-                <h3><a class="no-color" href="/pages/recently-updated">Recently Updated Pages</a></h3>
+                <h3><a class="no-color" href="{{ baseUrl("/pages/recently-updated") }}">Recently Updated Pages</a></h3>
                 <div id="recently-updated-pages">
                     @include('partials/entity-list', [
                     'entities' => $recentlyUpdatedPages,
                 <div id="recently-updated-pages">
                     @include('partials/entity-list', [
                     'entities' => $recentlyUpdatedPages,
index 5a9b32c06f902d9d90213e1b9f72d5a8d8c57edd..57cc86054f3837dc70a4ee3159e136260b4f4dcd 100644 (file)
@@ -6,10 +6,10 @@
         <h1>Delete {{ $page->draft ? 'Draft' : '' }} Page</h1>
         <p class="text-neg">Are you sure you want to delete this {{ $page->draft ? 'draft' : '' }} page?</p>
 
         <h1>Delete {{ $page->draft ? 'Draft' : '' }} Page</h1>
         <p class="text-neg">Are you sure you want to delete this {{ $page->draft ? 'draft' : '' }} page?</p>
 
-        <form action="{{$page->getUrl()}}" method="POST">
+        <form action="{{ $page->getUrl() }}" method="POST">
             {!! csrf_field() !!}
             <input type="hidden" name="_method" value="DELETE">
             {!! csrf_field() !!}
             <input type="hidden" name="_method" value="DELETE">
-            <a href="{{$page->getUrl()}}" class="button primary">Cancel</a>
+            <a href="{{ $page->getUrl() }}" class="button primary">Cancel</a>
             <button type="submit" class="button neg">Confirm</button>
         </form>
     </div>
             <button type="submit" class="button neg">Confirm</button>
         </form>
     </div>
index de6051118d1ae01d79ef264aa24d03810b4cc6f4..9fe6a6a1902f6b7ccbfa7a0ba8043e04d384b1f9 100644 (file)
@@ -1,7 +1,7 @@
 @extends('base')
 
 @section('head')
 @extends('base')
 
 @section('head')
-    <script src="/libs/tinymce/tinymce.min.js?ver=4.3.7"></script>
+    <script src="{{ baseUrl('/libs/tinymce/tinymce.min.js?ver=4.3.7') }}"></script>
 @stop
 
 @section('body-class', 'flexbox')
 @stop
 
 @section('body-class', 'flexbox')
@@ -9,7 +9,7 @@
 @section('content')
 
     <div class="flex-fill flex">
 @section('content')
 
     <div class="flex-fill flex">
-        <form action="{{$page->getUrl()}}" autocomplete="off" data-page-id="{{ $page->id }}" method="POST" class="flex flex-fill">
+        <form action="{{ $page->getUrl() }}" autocomplete="off" data-page-id="{{ $page->id }}" method="POST" class="flex flex-fill">
             @if(!isset($isDraft))
                 <input type="hidden" name="_method" value="PUT">
             @endif
             @if(!isset($isDraft))
                 <input type="hidden" name="_method" value="PUT">
             @endif
index b3fcd7c13c29f8c9971a9f91095841b9c5e7a71c..a03a208b6539440cb2cdfa4b8adad76db3b63904 100644 (file)
@@ -14,8 +14,8 @@
                 <tbody ui-sortable="sortOptions" ng-model="tags" >
                     <tr ng-repeat="tag in tags track by $index">
                         <td width="20" ><i class="handle zmdi zmdi-menu"></i></td>
                 <tbody ui-sortable="sortOptions" ng-model="tags" >
                     <tr ng-repeat="tag in tags track by $index">
                         <td width="20" ><i class="handle zmdi zmdi-menu"></i></td>
-                        <td><input autosuggest="/ajax/tags/suggest/names" autosuggest-type="name" class="outline" ng-attr-name="tags[@{{$index}}][name]" type="text" ng-model="tag.name" ng-change="tagChange(tag)" ng-blur="tagBlur(tag)" placeholder="Tag"></td>
-                        <td><input autosuggest="/ajax/tags/suggest/values" autosuggest-type="value" class="outline" ng-attr-name="tags[@{{$index}}][value]" type="text" ng-model="tag.value" ng-change="tagChange(tag)" ng-blur="tagBlur(tag)" placeholder="Tag Value (Optional)"></td>
+                        <td><input autosuggest="{{ baseUrl('/ajax/tags/suggest/names') }}" autosuggest-type="name" class="outline" ng-attr-name="tags[@{{$index}}][name]" type="text" ng-model="tag.name" ng-change="tagChange(tag)" ng-blur="tagBlur(tag)" placeholder="Tag"></td>
+                        <td><input autosuggest="{{ baseUrl('/ajax/tags/suggest/values') }}" autosuggest-type="value" class="outline" ng-attr-name="tags[@{{$index}}][value]" type="text" ng-model="tag.value" ng-change="tagChange(tag)" ng-blur="tagBlur(tag)" placeholder="Tag Value (Optional)"></td>
                         <td width="10" ng-show="tags.length != 1" class="text-center text-neg" style="padding: 0;" ng-click="removeTag(tag)"><i class="zmdi zmdi-close"></i></td>
                     </tr>
                 </tbody>
                         <td width="10" ng-show="tags.length != 1" class="text-center text-neg" style="padding: 0;" ng-click="removeTag(tag)"><i class="zmdi zmdi-close"></i></td>
                     </tr>
                 </tbody>
index 6529f044b5f5b222b2ba7bdcf6a6d8bc58f7c2cb..18a9868c7aecd5734acedcb89df35aa8b063cde5 100644 (file)
@@ -20,7 +20,7 @@
                                 <a ng-click="forceDraftSave()" class="text-pos"><i class="zmdi zmdi-save"></i>Save Draft</a>
                             </li>
                             <li ng-if="isNewPageDraft">
                                 <a ng-click="forceDraftSave()" class="text-pos"><i class="zmdi zmdi-save"></i>Save Draft</a>
                             </li>
                             <li ng-if="isNewPageDraft">
-                                <a href="{{$model->getUrl()}}/delete" class="text-neg"><i class="zmdi zmdi-delete"></i>Delete Draft</a>
+                                <a href="{{ $model->getUrl('/delete') }}" class="text-neg"><i class="zmdi zmdi-delete"></i>Delete Draft</a>
                             </li>
                         </ul>
                     </div>
                             </li>
                         </ul>
                     </div>
index 27ee4cd925644d2ea32e418cd7f2a418a789ebb7..d0fae60ca4a466fc46bca89350314f02836ce891 100644 (file)
@@ -7,16 +7,16 @@
             <div class="row">
                 <div class="col-sm-12 faded">
                     <div class="breadcrumbs">
             <div class="row">
                 <div class="col-sm-12 faded">
                     <div class="breadcrumbs">
-                        <a href="{{$book->getUrl()}}" class="text-book text-button"><i class="zmdi zmdi-book"></i>{{ $book->getShortName() }}</a>
+                        <a href="{{ $book->getUrl() }}" class="text-book text-button"><i class="zmdi zmdi-book"></i>{{ $book->getShortName() }}</a>
                         @if($page->hasChapter())
                             <span class="sep">&raquo;</span>
                             <a href="{{ $page->chapter->getUrl() }}" class="text-chapter text-button">
                                 <i class="zmdi zmdi-collection-bookmark"></i>
                         @if($page->hasChapter())
                             <span class="sep">&raquo;</span>
                             <a href="{{ $page->chapter->getUrl() }}" class="text-chapter text-button">
                                 <i class="zmdi zmdi-collection-bookmark"></i>
-                                {{$page->chapter->getShortName()}}
+                                {{ $page->chapter->getShortName() }}
                             </a>
                         @endif
                         <span class="sep">&raquo;</span>
                             </a>
                         @endif
                         <span class="sep">&raquo;</span>
-                        <a href="{{$page->getUrl()}}" class="text-page text-button"><i class="zmdi zmdi-file-text"></i>{{ $page->getShortName() }}</a>
+                        <a href="{{ $page->getUrl() }}" class="text-page text-button"><i class="zmdi zmdi-file-text"></i>{{ $page->getShortName() }}</a>
                     </div>
                 </div>
             </div>
                     </div>
                 </div>
             </div>
@@ -26,7 +26,7 @@
     <div class="container">
         <h1>Move Page <small class="subheader">{{$page->name}}</small></h1>
 
     <div class="container">
         <h1>Move Page <small class="subheader">{{$page->name}}</small></h1>
 
-        <form action="{{ $page->getUrl() }}/move" method="POST">
+        <form action="{{ $page->getUrl('/move') }}" method="POST">
             {!! csrf_field() !!}
             <input type="hidden" name="_method" value="PUT">
 
             {!! csrf_field() !!}
             <input type="hidden" name="_method" value="PUT">
 
index d0bdcf88024f6e40f7227d10e5582012a9ea817b..11bcddcfcb584afa724b193fc7e89ddc9ff57d40 100644 (file)
@@ -8,8 +8,8 @@
             <table>
                 @foreach($page->tags as $tag)
                     <tr class="tag">
             <table>
                 @foreach($page->tags as $tag)
                     <tr class="tag">
-                        <td @if(!$tag->value) colspan="2" @endif><a href="/search/all?term=%5B{{ urlencode($tag->name) }}%5D">{{ $tag->name }}</a></td>
-                        @if($tag->value) <td class="tag-value"><a href="/search/all?term=%5B{{ urlencode($tag->name) }}%3D{{ urlencode($tag->value) }}%5D">{{$tag->value}}</a></td> @endif
+                        <td @if(!$tag->value) colspan="2" @endif><a href="{{ baseUrl('/search/all?term=%5B' . urlencode($tag->name) .'%5D') }}">{{ $tag->name }}</a></td>
+                        @if($tag->value) <td class="tag-value"><a href="{{ baseUrl('/search/all?term=%5B' . urlencode($tag->name) .'%3D' . urlencode($tag->value) . '%5D') }}">{{$tag->value}}</a></td> @endif
                     </tr>
                 @endforeach
             </table>
                     </tr>
                 @endforeach
             </table>
index 09eb8a65b9df0609672936e07d36f917acca9297..8eca486c3d13ca8f5bdc50cc70addc7c9f62cbbf 100644 (file)
@@ -7,16 +7,16 @@
             <div class="row">
                 <div class="col-sm-12 faded">
                     <div class="breadcrumbs">
             <div class="row">
                 <div class="col-sm-12 faded">
                     <div class="breadcrumbs">
-                        <a href="{{$page->book->getUrl()}}" class="text-book text-button"><i class="zmdi zmdi-book"></i>{{ $page->book->getShortName() }}</a>
+                        <a href="{{ $page->book->getUrl() }}" class="text-book text-button"><i class="zmdi zmdi-book"></i>{{ $page->book->getShortName() }}</a>
                         @if($page->hasChapter())
                             <span class="sep">&raquo;</span>
                             <a href="{{ $page->chapter->getUrl() }}" class="text-chapter text-button">
                                 <i class="zmdi zmdi-collection-bookmark"></i>
                         @if($page->hasChapter())
                             <span class="sep">&raquo;</span>
                             <a href="{{ $page->chapter->getUrl() }}" class="text-chapter text-button">
                                 <i class="zmdi zmdi-collection-bookmark"></i>
-                                {{$page->chapter->getShortName()}}
+                                {{ $page->chapter->getShortName() }}
                             </a>
                         @endif
                         <span class="sep">&raquo;</span>
                             </a>
                         @endif
                         <span class="sep">&raquo;</span>
-                        <a href="{{$page->getUrl()}}" class="text-book text-button"><i class="zmdi zmdi-file"></i>{{ $page->getShortName() }}</a>
+                        <a href="{{ $page->getUrl() }}" class="text-book text-button"><i class="zmdi zmdi-file"></i>{{ $page->getShortName() }}</a>
                     </div>
                 </div>
             </div>
                     </div>
                 </div>
             </div>
index a73f16a4ff8bbd882f453e1d1d38b0d0bc442028..03fb23673c09f0fd7c935fe48e1d8ce4813ce4f1 100644 (file)
@@ -7,7 +7,7 @@
             <div class="row">
                 <div class="col-md-6 faded">
                     <div class="breadcrumbs">
             <div class="row">
                 <div class="col-md-6 faded">
                     <div class="breadcrumbs">
-                        <a href="{{$page->getUrl()}}" class="text-primary text-button"><i class="zmdi zmdi-arrow-left"></i>Back to page</a>
+                        <a href="{{ $page->getUrl() }}" class="text-primary text-button"><i class="zmdi zmdi-arrow-left"></i>Back to page</a>
                     </div>
                 </div>
                 <div class="col-md-6 faded">
                     </div>
                 </div>
                 <div class="col-md-6 faded">
@@ -40,9 +40,9 @@
                         <td> @if($revision->createdBy) {{$revision->createdBy->name}} @else Deleted User @endif</td>
                         <td><small>{{$revision->created_at->format('jS F, Y H:i:s')}} <br> ({{$revision->created_at->diffForHumans()}})</small></td>
                         <td>
                         <td> @if($revision->createdBy) {{$revision->createdBy->name}} @else Deleted User @endif</td>
                         <td><small>{{$revision->created_at->format('jS F, Y H:i:s')}} <br> ({{$revision->created_at->diffForHumans()}})</small></td>
                         <td>
-                            <a href="{{$revision->getUrl()}}" target="_blank">Preview</a>
+                            <a href="{{ $revision->getUrl() }}" target="_blank">Preview</a>
                             <span class="text-muted">&nbsp;|&nbsp;</span>
                             <span class="text-muted">&nbsp;|&nbsp;</span>
-                            <a href="{{$revision->getUrl()}}/restore">Restore</a>
+                            <a href="{{ $revision->getUrl('/restore') }}">Restore</a>
                         </td>
                     </tr>
                 @endforeach
                         </td>
                     </tr>
                 @endforeach
index f12ba58c61321a9f69ec444b478d1a56a4bd2a4f..9d6b74a035afdaa6ba04e04d33152473a3a4643d 100644 (file)
@@ -7,12 +7,12 @@
             <div class="row">
                 <div class="col-sm-6 faded">
                     <div class="breadcrumbs">
             <div class="row">
                 <div class="col-sm-6 faded">
                     <div class="breadcrumbs">
-                        <a href="{{$book->getUrl()}}" class="text-book text-button"><i class="zmdi zmdi-book"></i>{{ $book->getShortName() }}</a>
+                        <a href="{{ $book->getUrl() }}" class="text-book text-button"><i class="zmdi zmdi-book"></i>{{ $book->getShortName() }}</a>
                         @if($page->hasChapter())
                             <span class="sep">&raquo;</span>
                             <a href="{{ $page->chapter->getUrl() }}" class="text-chapter text-button">
                                 <i class="zmdi zmdi-collection-bookmark"></i>
                         @if($page->hasChapter())
                             <span class="sep">&raquo;</span>
                             <a href="{{ $page->chapter->getUrl() }}" class="text-chapter text-button">
                                 <i class="zmdi zmdi-collection-bookmark"></i>
-                                {{$page->chapter->getShortName()}}
+                                {{ $page->chapter->getShortName() }}
                             </a>
                         @endif
                     </div>
                             </a>
                         @endif
                     </div>
                         <span dropdown class="dropdown-container">
                             <div dropdown-toggle class="text-button text-primary"><i class="zmdi zmdi-open-in-new"></i>Export</div>
                             <ul class="wide">
                         <span dropdown class="dropdown-container">
                             <div dropdown-toggle class="text-button text-primary"><i class="zmdi zmdi-open-in-new"></i>Export</div>
                             <ul class="wide">
-                                <li><a href="{{$page->getUrl()}}/export/html" target="_blank">Contained Web File <span class="text-muted float right">.html</span></a></li>
-                                <li><a href="{{$page->getUrl()}}/export/pdf" target="_blank">PDF File <span class="text-muted float right">.pdf</span></a></li>
-                                <li><a href="{{$page->getUrl()}}/export/plaintext" target="_blank">Plain Text File <span class="text-muted float right">.txt</span></a></li>
+                                <li><a href="{{ $page->getUrl('/export/html') }}" target="_blank">Contained Web File <span class="text-muted float right">.html</span></a></li>
+                                <li><a href="{{ $page->getUrl('/export/pdf') }}" target="_blank">PDF File <span class="text-muted float right">.pdf</span></a></li>
+                                <li><a href="{{ $page->getUrl('/export/plaintext') }}" target="_blank">Plain Text File <span class="text-muted float right">.txt</span></a></li>
                             </ul>
                         </span>
                         @if(userCan('page-update', $page))
                             </ul>
                         </span>
                         @if(userCan('page-update', $page))
-                            <a href="{{$page->getUrl()}}/edit" class="text-primary text-button" ><i class="zmdi zmdi-edit"></i>Edit</a>
+                            <a href="{{ $page->getUrl('/edit') }}" class="text-primary text-button" ><i class="zmdi zmdi-edit"></i>Edit</a>
                         @endif
                         @if(userCan('page-update', $page) || userCan('restrictions-manage', $page) || userCan('page-delete', $page))
                             <div dropdown class="dropdown-container">
                                 <a dropdown-toggle class="text-primary text-button"><i class="zmdi zmdi-more-vert"></i></a>
                                 <ul>
                                     @if(userCan('page-update', $page))
                         @endif
                         @if(userCan('page-update', $page) || userCan('restrictions-manage', $page) || userCan('page-delete', $page))
                             <div dropdown class="dropdown-container">
                                 <a dropdown-toggle class="text-primary text-button"><i class="zmdi zmdi-more-vert"></i></a>
                                 <ul>
                                     @if(userCan('page-update', $page))
-                                        <li><a href="{{$page->getUrl()}}/move" class="text-primary" ><i class="zmdi zmdi-folder"></i>Move</a></li>
-                                        <li><a href="{{$page->getUrl()}}/revisions" class="text-primary"><i class="zmdi zmdi-replay"></i>Revisions</a></li>
+                                        <li><a href="{{ $page->getUrl('/move') }}" class="text-primary" ><i class="zmdi zmdi-folder"></i>Move</a></li>
+                                        <li><a href="{{ $page->getUrl('/revisions') }}" class="text-primary"><i class="zmdi zmdi-replay"></i>Revisions</a></li>
                                     @endif
                                     @if(userCan('restrictions-manage', $page))
                                     @endif
                                     @if(userCan('restrictions-manage', $page))
-                                        <li><a href="{{$page->getUrl()}}/permissions" class="text-primary"><i class="zmdi zmdi-lock-outline"></i>Permissions</a></li>
+                                        <li><a href="{{ $page->getUrl('/permissions') }}" class="text-primary"><i class="zmdi zmdi-lock-outline"></i>Permissions</a></li>
                                     @endif
                                     @if(userCan('page-delete', $page))
                                     @endif
                                     @if(userCan('page-delete', $page))
-                                        <li><a href="{{$page->getUrl()}}/delete" class="text-neg"><i class="zmdi zmdi-delete"></i>Delete</a></li>
+                                        <li><a href="{{ $page->getUrl('/delete') }}" class="text-neg"><i class="zmdi zmdi-delete"></i>Delete</a></li>
                                     @endif
                                 </ul>
                             </div>
                                     @endif
                                 </ul>
                             </div>
                     <hr>
 
                     <p class="text-muted small">
                     <hr>
 
                     <p class="text-muted small">
-                        Created {{$page->created_at->diffForHumans()}} @if($page->createdBy) by <a href="/user/{{ $page->createdBy->id }}">{{$page->createdBy->name}}</a> @endif
+                        Created {{ $page->created_at->diffForHumans() }} @if($page->createdBy) by <a href="{{ $page->createdBy->getProfileUrl() }}">{{$page->createdBy->name}}</a> @endif
                         <br>
                         <br>
-                        Last Updated {{$page->updated_at->diffForHumans()}} @if($page->updatedBy) by <a href="/user/{{ $page->updatedBy->id }}">{{$page->updatedBy->name}}</a> @endif
+                        Last Updated {{ $page->updated_at->diffForHumans() }} @if($page->updatedBy) by <a href="{{ $page->updatedBy->getProfileUrl() }}">{{$page->updatedBy->name}}</a> @endif
                     </p>
 
                 </div>
             </div>
                     </p>
 
                 </div>
             </div>
+
             <div class="col-md-3 print-hidden">
                 <div class="margin-top large"></div>
                 @if($book->restricted || ($page->chapter && $page->chapter->restricted) || $page->restricted)
             <div class="col-md-3 print-hidden">
                 <div class="margin-top large"></div>
                 @if($book->restricted || ($page->chapter && $page->chapter->restricted) || $page->restricted)
@@ -87,7 +88,7 @@
 
                         @if($book->restricted)
                             @if(userCan('restrictions-manage', $book))
 
                         @if($book->restricted)
                             @if(userCan('restrictions-manage', $book))
-                                <a href="{{ $book->getUrl() }}/permissions"><i class="zmdi zmdi-lock-outline"></i>Book Permissions Active</a>
+                                <a href="{{ $book->getUrl('/permissions') }}"><i class="zmdi zmdi-lock-outline"></i>Book Permissions Active</a>
                             @else
                                 <i class="zmdi zmdi-lock-outline"></i>Book Permissions Active
                             @endif
                             @else
                                 <i class="zmdi zmdi-lock-outline"></i>Book Permissions Active
                             @endif
@@ -96,7 +97,7 @@
 
                         @if($page->chapter && $page->chapter->restricted)
                             @if(userCan('restrictions-manage', $page->chapter))
 
                         @if($page->chapter && $page->chapter->restricted)
                             @if(userCan('restrictions-manage', $page->chapter))
-                                <a href="{{ $page->chapter->getUrl() }}/permissions"><i class="zmdi zmdi-lock-outline"></i>Chapter Permissions Active</a>
+                                <a href="{{ $page->chapter->getUrl('/permissions') }}"><i class="zmdi zmdi-lock-outline"></i>Chapter Permissions Active</a>
                             @else
                                 <i class="zmdi zmdi-lock-outline"></i>Chapter Permissions Active
                             @endif
                             @else
                                 <i class="zmdi zmdi-lock-outline"></i>Chapter Permissions Active
                             @endif
 
                         @if($page->restricted)
                             @if(userCan('restrictions-manage', $page))
 
                         @if($page->restricted)
                             @if(userCan('restrictions-manage', $page))
-                                <a href="{{ $page->getUrl() }}/permissions"><i class="zmdi zmdi-lock-outline"></i>Page Permissions Active</a>
+                                <a href="{{ $page->getUrl('/permissions') }}"><i class="zmdi zmdi-lock-outline"></i>Page Permissions Active</a>
                             @else
                                 <i class="zmdi zmdi-lock-outline"></i>Page Permissions Active
                             @endif
                             @else
                                 <i class="zmdi zmdi-lock-outline"></i>Page Permissions Active
                             @endif
                     </div>
                 @endif
                 @include('pages/sidebar-tree-list', ['book' => $book, 'sidebarTree' => $sidebarTree])
                     </div>
                 @endif
                 @include('pages/sidebar-tree-list', ['book' => $book, 'sidebarTree' => $sidebarTree])
-
             </div>
             </div>
+
         </div>
     </div>
 
         </div>
     </div>
 
index 3445acbdc3f967e3412f0ca23b8d539b5ff1e94b..e40fdbf0fcaa28d673aeea356246a05894ea6fc3 100644 (file)
@@ -2,12 +2,12 @@
 <div class="book-tree" ng-non-bindable>
     <h6 class="text-muted">Book Navigation</h6>
     <ul class="sidebar-page-list menu">
 <div class="book-tree" ng-non-bindable>
     <h6 class="text-muted">Book Navigation</h6>
     <ul class="sidebar-page-list menu">
-        <li class="book-header"><a href="{{$book->getUrl()}}" class="book {{ $current->matches($book)? 'selected' : '' }}"><i class="zmdi zmdi-book"></i>{{$book->name}}</a></li>
+        <li class="book-header"><a href="{{ $book->getUrl() }}" class="book {{ $current->matches($book)? 'selected' : '' }}"><i class="zmdi zmdi-book"></i>{{$book->name}}</a></li>
 
 
         @foreach($sidebarTree as $bookChild)
             <li class="list-item-{{ $bookChild->getClassName() }} {{ $bookChild->getClassName() }} {{ $bookChild->isA('page') && $bookChild->draft ? 'draft' : '' }}">
 
 
         @foreach($sidebarTree as $bookChild)
             <li class="list-item-{{ $bookChild->getClassName() }} {{ $bookChild->getClassName() }} {{ $bookChild->isA('page') && $bookChild->draft ? 'draft' : '' }}">
-                <a href="{{$bookChild->getUrl()}}" class="{{ $bookChild->getClassName() }} {{ $current->matches($bookChild)? 'selected' : '' }}">
+                <a href="{{ $bookChild->getUrl() }}" class="{{ $bookChild->getClassName() }} {{ $current->matches($bookChild)? 'selected' : '' }}">
                     @if($bookChild->isA('chapter'))<i class="zmdi zmdi-collection-bookmark"></i>@else <i class="zmdi zmdi-file-text"></i>@endif{{ $bookChild->name }}
                 </a>
 
                     @if($bookChild->isA('chapter'))<i class="zmdi zmdi-collection-bookmark"></i>@else <i class="zmdi zmdi-file-text"></i>@endif{{ $bookChild->name }}
                 </a>
 
@@ -18,7 +18,7 @@
                     <ul class="menu sub-menu inset-list @if($bookChild->matchesOrContains($current)) open @endif">
                         @foreach($bookChild->pages as $childPage)
                             <li class="list-item-page {{ $childPage->isA('page') && $childPage->draft ? 'draft' : '' }}">
                     <ul class="menu sub-menu inset-list @if($bookChild->matchesOrContains($current)) open @endif">
                         @foreach($bookChild->pages as $childPage)
                             <li class="list-item-page {{ $childPage->isA('page') && $childPage->draft ? 'draft' : '' }}">
-                                <a href="{{$childPage->getUrl()}}" class="page {{ $current->matches($childPage)? 'selected' : '' }}">
+                                <a href="{{ $childPage->getUrl() }}" class="page {{ $current->matches($childPage)? 'selected' : '' }}">
                                     <i class="zmdi zmdi-file-text"></i> {{ $childPage->name }}
                                 </a>
                             </li>
                                     <i class="zmdi zmdi-file-text"></i> {{ $childPage->name }}
                                 </a>
                             </li>
index ff0d745866788bffcca5acec04f1d0da8e8fd743..c45ca6c7a8252dc253174770a7137099715b4355 100644 (file)
@@ -3,13 +3,13 @@
 
 @if($activity->user)
     <div class="left">
 
 @if($activity->user)
     <div class="left">
-        <img class="avatar" src="{{ $activity->user->getAvatar(30) }}" alt="{{$activity->user->name}}">
+        <img class="avatar" src="{{ $activity->user->getAvatar(30) }}" alt="{{ $activity->user->name }}">
     </div>
 @endif
 
 <div class="right" ng-non-bindable>
     @if($activity->user)
     </div>
 @endif
 
 <div class="right" ng-non-bindable>
     @if($activity->user)
-        <a href="/user/{{ $activity->user->id }}">{{$activity->user->name}}</a>
+        <a href="{{ $activity->user->getProfileUrl() }}">{{ $activity->user->name }}</a>
     @else
         A deleted user
     @endif
     @else
         A deleted user
     @endif
@@ -20,7 +20,7 @@
         <a href="{{ $activity->entity->getUrl() }}">{{ $activity->entity->name }}</a>
     @endif
 
         <a href="{{ $activity->entity->getUrl() }}">{{ $activity->entity->name }}</a>
     @endif
 
-    @if($activity->extra) "{{$activity->extra}}" @endif
+    @if($activity->extra) "{{ $activity->extra }}" @endif
 
     <br>
 
 
     <br>
 
index 2e23e267ba93fef4ae2b8389b52f9582caafb238..bf7dde1d4a34de2344ee1a32d49ba6b5101e166a 100644 (file)
@@ -1,20 +1,20 @@
 <style>
     header, #back-to-top, .primary-background {
 <style>
     header, #back-to-top, .primary-background {
-        background-color: {{ Setting::get('app-color') }} !important;
+        background-color: {{ setting('app-color') }} !important;
     }
     .faded-small, .primary-background-light {
     }
     .faded-small, .primary-background-light {
-        background-color: {{ Setting::get('app-color-light') }};
+        background-color: {{ setting('app-color-light') }};
     }
     .button-base, .button, input[type="button"], input[type="submit"] {
     }
     .button-base, .button, input[type="button"], input[type="submit"] {
-        background-color: {{ Setting::get('app-color') }};
+        background-color: {{ setting('app-color') }};
     }
     .button-base:hover, .button:hover, input[type="button"]:hover, input[type="submit"]:hover, .button:focus {
     }
     .button-base:hover, .button:hover, input[type="button"]:hover, input[type="submit"]:hover, .button:focus {
-        background-color: {{ Setting::get('app-color') }};
+        background-color: {{ setting('app-color') }};
     }
     .nav-tabs a.selected, .nav-tabs .tab-item.selected {
     }
     .nav-tabs a.selected, .nav-tabs .tab-item.selected {
-        border-bottom-color: {{ Setting::get('app-color') }};
+        border-bottom-color: {{ setting('app-color') }};
     }
     p.primary:hover, p .primary:hover, span.primary:hover, .text-primary:hover, a, a:hover, a:focus, .text-button, .text-button:hover, .text-button:focus {
     }
     p.primary:hover, p .primary:hover, span.primary:hover, .text-primary:hover, a, a:hover, a:focus, .text-button, .text-button:hover, .text-button:focus {
-        color: {{ Setting::get('app-color') }};
+        color: {{ setting('app-color') }};
     }
 </style>
\ No newline at end of file
     }
 </style>
\ No newline at end of file
index ec8d54226c1f0c9d1e7e278acebd6a753addded8..4c1ded9d2a723dec738433cef864638a86d19db8 100644 (file)
@@ -1,5 +1,5 @@
 
 
-<script src="/libs/highlightjs/highlight.min.js"></script>
+<script src="{{ baseUrl('/libs/highlightjs/highlight.min.js') }}"></script>
 <script>
     $(function() {
         var aCodes = document.getElementsByTagName('pre');
 <script>
     $(function() {
         var aCodes = document.getElementsByTagName('pre');
index f22fd47d4f25caf798ce1fd7e2d4935f5ceee60c..2de4d968a650fe6310684e2be8d1c3f636f60617 100644 (file)
@@ -1,20 +1,21 @@
 <!DOCTYPE html>
 <html>
 <head>
 <!DOCTYPE html>
 <html>
 <head>
-    <title>BookStack</title>
+    <title>{{ setting('app-name') }}</title>
 
     <!-- Meta -->
     <meta name="viewport" content="width=device-width">
     <meta name="token" content="{{ csrf_token() }}">
 
     <!-- Meta -->
     <meta name="viewport" content="width=device-width">
     <meta name="token" content="{{ csrf_token() }}">
+    <meta name="base-url" content="{{ baseUrl('/') }}">
     <meta charset="utf-8">
 
     <!-- Styles and Fonts -->
     <link rel="stylesheet" href="{{ versioned_asset('css/styles.css') }}">
     <link rel="stylesheet" media="print" href="{{ versioned_asset('css/print-styles.css') }}">
     <meta charset="utf-8">
 
     <!-- Styles and Fonts -->
     <link rel="stylesheet" href="{{ versioned_asset('css/styles.css') }}">
     <link rel="stylesheet" media="print" href="{{ versioned_asset('css/print-styles.css') }}">
-    <link rel="stylesheet" href="/libs/material-design-iconic-font/css/material-design-iconic-font.min.css">
+    <link rel="stylesheet" href="{{ baseUrl("/libs/material-design-iconic-font/css/material-design-iconic-font.min.css") }}">
 
     <!-- Scripts -->
 
     <!-- Scripts -->
-    <script src="/libs/jquery/jquery.min.js?version=2.1.4"></script>
+    <script src="{{ baseUrl("/libs/jquery/jquery.min.js?version=2.1.4") }}"></script>
     @include('partials/custom-styles')
 </head>
 <body class="@yield('body-class')" ng-app="bookStack">
     @include('partials/custom-styles')
 </head>
 <body class="@yield('body-class')" ng-app="bookStack">
         <div class="row">
             <div class="col-md-6">
 
         <div class="row">
             <div class="col-md-6">
 
-                <a href="/" class="logo">
-                    <img class="logo-image" src="/logo.png" alt="Logo">
-                    <span class="logo-text">{{ Setting::get('app-name', 'BookStack') }}</span>
+                <a href="{{ baseUrl('/') }}" class="logo">
+                    @if(setting('app-logo', '') !== 'none')
+                        <img class="logo-image" src="{{ setting('app-logo', '') === '' ? baseUrl('/logo.png') : baseUrl(setting('app-logo', '')) }}" alt="Logo">
+                    @endif
+                    <span class="logo-text">{{ setting('app-name') }}</span>
                 </a>
             </div>
             <div class="col-md-6">
                 </a>
             </div>
             <div class="col-md-6">
                     </div>
                     @if(isset($signedIn) && $signedIn)
                         <div class="dropdown-container" dropdown>
                     </div>
                     @if(isset($signedIn) && $signedIn)
                         <div class="dropdown-container" dropdown>
-                                <span class="user-name" dropdown-toggle>
-                                    <img class="avatar" src="{{$currentUser->getAvatar(30)}}" alt="{{ $currentUser->name }}">
-                                    <span class="name" ng-non-bindable>{{ $currentUser->name }}</span> <i class="zmdi zmdi-caret-down"></i>
-                                </span>
+                            <span class="user-name" dropdown-toggle>
+                                <img class="avatar" src="{{$currentUser->getAvatar(30)}}" alt="{{ $currentUser->name }}">
+                                <span class="name" ng-non-bindable>{{ $currentUser->getShortName(9) }}</span> <i class="zmdi zmdi-caret-down"></i>
+                            </span>
                             <ul>
                                 <li>
                             <ul>
                                 <li>
-                                    <a href="/users/{{$currentUser->id}}" class="text-primary"><i class="zmdi zmdi-edit zmdi-hc-lg"></i>Edit Profile</a>
+                                    <a href="{{ baseUrl("/user/{$currentUser->id}") }}" class="text-primary"><i class="zmdi zmdi-account zmdi-hc-fw zmdi-hc-lg"></i>View Profile</a>
+                                </li>
+                                <li>
+                                    <a href="{{ baseUrl("/settings/users/{$currentUser->id}") }}" class="text-primary"><i class="zmdi zmdi-edit zmdi-hc-fw zmdi-hc-lg"></i>Edit Profile</a>
                                 </li>
                                 <li>
                                 </li>
                                 <li>
-                                    <a href="/logout" class="text-neg"><i class="zmdi zmdi-run zmdi-hc-lg"></i>Logout</a>
+                                    <a href="{{ baseUrl('/logout') }}" class="text-neg"><i class="zmdi zmdi-run zmdi-hc-fw zmdi-hc-lg"></i>Logout</a>
                                 </li>
                             </ul>
                         </div>
                                 </li>
                             </ul>
                         </div>
index c2ba341450fcdb1522579006502ef5c57e0fd6c7..fcfb2c902472ae627c69250f33fb44ba86b03bd8 100644 (file)
@@ -4,41 +4,41 @@
 
     <div class="container anim fadeIn" ng-non-bindable>
 
 
     <div class="container anim fadeIn" ng-non-bindable>
 
-        <h1>Search Results&nbsp;&nbsp;&nbsp; <span class="text-muted">{{$searchTerm}}</span></h1>
+        <h1>Search Results&nbsp;&nbsp;&nbsp; <span class="text-muted">{{ $searchTerm }}</span></h1>
 
         <p>
 
             @if(count($pages) > 0)
 
         <p>
 
             @if(count($pages) > 0)
-                <a href="/search/pages?term={{$searchTerm}}" class="text-page"><i class="zmdi zmdi-file-text"></i>View all matched pages</a>
+                <a href="{{ baseUrl("/search/pages?term={$searchTerm}") }}" class="text-page"><i class="zmdi zmdi-file-text"></i>View all matched pages</a>
             @endif
 
 
             @if(count($chapters) > 0)
                 &nbsp; &nbsp;&nbsp;
             @endif
 
 
             @if(count($chapters) > 0)
                 &nbsp; &nbsp;&nbsp;
-                <a href="/search/chapters?term={{$searchTerm}}" class="text-chapter"><i class="zmdi zmdi-collection-bookmark"></i>View all matched chapters</a>
+                <a href="{{ baseUrl("/search/chapters?term={$searchTerm}") }}" class="text-chapter"><i class="zmdi zmdi-collection-bookmark"></i>View all matched chapters</a>
             @endif
 
             @if(count($books) > 0)
                 &nbsp; &nbsp;&nbsp;
             @endif
 
             @if(count($books) > 0)
                 &nbsp; &nbsp;&nbsp;
-                <a href="/search/books?term={{$searchTerm}}" class="text-book"><i class="zmdi zmdi-book"></i>View all matched books</a>
+                <a href="{{ baseUrl("/search/books?term={$searchTerm}") }}" class="text-book"><i class="zmdi zmdi-book"></i>View all matched books</a>
             @endif
         </p>
         <div class="row">
 
             <div class="col-md-6">
             @endif
         </p>
         <div class="row">
 
             <div class="col-md-6">
-                <h3><a href="/search/pages?term={{$searchTerm}}" class="no-color">Matching Pages</a></h3>
+                <h3><a href="{{ baseUrl("/search/pages?term={$searchTerm}") }}" class="no-color">Matching Pages</a></h3>
                 @include('partials/entity-list', ['entities' => $pages, 'style' => 'detailed'])
             </div>
 
             <div class="col-md-5 col-md-offset-1">
 
                 @if(count($books) > 0)
                 @include('partials/entity-list', ['entities' => $pages, 'style' => 'detailed'])
             </div>
 
             <div class="col-md-5 col-md-offset-1">
 
                 @if(count($books) > 0)
-                    <h3><a href="/search/books?term={{$searchTerm}}" class="no-color">Matching Books</a></h3>
+                    <h3><a href="{{ baseUrl("/search/books?term={$searchTerm}") }}" class="no-color">Matching Books</a></h3>
                     @include('partials/entity-list', ['entities' => $books])
                 @endif
 
                 @if(count($chapters) > 0)
                     @include('partials/entity-list', ['entities' => $books])
                 @endif
 
                 @if(count($chapters) > 0)
-                    <h3><a href="/search/chapters?term={{$searchTerm}}" class="no-color">Matching Chapters</a></h3>
+                    <h3><a href="{{ baseUrl("/search/chapters?term={$searchTerm}") }}" class="no-color">Matching Chapters</a></h3>
                     @include('partials/entity-list', ['entities' => $chapters])
                 @endif
 
                     @include('partials/entity-list', ['entities' => $chapters])
                 @endif
 
index 5ca6492ef6eda07efb5c6699ed2f7eae403599e6..dd9c6a5090d740923817f241d831f27b7f456f8a 100644 (file)
@@ -6,7 +6,7 @@
         <div class="row">
 
             <div class="col-sm-7">
         <div class="row">
 
             <div class="col-sm-7">
-                <h1>{{ $title }} <small>{{$searchTerm}}</small></h1>
+                <h1>{{ $title }} <small>{{ $searchTerm }}</small></h1>
                 @include('partials.entity-list', ['entities' => $entities, 'style' => 'detailed'])
                 {!! $entities->links() !!}
             </div>
                 @include('partials.entity-list', ['entities' => $entities, 'style' => 'detailed'])
                 {!! $entities->links() !!}
             </div>
index 1e76c16754d6655f7dc5eeca4b218e1ea0c42486..222ff0f690492dddcd8c0c91365ba18a96c68cd1 100644 (file)
@@ -8,7 +8,7 @@
 
     <h1>Settings</h1>
 
 
     <h1>Settings</h1>
 
-    <form action="/settings" method="POST" ng-cloak>
+    <form action="{{ baseUrl("/settings") }}" method="POST" ng-cloak>
         {!! csrf_field() !!}
 
         <h3>App Settings</h3>
         {!! csrf_field() !!}
 
         <h3>App Settings</h3>
@@ -41,7 +41,7 @@
                 <div class="form-group" id="logo-control">
                     <label for="setting-app-logo">Application logo</label>
                     <p class="small">This image should be 43px in height. <br>Large images will be scaled down.</p>
                 <div class="form-group" id="logo-control">
                     <label for="setting-app-logo">Application logo</label>
                     <p class="small">This image should be 43px in height. <br>Large images will be scaled down.</p>
-                    <image-picker resize-height="43" show-remove="true" resize-width="200" current-image="{{ setting('app-logo', '') }}" default-image="/logo.png" name="setting-app-logo" image-class="logo-image"></image-picker>
+                    <image-picker resize-height="43" show-remove="true" resize-width="200" current-image="{{ setting('app-logo', '') }}" default-image="{{ baseUrl('/logo.png') }}" name="setting-app-logo" image-class="logo-image"></image-picker>
                 </div>
                 <div class="form-group" id="color-control">
                     <label for="setting-app-color">Application primary color</label>
                 </div>
                 <div class="form-group" id="color-control">
                     <label for="setting-app-color">Application primary color</label>
 @stop
 
 @section('scripts')
 @stop
 
 @section('scripts')
-    <script src="/libs/jq-color-picker/tiny-color-picker.min.js?version=1.0.0"></script>
+    <script src="{{ baseUrl("/libs/jq-color-picker/tiny-color-picker.min.js?version=1.0.0") }}"></script>
     <script type="text/javascript">
         $('#setting-app-color').colorPicker({
             opacity: false,
     <script type="text/javascript">
         $('#setting-app-color').colorPicker({
             opacity: false,
                 if (!isEmpty) $elm.val(hexVal);
                 $('#setting-app-color-light').val(isEmpty ? '' : rgbLightVal);
                 // Set page elements to provide preview
                 if (!isEmpty) $elm.val(hexVal);
                 $('#setting-app-color-light').val(isEmpty ? '' : rgbLightVal);
                 // Set page elements to provide preview
-                $('#header, .image-picker .button').css('background-color', hexVal);
+                $('#header, .image-picker .button').attr('style', 'background-color:'+ hexVal+'!important;');
                 $('.faded-small').css('background-color', rgbLightVal);
                 $('.faded-small').css('background-color', rgbLightVal);
-                $('.setting-nav a.selected').css('border-bottom-color', hexVal);
+                $('.setting-nav a.selected').css('border-bottom-color', hexVal  + '!important');
             }
         });
     </script>
             }
         });
     </script>
index b656f5b364bf5d9467d513f1f20837d0ab7c179e..f4526b4c8b450f8771fb10dbd2640a6613b09b82 100644 (file)
@@ -4,13 +4,13 @@
         <div class="row">
             <div class="col-md-12 setting-nav nav-tabs">
                 @if($currentUser->can('settings-manage'))
         <div class="row">
             <div class="col-md-12 setting-nav nav-tabs">
                 @if($currentUser->can('settings-manage'))
-                    <a href="/settings" @if($selected == 'settings') class="selected text-button" @endif><i class="zmdi zmdi-settings"></i>Settings</a>
+                    <a href="{{ baseUrl('/settings') }}" @if($selected == 'settings') class="selected text-button" @endif><i class="zmdi zmdi-settings"></i>Settings</a>
                 @endif
                 @if($currentUser->can('users-manage'))
                 @endif
                 @if($currentUser->can('users-manage'))
-                    <a href="/settings/users" @if($selected == 'users') class="selected text-button" @endif><i class="zmdi zmdi-accounts"></i>Users</a>
+                    <a href="{{ baseUrl('/settings/users') }}" @if($selected == 'users') class="selected text-button" @endif><i class="zmdi zmdi-accounts"></i>Users</a>
                 @endif
                 @if($currentUser->can('user-roles-manage'))
                 @endif
                 @if($currentUser->can('user-roles-manage'))
-                    <a href="/settings/roles" @if($selected == 'roles') class="selected text-button" @endif><i class="zmdi zmdi-lock-open"></i>Roles</a>
+                    <a href="{{ baseUrl('/settings/roles') }}" @if($selected == 'roles') class="selected text-button" @endif><i class="zmdi zmdi-lock-open"></i>Roles</a>
                 @endif
             </div>
         </div>
                 @endif
             </div>
         </div>
index f7d39f454f235102e29ddef14de8c59b0f20a172..6a59c0c54c8281ebd6756e007a9dcd2e27a4e056 100644 (file)
@@ -7,7 +7,7 @@
     <div class="container">
         <h1>Create New Role</h1>
 
     <div class="container">
         <h1>Create New Role</h1>
 
-        <form action="/settings/roles/new" method="POST">
+        <form action="{{ baseUrl("/settings/roles/new") }}" method="POST">
             @include('settings/roles/form')
         </form>
     </div>
             @include('settings/roles/form')
         </form>
     </div>
index 5d1ffe2594cb5f040145b0ecdd74198eac941d95..1377d07aeb7857528d1ae72ca0d48e506cbb2c2f 100644 (file)
@@ -6,9 +6,9 @@
 
     <div class="container small" ng-non-bindable>
         <h1>Delete Role</h1>
 
     <div class="container small" ng-non-bindable>
         <h1>Delete Role</h1>
-        <p>This will delete the role with the name '{{$role->display_name}}'.</p>
+        <p>This will delete the role with the name '{{ $role->display_name }}'.</p>
 
 
-        <form action="/settings/roles/delete/{{$role->id}}" method="POST">
+        <form action="{{ baseUrl("/settings/roles/delete/{$role->id}") }}" method="POST">
             {!! csrf_field() !!}
             <input type="hidden" name="_method" value="DELETE">
 
             {!! csrf_field() !!}
             <input type="hidden" name="_method" value="DELETE">
 
@@ -20,7 +20,7 @@
             @endif
 
             <p class="text-neg">Are you sure you want to delete this role?</p>
             @endif
 
             <p class="text-neg">Are you sure you want to delete this role?</p>
-            <a href="/settings/roles/{{ $role->id }}" class="button">Cancel</a>
+            <a href="{{ baseUrl("/settings/roles/{$role->id}") }}" class="button">Cancel</a>
             <button type="submit" class="button neg">Confirm</button>
         </form>
     </div>
             <button type="submit" class="button neg">Confirm</button>
         </form>
     </div>
index f98e6e0b34b954860e57e84ba3619aa9898c3166..7e186e8980e6069910fa6c73d01648b0e6362432 100644 (file)
             </div>
             <div class="col-sm-6">
                 <p></p>
             </div>
             <div class="col-sm-6">
                 <p></p>
-                <a href="/settings/roles/delete/{{ $role->id }}" class="button neg float right">Delete Role</a>
+                <a href="{{ baseUrl("/settings/roles/delete/{$role->id}") }}" class="button neg float right">Delete Role</a>
             </div>
         </div>
 
             </div>
         </div>
 
-        <form action="/settings/roles/{{ $role->id }}" method="POST">
+        <form action="{{ baseUrl("/settings/roles/{$role->id}") }}" method="POST">
             <input type="hidden" name="_method" value="PUT">
             @include('settings/roles/form', ['model' => $role])
         </form>
             <input type="hidden" name="_method" value="PUT">
             @include('settings/roles/form', ['model' => $role])
         </form>
index 6181acaea03dcaa599529b2fec1474c298185f5d..5e653f8de0525975e1f375243fed25c9bf9d0fe9 100644 (file)
                 </table>
             </div>
         </div>
                 </table>
             </div>
         </div>
-        <a href="/settings/roles" class="button muted">Cancel</a>
+        <a href="{{ baseUrl("/settings/roles") }}" class="button muted">Cancel</a>
         <button type="submit" class="button pos">Save Role</button>
     </div>
     <div class="col-md-3">
         <button type="submit" class="button pos">Save Role</button>
     </div>
     <div class="col-md-3">
         <table class="list-table">
             @foreach($role->users as $user)
                 <tr>
         <table class="list-table">
             @foreach($role->users as $user)
                 <tr>
-                    <td style="line-height: 0;"><img class="avatar small" src="{{$user->getAvatar(40)}}" alt="{{$user->name}}"></td>
+                    <td style="line-height: 0;"><img class="avatar small" src="{{ $user->getAvatar(40) }}" alt="{{ $user->name }}"></td>
                     <td>
                         @if(userCan('users-manage') || $currentUser->id == $user->id)
                     <td>
                         @if(userCan('users-manage') || $currentUser->id == $user->id)
-                            <a href="/settings/users/{{$user->id}}">
+                            <a href="{{ baseUrl("/settings/users/{$user->id}") }}">
                                 @endif
                                 {{ $user->name }}
                                 @if(userCan('users-manage') || $currentUser->id == $user->id)
                                 @endif
                                 {{ $user->name }}
                                 @if(userCan('users-manage') || $currentUser->id == $user->id)
index 358c24945e79bfc86c8d779fdcd64b481ff3de03..2c905ae22c336aa0ebf102d63437ef9fea867633 100644 (file)
@@ -12,7 +12,7 @@
             </div>
             <div class="col-sm-4">
                 <p></p>
             </div>
             <div class="col-sm-4">
                 <p></p>
-                <a href="/settings/roles/new" class="button float right pos"><i class="zmdi zmdi-lock-open"></i>Add new role</a>
+                <a href="{{ baseUrl("/settings/roles/new") }}" class="button float right pos"><i class="zmdi zmdi-lock-open"></i>Add new role</a>
             </div>
         </div>
 
             </div>
         </div>
 
@@ -24,7 +24,7 @@
             </tr>
             @foreach($roles as $role)
                 <tr>
             </tr>
             @foreach($roles as $role)
                 <tr>
-                    <td><a href="/settings/roles/{{ $role->id }}">{{ $role->display_name }}</a></td>
+                    <td><a href="{{ baseUrl("/settings/roles/{$role->id}") }}">{{ $role->display_name }}</a></td>
                     <td>{{ $role->description }}</td>
                     <td class="text-right">{{ $role->users->count() }}</td>
                 </tr>
                     <td>{{ $role->description }}</td>
                     <td class="text-right">{{ $role->users->count() }}</td>
                 </tr>
index 716742ba8e8486c9293cac5737dd84f7cb36074a..b25f2ee8aa10d6df97786da231456e75a21d2f78 100644 (file)
@@ -6,9 +6,9 @@
     <div class="container small" ng-non-bindable>
         <h1>Create User</h1>
 
     <div class="container small" ng-non-bindable>
         <h1>Create User</h1>
 
-        <form action="/settings/users/create" method="post">
+        <form action="{{ baseUrl("/settings/users/create") }}" method="post">
             {!! csrf_field() !!}
             {!! csrf_field() !!}
-            @include('users.forms.' . $authMethod)
+            @include('users/forms/' . $authMethod)
         </form>
     </div>
 
         </form>
     </div>
 
index af247509dcc64cdd054eb3c91d90593d3ee2dc4c..74b993b3c681e80ecb17d8280c1add4bd4fadab1 100644 (file)
@@ -4,13 +4,13 @@
 
     <div class="container small" ng-non-bindable>
         <h1>Delete User</h1>
 
     <div class="container small" ng-non-bindable>
         <h1>Delete User</h1>
-        <p>This will fully delete this user with the name '<span class="text-neg">{{$user->name}}</span>' from the system.</p>
+        <p>This will fully delete this user with the name '<span class="text-neg">{{ $user->name }}</span>' from the system.</p>
         <p class="text-neg">Are you sure you want to delete this user?</p>
 
         <p class="text-neg">Are you sure you want to delete this user?</p>
 
-        <form action="/settings/users/{{$user->id}}" method="POST">
+        <form action="{{ baseUrl("/settings/users/{$user->id}") }}" method="POST">
             {!! csrf_field() !!}
             <input type="hidden" name="_method" value="DELETE">
             {!! csrf_field() !!}
             <input type="hidden" name="_method" value="DELETE">
-            <a href="/settings/users/{{$user->id}}" class="button muted">Cancel</a>
+            <a href="{{ baseUrl("/settings/users/{$user->id}") }}" class="button muted">Cancel</a>
             <button type="submit" class="button neg">Confirm</button>
         </form>
     </div>
             <button type="submit" class="button neg">Confirm</button>
         </form>
     </div>
index 16fc1bfa22c20a7fe08aa44ad839ecb201a5b1cd..d06ec09bc3a3fcde92179766b0eed4b647185120 100644 (file)
@@ -8,14 +8,14 @@
 
 
     <div class="container small">
 
 
     <div class="container small">
-        <form action="/settings/users/{{$user->id}}" method="post">
+        <form action="{{ baseUrl("/settings/users/{$user->id}") }}" method="post">
             <div class="row">
                 <div class="col-sm-8">
                     <h1>Edit {{ $user->id === $currentUser->id ? 'Profile' : 'User' }}</h1>
                 </div>
                 <div class="col-sm-4">
                     <p></p>
             <div class="row">
                 <div class="col-sm-8">
                     <h1>Edit {{ $user->id === $currentUser->id ? 'Profile' : 'User' }}</h1>
                 </div>
                 <div class="col-sm-4">
                     <p></p>
-                    <a href="/settings/users/{{$user->id}}/delete" class="neg button float right">Delete User</a>
+                    <a href="{{ baseUrl("/settings/users/{$user->id}/delete") }}" class="neg button float right">Delete User</a>
                 </div>
             </div>
             <div class="row">
                 </div>
             </div>
             <div class="row">
@@ -29,7 +29,7 @@
                 <div class="form-group" id="logo-control">
                     <label for="user-avatar">User Avatar</label>
                     <p class="small">This image should be approx 256px square.</p>
                 <div class="form-group" id="logo-control">
                     <label for="user-avatar">User Avatar</label>
                     <p class="small">This image should be approx 256px square.</p>
-                    <image-picker resize-height="512" resize-width="512" current-image="{{ $user->getAvatar(80) }}" current-id="{{ $user->image_id }}" default-image="/user_avatar.png" name="image_id" show-remove="false" image-class="['avatar' ,'large']"></image-picker>
+                    <image-picker resize-height="512" resize-width="512" current-image="{{ $user->getAvatar(80) }}" current-id="{{ $user->image_id }}" default-image="{{ baseUrl("/user_avatar.png") }}" name="image_id" show-remove="false" image-class="['avatar' ,'large']"></image-picker>
                 </div>
             </div>
         </div>
                 </div>
             </div>
         </div>
@@ -49,9 +49,9 @@
                         <div><i class="zmdi zmdi-google-plus-box zmdi-hc-4x" style="color: #DC4E41;"></i></div>
                         <div>
                             @if($user->hasSocialAccount('google'))
                         <div><i class="zmdi zmdi-google-plus-box zmdi-hc-4x" style="color: #DC4E41;"></i></div>
                         <div>
                             @if($user->hasSocialAccount('google'))
-                                <a href="/login/service/google/detach" class="button neg">Disconnect Account</a>
+                                <a href="{{ baseUrl("/login/service/google/detach") }}" class="button neg">Disconnect Account</a>
                             @else
                             @else
-                                <a href="/login/service/google" class="button pos">Attach Account</a>
+                                <a href="{{ baseUrl("/login/service/google") }}" class="button pos">Attach Account</a>
                             @endif
                         </div>
                     </div>
                             @endif
                         </div>
                     </div>
@@ -61,9 +61,9 @@
                         <div><i class="zmdi zmdi-github zmdi-hc-4x" style="color: #444;"></i></div>
                         <div>
                             @if($user->hasSocialAccount('github'))
                         <div><i class="zmdi zmdi-github zmdi-hc-4x" style="color: #444;"></i></div>
                         <div>
                             @if($user->hasSocialAccount('github'))
-                                <a href="/login/service/github/detach" class="button neg">Disconnect Account</a>
+                                <a href="{{ baseUrl("/login/service/github/detach") }}" class="button neg">Disconnect Account</a>
                             @else
                             @else
-                                <a href="/login/service/github" class="button pos">Attach Account</a>
+                                <a href="{{ baseUrl("/login/service/github") }}" class="button pos">Attach Account</a>
                             @endif
                         </div>
                     </div>
                             @endif
                         </div>
                     </div>
index 5fc8ce397d10b118d7c8e6ee338aca657999c9cd..6e4d2a5fd3c8de7402021955ba9cf1b40c1a6ed9 100644 (file)
@@ -25,6 +25,6 @@
 @endif
 
 <div class="form-group">
 @endif
 
 <div class="form-group">
-    <a href="/settings/users" class="button muted">Cancel</a>
+    <a href="{{ baseUrl("/settings/users") }}" class="button muted">Cancel</a>
     <button class="button pos" type="submit">Save</button>
 </div>
\ No newline at end of file
     <button class="button pos" type="submit">Save</button>
 </div>
\ No newline at end of file
index 52ebac9765fb52d5306471b708ac257771b9fcaf..d902c5b2cf2955046e68b713e6c43b03122a02fe 100644 (file)
@@ -34,7 +34,7 @@
 </div>
 
 <div class="form-group">
 </div>
 
 <div class="form-group">
-    <a href="/settings/users" class="button muted">Cancel</a>
+    <a href="{{ baseUrl("/settings/users") }}" class="button muted">Cancel</a>
     <button class="button pos" type="submit">Save</button>
 </div>
 
     <button class="button pos" type="submit">Save</button>
 </div>
 
index d539f314ee57c49335f67aa09d2149b196145808..e72a9e61a5df113d041190cde8707ccbd6d56749 100644 (file)
@@ -14,7 +14,7 @@
             <div class="col-sm-4">
                 <p></p>
                 @if(userCan('users-manage'))
             <div class="col-sm-4">
                 <p></p>
                 @if(userCan('users-manage'))
-                    <a href="/settings/users/create" class="pos button float right"><i class="zmdi zmdi-account-add"></i>Add new user</a>
+                    <a href="{{ baseUrl("/settings/users/create") }}" class="pos button float right"><i class="zmdi zmdi-account-add"></i>Add new user</a>
                 @endif
             </div>
         </div>
                 @endif
             </div>
         </div>
@@ -26,9 +26,9 @@
                 </div>
             </div>
             <div class="col-sm-4">
                 </div>
             </div>
             <div class="col-sm-4">
-                <form method="get" class="float right" action="/settings/users">
+                <form method="get" class="float right" action="{{ baseUrl("/settings/users") }}">
                     @foreach(collect($listDetails)->except('search') as $name => $val)
                     @foreach(collect($listDetails)->except('search') as $name => $val)
-                        <input type="hidden" name="{{$name}}" value="{{$val}}">
+                        <input type="hidden" name="{{ $name }}" value="{{ $val }}">
                     @endforeach
                     <input type="text" name="search" placeholder="Search Users" @if($listDetails['search']) value="{{$listDetails['search']}}" @endif>
                 </form>
                     @endforeach
                     <input type="text" name="search" placeholder="Search Users" @if($listDetails['search']) value="{{$listDetails['search']}}" @endif>
                 </form>
             </tr>
             @foreach($users as $user)
                 <tr>
             </tr>
             @foreach($users as $user)
                 <tr>
-                    <td style="line-height: 0;"><img class="avatar med" src="{{$user->getAvatar(40)}}" alt="{{$user->name}}"></td>
+                    <td style="line-height: 0;"><img class="avatar med" src="{{ $user->getAvatar(40)}}" alt="{{ $user->name }}"></td>
                     <td>
                         @if(userCan('users-manage') || $currentUser->id == $user->id)
                     <td>
                         @if(userCan('users-manage') || $currentUser->id == $user->id)
-                            <a href="/settings/users/{{$user->id}}">
+                            <a href="{{ baseUrl("/settings/users/{$user->id}") }}">
                                 @endif
                                 {{ $user->name }}
                                 @if(userCan('users-manage') || $currentUser->id == $user->id)
                                 @endif
                                 {{ $user->name }}
                                 @if(userCan('users-manage') || $currentUser->id == $user->id)
@@ -59,7 +59,7 @@
                     </td>
                     <td>
                         @if(userCan('users-manage') || $currentUser->id == $user->id)
                     </td>
                     <td>
                         @if(userCan('users-manage') || $currentUser->id == $user->id)
-                            <a href="/settings/users/{{$user->id}}">
+                            <a href="{{ baseUrl("/settings/users/{$user->id}") }}">
                                 @endif
                                 {{ $user->email }}
                                 @if(userCan('users-manage') || $currentUser->id == $user->id)
                                 @endif
                                 {{ $user->email }}
                                 @if(userCan('users-manage') || $currentUser->id == $user->id)
@@ -68,7 +68,7 @@
                     </td>
                     <td>
                         @foreach($user->roles as $index => $role)
                     </td>
                     <td>
                         @foreach($user->roles as $index => $role)
-                            <small><a href="/settings/roles/{{$role->id}}">{{$role->display_name}}</a>@if($index !== count($user->roles) -1),@endif</small>
+                            <small><a href="{{ baseUrl("/settings/roles/{$role->id}") }}">{{$role->display_name}}</a>@if($index !== count($user->roles) -1),@endif</small>
                         @endforeach
                     </td>
                 </tr>
                         @endforeach
                     </td>
                 </tr>
index 10189f9aa48900d1c5dabaaa9c0b557a63633d26..1ae869979d1aa1c44f67fdffba57ad65f23fa167 100644 (file)
@@ -12,7 +12,7 @@
                     <div class="col-md-7">
                         <div class="clearfix">
                             <div class="padded-right float left">
                     <div class="col-md-7">
                         <div class="clearfix">
                             <div class="padded-right float left">
-                                <img class="avatar square huge" src="{{$user->getAvatar(120)}}" alt="{{ $user->name }}">
+                                <img class="avatar square huge" src="{{ $user->getAvatar(120) }}" alt="{{ $user->name }}">
                             </div>
                             <div>
                                 <h3 style="margin-top: 0;">{{ $user->name }}</h3>
                             </div>
                             <div>
                                 <h3 style="margin-top: 0;">{{ $user->name }}</h3>