Skip to content

Commit

Permalink
replace mobile_detect function used default on joomla isMobile();
Browse files Browse the repository at this point in the history
  • Loading branch information
Alexon Balangue committed Sep 15, 2016
1 parent aeba3c0 commit 08b9eea
Show file tree
Hide file tree
Showing 6 changed files with 21 additions and 15 deletions.
13 changes: 9 additions & 4 deletions index.php
Expand Up @@ -13,6 +13,7 @@
$apps = JFactory::getApplication();
$docs = JFactory::getDocument();
$users = JFactory::getUser();
$browser = JBrowser::getInstance();
$this->language = $docs->language;
$this->direction = $docs->direction;

Expand Down Expand Up @@ -118,10 +119,14 @@


require_once dirname(__FILE__).DIRECTORY_SEPARATOR.'html'.DIRECTORY_SEPARATOR.'renderer'.DIRECTORY_SEPARATOR.'head.php';
require_once JPATH_SITE.DIRECTORY_SEPARATOR.'media'.DIRECTORY_SEPARATOR.'mod_opensource'.DIRECTORY_SEPARATOR.'Mobile_Detect.php';
$detect = new Mobile_Detect;
$JMobileDetectHeader = $detect->isMobile() && $detect->isTablet() ? '<jdoc:include type="modules" name="banner-mheader" style="nones" />' : '<jdoc:include type="modules" name="banner-header" style="nones" />';
$JMobileDetectFooter = $detect->isMobile() && $detect->isTablet() ? '<jdoc:include type="modules" name="banner-mfooter" style="nones" />' : '<jdoc:include type="modules" name="banner-footer" style="nones" />';

if( $browser->isMobile() == true ){
$JMobileDetectHeader = '<jdoc:include type="modules" name="banner-mheader" style="nones" />';
$JMobileDetectFooter = '<jdoc:include type="modules" name="banner-mfooter" style="nones" />';
} else {
$JMobileDetectHeader = '<jdoc:include type="modules" name="banner-header" style="nones" />';
$JMobileDetectFooter = '<jdoc:include type="modules" name="banner-footer" style="nones" />';
}
?>

[doctype html="html" /]
Expand Down
4 changes: 2 additions & 2 deletions language/en-GB/en-GB.tpl_stylish.ini
@@ -1,8 +1,8 @@
TPL_STYLISH_XML_DESCRIPTION="template Stylish innovate starter template by CONCEPTOR - Indicate name "Conceptor, Developper, Designer, referencer, marketor" to cooperate together. <br /> <hr /> Developper by Alexon Balangue for only joomla 3.x<br /> <h3>Version now: 1.3 - For developper &amp; designer (novice/Expert)</h3> <hr /> "
TPL_STYLISH_XML_DESCRIPTION="template Stylish innovate starter template by CONCEPTOR - Indicate name "Conceptor, Developper, Designer, referencer, marketor" to cooperate together. <br /> <hr /> Developper by Alexon Balangue for only joomla 3.x<br /> <h3>Version now: 1.4.1 - For developper &amp; designer (novice/Expert)</h3> <hr /> "
TPL_STYLISH_LOGO_LABEL="Logo"
TPL_STYLISH_LOGO_DESC="Upload a custom logo for the site template. requir images"
TPL_STYLISH_COOKIESEU_HOME="The site uses secure cookies to enhance your experience."
;1.3
;1.4.1

TPL_STYLISH_MENTION_SEARCH_HOME="Search"
TPL_STYLISH_INFORMATION_HOME="Information"
Expand Down
4 changes: 2 additions & 2 deletions language/en-GB/en-GB.tpl_stylish.sys.ini
@@ -1,8 +1,8 @@
TPL_STYLISH_XML_DESCRIPTION="template Stylish innovate starter template by CONCEPTOR - Indicate name "Conceptor, Developper, Designer, referencer, marketor" to cooperate together. <br /> <hr /> Developper by Alexon Balangue for only joomla 3.x<br /> <h3>Version now: 1.3 - For developper &amp; designer (novice/Expert)</h3> <hr /> "
TPL_STYLISH_XML_DESCRIPTION="template Stylish innovate starter template by CONCEPTOR - Indicate name "Conceptor, Developper, Designer, referencer, marketor" to cooperate together. <br /> <hr /> Developper by Alexon Balangue for only joomla 3.x<br /> <h3>Version now: 1.4.1 - For developper &amp; designer (novice/Expert)</h3> <hr /> "
TPL_STYLISH_LOGO_LABEL="Logo"
TPL_STYLISH_LOGO_DESC="Upload a custom logo for the site template. requir images"
TPL_STYLISH_COOKIESEU_HOME="The site uses secure cookies to enhance your experience."
;1.3
;1.4.1

