Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
U
UserAdminV2
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
庄欣
UserAdminV2
Commits
5d3cc6be
Commit
5d3cc6be
authored
Apr 03, 2012
by
Taylor Otwell
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
template changes.
parent
2af60594
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
85 additions
and
101 deletions
+85
-101
application/views/home/index.blade.php
+14
-8
bundles/docs/routes.php
+52
-16
bundles/docs/views/home.blade.php
+0
-37
bundles/docs/views/menu.blade.php
+0
-28
bundles/docs/views/template.blade.php
+5
-7
public/laravel/css/style.css
+14
-5
No files found.
application/views/home/index.blade.php
View file @
5d3cc6be
...
...
@@ -13,15 +13,12 @@
<h1>
Laravel
</h1>
<h2>
A Framework For Web Artisans
</h2>
<p
class=
"intro-text"
>
You have successfully installed the Laravel framework. Laravel is a simple framework
that helps web artisans create beautiful, creative applications using elegant, expressive
syntax. You'll love using it.
<p
class=
"intro-text"
style=
"margin-top: 45px;"
>
</p>
</header>
<div
role=
"main"
class=
"main"
>
<div
class=
"home"
>
<h
3
>
Learn the terrain.
</h3>
<h
2
>
Learn the terrain.
</h3>
<p>
You've landed yourself on our default home page. The route that
...
...
@@ -34,13 +31,22 @@
<pre>
{{ path('app') }}views/home/index.php
</pre>
<h
3>
Read the docs.
</h3
>
<h
2>
Grow in knowledge.
</h2
>
<p>
The docs are now included with the source package, you can {{ HTML::link('docs', 'read them offline here') }}.
Leaning to use Laravel is amazingly simple thanks to
its {{ HTML::link('docs', 'wonderful documentation') }}.
Here are the basics:
</p>
<h3>
Create something beautiful.
</h3>
<ul>
<li>
{{ HTML::link('docs/routing#the-basics', 'Defining Routes') }}
</li>
<li>
{{ HTML::link('docs/controllers#the-basics', 'Building Controllers') }}
</li>
<li>
{{ HTML::link('docs/views#the-basics', 'Creating Views') }}
</li>
<li>
{{ HTML::link('docs/database/eloquent', 'Eloquent ORM') }}
</li>
</ul>
<h2>
Create something beautiful.
</h2>
<p>
Now that you're up and running, it's time to start creating!
...
...
bundles/docs/routes.php
View file @
5d3cc6be
<?php
/**
* Load the Markdown library.
*/
require_once
__DIR__
.
'/libraries/markdown.php'
;
/**
* Get the parsed Markdown contents of a given page.
*
* @param string $page
* @return string
*/
function
document
(
$page
)
{
return
Markdown
(
file_get_contents
(
path
(
'storage'
)
.
'documentation/'
.
$page
.
'.md'
));
}
/**
* Determine if a documentation page exists.
*
* @param string $page
* @return bool
*/
function
document_exists
(
$page
)
{
return
file_exists
(
path
(
'storage'
)
.
'documentation/'
.
$page
.
'.md'
);
}
/**
* Attach the sidebar to the documentatoin template.
*/
View
::
composer
(
'docs::template'
,
function
(
$view
)
{
Asset
::
add
(
'stylesheet'
,
'laravel/css/style.css'
);
Asset
::
add
(
'modernizr'
,
'laravel/js/modernizr-2.5.3.min.js'
);
Asset
::
container
(
'footer'
)
->
add
(
'prettify'
,
'laravel/js/prettify.js'
);
$view
->
with
(
'sidebar'
,
Markdown
(
file_get_contents
(
path
(
'storage'
)
.
'documentation/contents.md'
)));
$view
->
with
(
'sidebar'
,
document
(
'contents'
));
});
/**
* Handle the documentation homepage.
*
* This page contains the "introduction" to Laravel.
*/
Route
::
get
(
'(:bundle)'
,
function
()
{
return
View
::
make
(
'docs::
home'
);
return
View
::
make
(
'docs::
page'
)
->
with
(
'content'
,
document
(
'home'
)
);
});
Route
::
get
(
'docs/(:any)/(:any?)'
,
function
(
$section
,
$page
=
null
)
/**
* Handle documentation routes for sections and pages.
*
* @param string $section
* @param string $page
* @return mixed
*/
Route
::
get
(
'(:bundle)/(:any)/(:any?)'
,
function
(
$section
,
$page
=
null
)
{
$
root
=
path
(
'storage'
)
.
'documentation/'
;
$
file
=
rtrim
(
implode
(
'/'
,
func_get_args
()),
'/'
)
;
$file
=
rtrim
(
implode
(
'/'
,
array
(
$section
,
$page
)),
'/'
)
.
'.md'
;
if
(
file_exists
(
$path
=
$root
.
$file
))
// If no page was specified, but a "home" page exists for the section,
// we'll set the file to the home page so that the proper page is
// display back out to the client for the requested doc page.
if
(
is_null
(
$page
)
and
document_exists
(
$file
.
'/home'
))
{
$
content
=
Markdown
(
file_get_contents
(
$path
))
;
$
file
.=
'/home'
;
}
elseif
(
file_exists
(
$path
=
$root
.
$section
.
'/home.md'
))
if
(
document_exists
(
$file
))
{
$content
=
Markdown
(
file_get_contents
(
$path
));
return
View
::
make
(
'docs::page'
)
->
with
(
'content'
,
document
(
$file
));
}
else
{
return
Response
::
error
(
'404'
);
}
return
View
::
make
(
'docs::page'
)
->
with
(
'content'
,
$content
);
});
\ No newline at end of file
bundles/docs/views/home.blade.php
deleted
100644 → 0
View file @
2af60594
@
layout
(
'docs::template'
)
@
section
(
'content'
)
<
h1
>
Learn
the
terrain
.</
h1
>
<
p
>
You
've landed yourself on our default home page. The route that
is generating this page lives in the main routes file. You can
find it here:
</p>
<pre>APP_PATH/routes.php</pre>
<!--
<pre class="prettyprint lang-php linenums">
return array(
'
welcome
' => '
Welcome
to
our
website
!
',
);
</pre>
-->
<p>And the view sitting before you can be found at:</p>
<pre>APP_PATH/views/home/index.php</pre>
<h1>Create something beautiful.</h1>
<p>
Now that you'
re
up
and
running
,
it
'
s
time
to
start
creating
!
Here
are
some
links
to
help
you
get
started
:
</
p
>
<
ul
>
<
li
><
a
href
=
"http://laravel.com"
>
Official
Website
</
a
></
li
>
<
li
><
a
href
=
"http://forums.laravel.com"
>
Laravel
Forums
</
a
></
li
>
<
li
><
a
href
=
"http://github.com/laravel/laravel"
>
GitHub
Repository
</
a
></
li
>
</
ul
>
@
endsection
bundles/docs/views/menu.blade.php
deleted
100644 → 0
View file @
2af60594
<h2>
Documentation
</h2>
<ul>
<li><a
href=
"#"
>
Menu Item
</a></li>
<li><a
href=
"#"
>
Menu Item
</a></li>
<li><a
href=
"#"
>
Menu Item
</a>
<ul>
<li><a
href=
"#"
>
Sub Menu Item
</a></li>
<li><a
href=
"#"
>
Sub Menu Item
</a></li>
</ul>
</li>
<li><a
href=
"#"
>
Menu Item
</a></li>
<li><a
href=
"#"
>
Menu Item
</a></li>
<li><a
href=
"#"
>
Menu Item
</a>
<ul>
<li><a
href=
"#"
>
Sub Menu Item
</a></li>
<li><a
href=
"#"
>
Sub Menu Item
</a></li>
<li><a
href=
"#"
>
Sub Menu Item
</a></li>
</ul>
</li>
<li><a
href=
"#"
>
Menu Item
</a></li>
<li><a
href=
"#"
>
Menu Item
</a></li>
<li><a
href=
"#"
>
Menu Item
</a></li>
<li><a
href=
"#"
>
Menu Item
</a></li>
<li><a
href=
"#"
>
Menu Item
</a></li>
<li><a
href=
"#"
>
Menu Item
</a></li>
<li><a
href=
"#"
>
Menu Item
</a></li>
</ul>
\ No newline at end of file
bundles/docs/views/template.blade.php
View file @
5d3cc6be
...
...
@@ -5,8 +5,9 @@
<meta
http-equiv=
"X-UA-Compatible"
content=
"IE=edge,chrome=1"
>
<title>
Laravel: A Framework For Web Artisans
</title>
<meta
name=
"viewport"
content=
"width=device-width"
>
{{ Asset::styles(); }}
{{ Asset::scripts(); }}
{{ HTML::style('laravel/css/style.css') }}
{{ HTML::style('laravel/js/modernizr-2.5.3.min.js') }}
</head>
<body
onload=
"prettyPrint()"
>
<div
class=
"wrapper"
>
...
...
@@ -14,10 +15,7 @@
<h1>
Laravel
</h1>
<h2>
A Framework For Web Artisans
</h2>
<p
class=
"intro-text"
>
You have successfully installed the Laravel framework. Laravel is a simple framework
that helps web artisans create beautiful, creative applications using elegant, expressive
syntax. You'll love using it.
<p
class=
"intro-text"
style=
"margin-top: 45px;"
>
</p>
</header>
<div
role=
"main"
class=
"main"
>
...
...
@@ -30,6 +28,6 @@
</div>
</div>
{{ HTML::script('http://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js') }}
{{
Asset::container('footer')->scripts();
}}
{{
HTML::script('laravel/js/prettify.js')
}}
</body>
</html>
public/laravel/css/style.css
View file @
5d3cc6be
...
...
@@ -141,6 +141,14 @@ body
margin-top
:
2.2em
;
}
div
.home
>
h2
:not
(
:first-child
)
{
margin-top
:
2.2em
;
}
div
.home
>
h2
{
font-size
:
14pt
;
}
.content
>
h3
{
font-size
:
12pt
;
}
...
...
@@ -159,6 +167,12 @@ body
margin-bottom
:
1em
;
}
div
.home
li
{
line-height
:
1.5em
;
margin-bottom
:
1em
;
}
a
,
a
:visited
{
color
:
#2972A3
;
...
...
@@ -235,11 +249,6 @@ code
text-shadow
:
1px
1px
0
#fff
;
}
.home
{
font-size
:
1.1em
;
}
.out-links
{
margin
:
0
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment