<span class="qte-attr qte_31_32-qte">3.1.x & 3.2.x</span>
[phpBB Debug] PHP Warning : in file [ROOT]/vendor/twig/twig/src/Template.php on line 359 : Array to string conversion
Array
dmzx
Founder
Status:
Offline
User theme: Dark
Posts: 6485 Joined: Jan 13th, '14, 20:45
Post
by dmzx » Sep 22nd, '15, 21:21
Extension Name: Switches
Author: dmzx
Special thanks to: martin
Extension Description:
This extension will add some switches.
dmzx/Switches
Screenshot:
None
3.3 version can be found here
Switches
Extension Download:
Installation:
Download the latest release.
Unzip the downloaded release, and change the name of the folder to `switches `.
In the `ext ` directory of your phpBB board, create a new directory named `dmzx ` (if it does not already exist).
Copy the `switches ` folder to `/ext/dmzx/ ` if done correctly, you'll have the main extension class at (your forum root)/ext/dmzx/switches/composer.json
Navigate in the ACP to `Customise -> Manage extensions`
Look for `Switches ` under the Disabled Extensions list, and click its `Enable ` link.
[phpBB Debug] PHP Warning : in file [ROOT]/vendor/twig/twig/src/Template.php on line 359 : Array to string conversion
Array
martin
Admin
Status:
Offline
User theme: Dark
Posts: 5123 Joined: Apr 6th, '14, 14:12
Post
by martin » Sep 22nd, '15, 21:23
Screenshot
22.png
Example of html code should look like
Code: Select all
<!-- IF SWITCHES_ENABLE_FIRST -->
<div style="position: absolute; margin: -12px 0 0 -48px ">
<img src="{ROOT_PATH}images/cornerhatbig.png" alt="Santa hat" />
</div>
<!-- ENDIF -->
note the
<!-- IF SWITCHES_ENABLE_FIRST --> in the code and image ?
You do not have the required permissions to view the files attached to this post! Maybe your post count is too low.
[phpBB Debug] PHP Warning : in file [ROOT]/vendor/twig/twig/src/Template.php on line 359 : Array to string conversion
Array
nelflucifer
Users
Status:
Offline
User theme: Dark
Posts: 70 Joined: Jan 3rd, '16, 11:24
Post
by nelflucifer » Jan 19th, '16, 17:27
You do not have the required permissions to view the files attached to this post! Maybe your post count is too low.
Last edited by nelflucifer on Jan 25th, '16, 09:32, edited 1 time in total.
[phpBB Debug] PHP Warning : in file [ROOT]/vendor/twig/twig/src/Template.php on line 359 : Array to string conversion
Array
Helios
Users
Status:
Offline
User theme: Dark
Posts: 14 Joined: Sep 27th, '15, 22:27
Post
by Helios » Jan 21st, '16, 13:14
You do not have the required permissions to view the files attached to this post! Maybe your post count is too low.
[phpBB Debug] PHP Warning : in file [ROOT]/vendor/twig/twig/src/Template.php on line 359 : Array to string conversion
Array
martin
Admin
Status:
Offline
User theme: Dark
Posts: 5123 Joined: Apr 6th, '14, 14:12
Post
by martin » Dec 27th, '20, 16:46
Updated to work on 3.3
Screenshot from 2020-12-27 16-45-52.png
dmzx_switches_1_0_0.zip
Code: Select all
{% if SWITCHES_ENABLE_FIRST %}
<div style="position: absolute; margin: -12px 0 0 -48px ">
<img src="{ROOT_PATH}images/cornerhatbig.png" alt="Santa hat" />
</div>
{% endif %}
or you can do it this way
Code: Select all
{% if SWITCHES_ENABLE_FIRST %}
<div id="hat1"></div>
{% endif %}
and put css in a css file
Code: Select all
position: absolute;
margin: -12px 0 0 -48px;
background-image: url(images/cornerhatbig.png alt="Santa hat");
You do not have the required permissions to view the files attached to this post! Maybe your post count is too low.