Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
makura-2025
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
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Raj Shah
makura-2025
Commits
98d33317
Commit
98d33317
authored
Jun 02, 2025
by
rajshah
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
footer menu dynamic
parent
52f68e49
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
33 additions
and
19 deletions
+33
-19
footer.php
footer.php
+30
-18
functions.php
functions.php
+3
-1
No files found.
footer.php
View file @
98d33317
...
@@ -84,24 +84,36 @@
...
@@ -84,24 +84,36 @@
<footer
class=
"background-dark section-footer"
>
<footer
class=
"background-dark section-footer"
>
<div
class=
"container"
>
<div
class=
"container"
>
<div
class=
"footer-links"
>
<div
class=
"footer-links"
>
<div
class=
"footer-link-wrapper"
>
<?php
<strong
class=
"text-uppercase text-white"
>
Quick Links
</strong>
function
footer_menu_makura
(
$theme_location
,
$default_title
)
<ul>
{
<li><a
href=
"#"
>
Home
</a></li>
$locations
=
get_nav_menu_locations
();
<li><a
href=
"#"
>
About
</a></li>
if
(
!
isset
(
$locations
[
$theme_location
]))
{
<li><a
href=
"#"
>
Services
</a></li>
return
;
<li><a
href=
"#"
>
Contact
</a></li>
}
</ul>
$menu
=
wp_get_nav_menu_object
(
$locations
[
$theme_location
]);
</div>
if
(
!
$menu
||
empty
(
$menu
->
name
))
{
<div
class=
"footer-link-wrapper"
>
return
;
<strong
class=
"text-uppercase text-white"
>
Services
</strong>
}
<ul>
$menu_title
=
esc_html
(
$menu
->
name
?:
$default_title
);
<li><a
href=
"#"
>
Wordpress Development
</a></li>
?>
<li><a
href=
"#"
>
Search Engine Optimization (SEO)
</a></li>
<div
class=
"footer-link-wrapper"
>
<li><a
href=
"#"
>
Promotional Video
</a></li>
<strong
class=
"text-uppercase text-white"
>
<?php
echo
$menu_title
;
?>
</strong>
<li><a
href=
"#"
>
UI/UX Design
</a></li>
<ul>
</ul>
<?php
</div>
wp_nav_menu
([
'theme_location'
=>
$theme_location
,
'container'
=>
false
,
'menu_class'
=>
''
,
]);
?>
</ul>
</div>
<?php
}
footer_menu_makura
(
'quick-link'
,
'Quick Links'
);
footer_menu_makura
(
'services'
,
'Services'
);
?>
<div
class=
"footer-link-wrapper"
>
<div
class=
"footer-link-wrapper"
>
<strong
class=
"text-uppercase text-white"
>
Socials
</strong>
<strong
class=
"text-uppercase text-white"
>
Socials
</strong>
<ul
class=
"socials"
>
<ul
class=
"socials"
>
...
...
functions.php
View file @
98d33317
...
@@ -252,7 +252,9 @@ function my_custom_pagination($numpages = '', $pagerange = '', $paged = '', $sea
...
@@ -252,7 +252,9 @@ function my_custom_pagination($numpages = '', $pagerange = '', $paged = '', $sea
register_nav_menus
(
register_nav_menus
(
array
(
array
(
'menu-web'
=>
esc_html__
(
'Primary Menu'
,
'makura'
)
'menu-web'
=>
esc_html__
(
'Primary Menu'
,
'makura'
),
'quick-link'
=>
esc_html__
(
'Quick Links'
,
'makura'
),
'services'
=>
esc_html__
(
'Services'
,
'makura'
)
)
)
);
);
...
...
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