Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
J
joshine
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
joshine
Commits
96cc922d
Commit
96cc922d
authored
Feb 25, 2023
by
lmf
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'developer' into production
parents
f5b41254
70c39dc0
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
2 deletions
+8
-2
app/code/Joshine/Banner/view/frontend/templates/index.phtml
+8
-2
No files found.
app/code/Joshine/Banner/view/frontend/templates/index.phtml
View file @
96cc922d
...
@@ -4,6 +4,12 @@ $collection = $block->getCollection();
...
@@ -4,6 +4,12 @@ $collection = $block->getCollection();
?>
?>
<div
class=
"banner1"
style=
"background-color: #f0f0f0;"
></div>
<div
class=
"banner1"
style=
"background-color: #f0f0f0;"
></div>
<?php
$_objectManager
=
\Magento\Framework\App\ObjectManager
::
getInstance
();
//instance of\Magento\Framework\App\ObjectManager
$storeManager
=
$_objectManager
->
get
(
'Magento\Store\Model\StoreManagerInterface'
);
$currentStore
=
$storeManager
->
getStore
();
$mediaUrl
=
$currentStore
->
getBaseUrl
(
\Magento\Framework\UrlInterface
::
URL_TYPE_MEDIA
)
;
?>
<?php
foreach
(
$collection
->
getItems
()
as
$item
)
:?>
<?php
foreach
(
$collection
->
getItems
()
as
$item
)
:?>
<?
php
echo
$item
->
getData
(
'name'
);
?>
<?
php
echo
$item
->
getData
(
'name'
);
?>
...
@@ -16,8 +22,8 @@ require(['jquery','banner'],function ($){
...
@@ -16,8 +22,8 @@ require(['jquery','banner'],function ($){
[
[
<?php
foreach
(
$collection
->
getItems
()
as
$item
)
:?>
<?php
foreach
(
$collection
->
getItems
()
as
$item
)
:?>
[
[
<?
php
echo
"'
/media/"
.
$item
->
getData
(
'img_patch'
)
.
"',"
;
?>
<?
php
echo
"'
"
.
$mediaUrl
.
$item
->
getData
(
'img_patch'
)
.
"',"
;
?>
<?php
echo
"'
/media/"
.
$item
->
getData
(
'phone_img_patch'
)
.
"',"
;
?>
<?php
echo
"'
"
.
$mediaUrl
.
$item
->
getData
(
'phone_img_patch'
)
.
"',"
;
?>
],
],
<?php
endforeach
;
?>
<?php
endforeach
;
?>
];
];
...
...
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