Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
Tenzing
/
Tz Tools
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
0feae26e
authored
2009-09-21 17:02:44 +0000
by
Chris Boden
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
Aercoustics required updates
1 parent
e9a070c8
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
33 additions
and
3 deletions
MenuWidget.php
wp_functions.php
MenuWidget.php
View file @
0feae26
...
...
@@ -20,10 +20,11 @@ class MenuWidget extends WP_Widget {
public
function
widget
(
$args
,
$instance
)
{
static
$all_pages
=
false
;
$display_container
=
false
;
foreach
(
$instance
[
'pages'
]
as
$page
)
{
if
(
$instance
[
'inclusive'
]
==
0
)
{
$instance
[
'child_of'
]
=
$page
;
_list_pages
(
$instance
);
_list_pages
(
$instance
);
// I should probably have the before/after from args in here . . .
continue
;
}
...
...
@@ -45,9 +46,18 @@ class MenuWidget extends WP_Widget {
$instance
[
'exclude'
]
.=
$wp_page
->
ID
;
}
}
if
(
!
$display_container
&&
!
empty
(
$args
[
'before_widget'
]))
{
echo
$args
[
'before_widget'
];
$display_container
=
true
;
}
_list_pages
(
$instance
);
}
if
(
$display_container
)
{
echo
$args
[
'after_widget'
];
}
}
public
function
update
(
$new_instance
,
$old_instance
)
{
...
...
wp_functions.php
View file @
0feae26
...
...
@@ -88,4 +88,24 @@ function _dropdown_pages() {
$params
=
func_get_args
();
return
call_user_func_array
(
'wp_dropdown_pages'
,
$params
);
}
?>
function
_attachment_is_image
()
{
$params
=
func_get_args
();
return
call_user_func_array
(
'wp'
.
__FUNCTION__
,
$params
);
}
function
_get_attachment_thumb_url
()
{
$params
=
func_get_args
();
return
call_user_func_array
(
'wp'
.
__FUNCTION__
,
$params
);
}
function
_get_attachment_metadata
()
{
$params
=
func_get_args
();
return
call_user_func_array
(
'wp'
.
__FUNCTION__
,
$params
);
}
function
_get_attachment_url
()
{
$params
=
func_get_args
();
return
call_user_func_array
(
'wp'
.
__FUNCTION__
,
$params
);
}
?>
\ No newline at end of file
...
...
Please
register
or
sign in
to post a comment