How to use a new gallery in the image field ?

More
3 years 6 months ago #79346 by lclaude
Hi!

Sorry for the delay, I was very busy. Here is my feedback:

Ok I understood the choice of thubnails. It's cool !

Actually when You clic on 'load' it's not the original picture wich is loaded but the thumbnail, I think You have to change this line :
"panorama": "' . JUri::root(true).'/'.$src . '",
by this one :
"panorama": "' . JUri::root(true).'/'.$srco . '",

Can't understand why there is settings for tablet and mobile *in the desktop tab*
There is not parameters in the Mobile tab
How does it work to have settings in the Mobile tab? Must we create another .xml or add a new section in the existing one?

In the div id="panorama_' I add display: inline-flex; in the style, in order to display multiple panoramas on a single line.

Regards,

Laurent

Please Log in or Create an account to join the conversation.

More
3 years 6 months ago - 3 years 6 months ago #79349 by ggppdk
Hello
regarding your 2 points

1.

Can't understand why there is settings for tablet and mobile *in the desktop tab*


because
-- "Desktop" and "Mobile" Tab load the (XML) configuration file of some gallery
e.g. fancybox gallery parameters, e.g. gallerific gallery parameters

Meaning that the "Desktop" and "Mobile" Tab are loading the full XML file


2. About changing
Code:
"panorama": "' . JUri::root(true).'/'.$src . '",
to
Code:
"panorama": "' . JUri::root(true).'/'.$srco . '",

yes, it should be $srco
($src is meant for the preview: setting)

i have committed the fix


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star...
Last edit: 3 years 6 months ago by ggppdk.

Please Log in or Create an account to join the conversation.

More
3 years 6 months ago #79351 by lclaude
Hello,

Thanks, that's cool !

I have add a display: inline-flex; style, in the .php:
Code:
<div id="panorama_' . $uniqueid . '" style="width: ' . $w . 'px; height: ' . $w . 'px; max-width: 100%; max-height: ' . $vp_max_height . 'vh; display: inline-flex;"></div>

I have change the 'title' variable, and added 'author', like this :
Code:
"title": "' . $desc_encoded . '", "author": "' . $title_encoded .'",

And add 3 variables, for Pannellum features:
Code:
$Pannellum_autoRotate = (int) $field->parameters->get( $PPFX_ . 'autoRotate', 3 ); $Pannellum_orientationOnByDefault = (int) $field->parameters->get( $PPFX_ . 'orientationOnByDefault', 1 ); $Pannellum_showZoomCtrl = (string) $field->parameters->get( $PPFX_ . 'showZoomCtrl', 'true' );

So, the 'script' section become :
Code:
<div id="panorama_' . $uniqueid . '" style="width: ' . $w . 'px; height: ' . $w . 'px; max-width: 100%; max-height: ' . $vp_max_height . 'vh; display: inline-flex;"></div> <script> pannellum.viewer(\'panorama_' . $uniqueid . '\', { "type": "equirectangular", "panorama": "' . JUri::root(true).'/'.$srco . '", "preview": "' . $ABS_SRC . '", "title": "' . $desc_encoded . '", "author": "' . $title_encoded .'", "autoRotate": "' . $Pannellum_autoRotate .'", "orientationOnByDefault": "' . $Pannellum_orientationOnByDefault . '", "showZoomCtrl": "' . $Pannellum_showZoomCtrl . '" }); </script>


And in the .xml:
Code:
<field name="" type="separator" default="Pannellum options" level="level1" /> <field name="Pannellum_autoRotate" type="number" default="-5" label="Autorotate (°/s)" description="Setting this parameter causes the panorama to automatically rotate when loaded. The value specifies the rotation speed in degrees per second. Positive is counter-clockwise, and negative is clockwise" /> <field name="Pannellum_orientationOnByDefault" type="multilist" subtype="radio" default="1" toggle_related="1" label="Device orientation" description="If set to true, device orientation control will be used when the panorama is loaded, if the device supports it. If false, device orientation control needs to be activated by pressing a button." class="btn-group btn-group-yesno" depend_class=""> <option value="0">FLEXI_NO</option> <option value="1">FLEXI_YES</option> </field> <field name="Pannellum_showZoomCtrl" type="multilist" subtype="radio" default="true" toggle_related="1" label="Show zoom controls" description="If set to false, the zoom controls will not be displayed." class="btn-group btn-group-yesno" depend_class=""> <option value="0">FLEXI_NO</option> <option value="true">FLEXI_YES</option> </field>

Laurent

Please Log in or Create an account to join the conversation.

Moderators: vistamediajoomlacornerggppdk
Time to create page: 0.275 seconds
Save
Cookies user preferences
We use cookies to ensure you to get the best experience on our website. If you decline the use of cookies, this website may not function as expected.
Accept all
Decline all
Essential
These cookies are needed to make the website work correctly. You can not disable them.
Display
Accept
Analytics
Tools used to analyze the data to measure the effectiveness of a website and to understand how it works.
Google Analytics
Accept
Decline