TPL_STYLISH_MENTION_SEARCH_HOME="Search"
TPL_STYLISH_INFORMATION_HOME="Information"
Expand Down
4 changes: 2 additions & 2 deletions language/fr-FR/fr-FR.tpl_stylish.ini
@@ -1,8 +1,8 @@
TPL_STYLISH_XML_DESCRIPTION="thème Stylish innovante à partir du thème de CONCEPTOR - Le nom l'indique "Concepteur, Développeur, Designeur, référencer, marqueteur" en coopérative ensemble. <hr /> Développer Par Alexon Balangue for only joomla 3.x<br /> <h3>Version now: 1.3 - For developper &amp; designer (novice/Expert)</h3> <hr />"
TPL_STYLISH_XML_DESCRIPTION="thème Stylish innovante à partir du thème de CONCEPTOR - Le nom l'indique "Concepteur, Développeur, Designeur, référencer, marqueteur" en coopérative ensemble. <hr /> Développer Par Alexon Balangue for only joomla 3.x<br /> <h3>Version now: 1.4.1 - For developper &amp; designer (novice/Expert)</h3> <hr />"
TPL_STYLISH_LOGO_LABEL="Logo"
TPL_STYLISH_LOGO_DESC="Choisir un logo personnalisé pour le template. requise images"
TPL_STYLISH_COOKIESEU_HOME="Le site utilise les cookies sécurisés pour améliorer votre expérience."
;1.3
;1.4.1
TPL_STYLISH_MENTION_SEARCH_HOME="Recherche"
TPL_STYLISH_INFORMATION_HOME="Information"
TPL_STYLISH_SERVICES_HOME="Services"
Expand Down
4 changes: 2 additions & 2 deletions language/fr-FR/fr-FR.tpl_stylish.sys.ini
@@ -1,8 +1,8 @@
TPL_STYLISH_XML_DESCRIPTION="thème Stylish innovante à partir du thème de CONCEPTOR - Le nom l'indique "Concepteur, Développeur, Designeur, référencer, marqueteur" en coopérative ensemble. <hr /> Développer Par Alexon Balangue for only joomla 3.x<br /> <h3>Version now: 1.3 - For developper &amp; designer (novice/Expert)</h3> <hr />"
TPL_STYLISH_XML_DESCRIPTION="thème Stylish innovante à partir du thème de CONCEPTOR - Le nom l'indique "Concepteur, Développeur, Designeur, référencer, marqueteur" en coopérative ensemble. <hr /> Développer Par Alexon Balangue for only joomla 3.x<br /> <h3>Version now: 1.4.1 - For developper &amp; designer (novice/Expert)</h3> <hr />"
TPL_STYLISH_LOGO_LABEL="Logo"
TPL_STYLISH_LOGO_DESC="Choisir un logo personnalisé pour le template. requise images"
TPL_STYLISH_COOKIESEU_HOME="Le site utilise les cookies sécurisés pour améliorer votre expérience."
;1.3
;1.4.1
TPL_STYLISH_MENTION_SEARCH_HOME="Recherche"
TPL_STYLISH_INFORMATION_HOME="Information"
TPL_STYLISH_SERVICES_HOME="Services"
Expand Down
7 changes: 4 additions & 3 deletions templateDetails.xml
@@ -1,8 +1,8 @@
<?xml version="1.0" encoding="utf-8"?>
<extension version="3.5" type="template" client="site" method="upgrade">
<extension version="3.6" type="template" client="site" method="upgrade">
<name>stylish</name>
<version>1.3</version>
<creationDate>May, 18th 2016</creationDate>
<version>1.4.1</version>
<creationDate>September, 15th 2016</creationDate>
<author>Alexon Balangue</author>
<authorUrl>www.alexonbalangue.me</authorUrl>
<authorEmail>moi.sites@alexonbalangue.me</authorEmail>
Expand All @@ -14,6 +14,7 @@
<filename>offline.php</filename>
<filename>favicon.ico</filename>
<filename>index.php</filename>
<filename>index.html</filename>
<filename>templateDetails.xml</filename>
<filename>template_preview.png</filename>
<filename>template_thumbnail.png</filename>
Expand Down

0 comments on commit 08b9eea

Please sign in to comment.