« Note to self; "Unable to find valid target platform" means "hey, install the core product first" when installing the Notes client | Main| Engaged at Engage 2017 in Antwerpen, Belgium! »

How to get XPages and Bootstrap3_xxx themes to work (or how to check that XPages is correctly installed)?

Tags: Lotus Notes Xpages Question
0

Warning – Not that experienced XPages programmer here Smile 

I have been fiddling around with the Single Page Application control in XPages, but I never got it to work properly with the Bootstrap3, or Bootstrap3_flat themes. In fact it only worked with OneUI before FP8. I supect that I have some issue with XPages on the server.

Below you see a screen shot of the result in Chrome;

image

My question is therefore – Does anybody know how to check if XPages is is properly installed on the server? I search around and find some details, but a lot of the information seems somewhat old (2014’ish), and the nomenclature seems different now and pretty fragmented. I guess I am also a little confused about what features that still needs ExtLib and what has been moved to the core product with FP8.

The environment is a Domino Win32 9.0.1 FP8 server;

SNAGHTML1d5b5942

The server was once installed as a Domino 7 server and has been upgraded as every new version, fixpack and feature pack has arrived.

I use an UpdateSite-database to install plugins such as XPages Extension Library and SmartNSF (both brilliant softwares!). Right now it looks like this;

image

As you see I have installed the latest XPages Extension Library (version 901v00_17.20160428-0214) from OpenNTF.

One place I saw something about using the Action –> Delete All in the UpdateSite-database, and so I did, restarted the server, and Imported the ExtLib server files from the updateSiteOpenNTF.zip again. A final restart of the server was done.

So as far as I can understand, I now should have both the latest and greatest XPages stuff coming along with the FP8-install, in addition to the latest ExtLib as shown above.

I have seen posts that I can issue the command “tell http osgi ss com.ibm.xsp.extlib” to see what level XPages features have, and on my system that yields;

> tell http osgi ss com.ibm.xsp.extlib
21.03.2017 08:44:19   Framework is launched.
21.03.2017 08:44:19   id    State       Bundle
21.03.2017 08:44:19   16    INSTALLED   com.ibm.xsp.extlib_9.0.1.v00_17_20160428-0214
21.03.2017 08:44:19   17    INSTALLED   com.ibm.xsp.extlib.core_9.0.1.v00_17_20160428-0214
21.03.2017 08:44:19   20    INSTALLED   com.ibm.xsp.extlib.oneui_9.0.1.v00_17_20160428-0214
21.03.2017 08:44:19   23    RESOLVED    com.ibm.xsp.extlibx.controls_9.0.1.v00_16_20160119-2239
21.03.2017 08:44:19   24    ACTIVE      com.ibm.xsp.extlibx.theme.bootstrap4_9.0.1.v00_16_20160119-2239
21.03.2017 08:44:20   25    INSTALLED   com.ibm.xsp.extlib.domino_9.0.1.v00_17_20160428-0214
21.03.2017 08:44:20   29    ACTIVE      com.ibm.xsp.extlibx_9.0.1.v00_16_20160119-2239
21.03.2017 08:44:20   30    INSTALLED   com.ibm.xsp.extlib.mobile_9.0.1.v00_17_20160428-0214
21.03.2017 08:44:20   31    INSTALLED   com.ibm.xsp.extlib.controls_9.0.1.v00_17_20160428-0214
21.03.2017 08:44:20   33    INSTALLED   com.ibm.xsp.extlib.relational_9.0.1.v00_17_20160428-0214
21.03.2017 08:44:20   37    <<LAZY>>    com.ibm.xsp.extlibx.core_9.0.1.v00_16_20160119-2239
21.03.2017 08:44:20   130    RESOLVED    com.ibm.xsp.extlib.controls.nl1_9.0.1.v08_00_20170223-0757
21.03.2017 08:44:20                   Master=133
21.03.2017 08:44:20   131    RESOLVED    com.ibm.xsp.extlib.controls.nl2_9.0.1.v08_00_20170223-0757
21.03.2017 08:44:20                   Master=133
21.03.2017 08:44:20   132    RESOLVED    com.ibm.xsp.extlib.controls.nl3_9.0.1.v08_00_20170223-0757
21.03.2017 08:44:20                   Master=133
21.03.2017 08:44:20   133    ACTIVE      com.ibm.xsp.extlib.controls_9.0.1.v08_00_20170223-0757
21.03.2017 08:44:20                   Fragments=130, 131, 132
21.03.2017 08:44:20   134    RESOLVED    com.ibm.xsp.extlib.core.nl1_9.0.1.v08_00_20170223-0757
21.03.2017 08:44:20                   Master=137
21.03.2017 08:44:20   135    RESOLVED    com.ibm.xsp.extlib.core.nl2_9.0.1.v08_00_20170223-0757
21.03.2017 08:44:20                   Master=137
21.03.2017 08:44:20   136    RESOLVED    com.ibm.xsp.extlib.core.nl3_9.0.1.v08_00_20170223-0757
21.03.2017 08:44:20                   Master=137
21.03.2017 08:44:20   137    ACTIVE      com.ibm.xsp.extlib.core_9.0.1.v08_00_20170223-0757
21.03.2017 08:44:20                   Fragments=134, 135, 136
21.03.2017 08:44:20   138    RESOLVED    com.ibm.xsp.extlib.domino.nl1_9.0.1.v08_00_20170223-0757
21.03.2017 08:44:20                   Master=141
21.03.2017 08:44:20   139    RESOLVED    com.ibm.xsp.extlib.domino.nl2_9.0.1.v08_00_20170223-0757
21.03.2017 08:44:20                   Master=141
21.03.2017 08:44:20   140    RESOLVED    com.ibm.xsp.extlib.domino.nl3_9.0.1.v08_00_20170223-0757
21.03.2017 08:44:20                   Master=141
21.03.2017 08:44:20   141    ACTIVE      com.ibm.xsp.extlib.domino_9.0.1.v08_00_20170223-0757
21.03.2017 08:44:20                   Fragments=138, 139, 140
21.03.2017 08:44:20   142    RESOLVED    com.ibm.xsp.extlib.mobile.nl1_9.0.1.v08_00_20170223-0757
21.03.2017 08:44:20                   Master=145
21.03.2017 08:44:20   143    RESOLVED    com.ibm.xsp.extlib.mobile.nl2_9.0.1.v08_00_20170223-0757
21.03.2017 08:44:20                   Master=145
21.03.2017 08:44:20   144    RESOLVED    com.ibm.xsp.extlib.mobile.nl3_9.0.1.v08_00_20170223-0757
21.03.2017 08:44:20                   Master=145
21.03.2017 08:44:20   145    ACTIVE      com.ibm.xsp.extlib.mobile_9.0.1.v08_00_20170223-0757
21.03.2017 08:44:20                   Fragments=142, 143, 144
21.03.2017 08:44:20   146    RESOLVED    com.ibm.xsp.extlib.oneui.nl1_9.0.1.v08_00_20170223-0757
21.03.2017 08:44:20                   Master=149
21.03.2017 08:44:20   147    RESOLVED    com.ibm.xsp.extlib.oneui.nl2_9.0.1.v08_00_20170223-0757
21.03.2017 08:44:20                   Master=149
21.03.2017 08:44:20   148    RESOLVED    com.ibm.xsp.extlib.oneui.nl3_9.0.1.v08_00_20170223-0757
21.03.2017 08:44:20                   Master=149
21.03.2017 08:44:20   149    ACTIVE      com.ibm.xsp.extlib.oneui_9.0.1.v08_00_20170223-0757
21.03.2017 08:44:20                   Fragments=146, 147, 148
21.03.2017 08:44:20   150    RESOLVED    com.ibm.xsp.extlib.relational.nl1_9.0.1.v08_00_20170223-0757
21.03.2017 08:44:20   151    RESOLVED    com.ibm.xsp.extlib.relational.nl2_9.0.1.v08_00_20170223-0757
21.03.2017 08:44:20   152    RESOLVED    com.ibm.xsp.extlib.relational.nl3_9.0.1.v08_00_20170223-0757
21.03.2017 08:44:20   153    ACTIVE      com.ibm.xsp.extlib.relational_9.0.1.v08_00_20170223-0757
21.03.2017 08:44:20   154    ACTIVE      com.ibm.xsp.extlib_9.0.1.v08_00_20170223-0757

Not entirely clear to me what version I do have, but I suspect that the extlib_9.0.1.v08_00_20170223-0757 is the ExtLib from the FP8, right?

Ok. My application was created some time ago and did actually work fine with the One UI theme.

Below you see the XPage Properties for the database;

image

I have tried to set the Bootstrap3_flat theme on both places. Below is the “Page Generation” tab;

image

When I upgraded to FP8, the Designer complained about the com.ibm.xsp.extlibx.library wasn’t found anymore. This is one of the spots that make me uncertain about the installation. I know that some parts get moved from the ExtLibX to the ExtLib from time to time. And now also some parts has been moved from ExtLib to the core. Well, you see that the only setting I have visible now, is the com.ibm.xsp.extlib.library.

The “Source” tab of the XPages Properties file holds these variables;

xsp.ajax.renderwholetree=false
xsp.client.script.radioCheckbox.ie.onchange.trigger=early-onclick
xsp.error.page.default=true
xsp.library.depends=com.ibm.xsp.extlib.library
xsp.persistence.mode=file
xsp.resources.aggregate=true
xsp.theme.mobile.pagePrefix=m_
xsp.theme=Bootstrap3_flat
xsp.min.version=9.0.100.v08
xsp.application.forcefullrefresh=true
xsp.theme.mobile=Bootstrap3_flat

Symptoms that something is wrong

If I click any of the links in the following page;

SNAGHTML1d9241b7

… I get this;

SNAGHTML1d932dec

Translated that means something like “com.ibm.xsp.FacesExceptionEx: java.io.IOException: "infiniteScroll”-property is not support for the current theme (null)”.

If I for fun change the theme back to the OneUI, things look like this;

SNAGHTML1d94eacf

.. And the page look like this;

SNAGHTML1d95a005

Something isn’t being downloaded properly, and if I launch Chrome’s Developer Toolbox I see this;

SNAGHTML1d976bcc

If I try to access one of the pages in the SPA-application, I get this;

“_1.doc.getCSSCanvasContext is not a function”

The following console debug is also shown;

image

If anybody recognizes what is going on here, it would be fantastic!

Comments

Gravatar Image1 - I had tried the same thing. It seems that Chrome/Android had deprecated getCSSCanvasContext, so where you may find SPA works in iOS, it won't in Android devices. I've not tried it yet but { Link } may let you do an infinite scroll without the getCSSCanvasContext.

Gravatar Image2 - Hi,
I've never checked to see if "XPages is installed correctly" because for me it always has been. It's just part of the server. Now components like the ext. library, yes they might have issues and you can check on them with various comments - a search on StackOverFlow should get that in short order.

I'm not exactly sure what you're trying to do but I know this - The "Single Page Application" control lives under the Mobile Controls section of the control pallet. Those controls, as far as I know, are specific for "Mobile Controls" as provided by the Dojo Framework. They need Dojo css styling to work. I would not think that they are in any way "Bootstrap compatible". I would think you need to pick one or the other.

If you're looking to build a mobile based application your 2 built in choices are :
1- Use XPages Mobile Controls
2- Use Bootstrap and rely on the responsive grid to size for a particular device.

Now how do you choose between the two? That's up to you of course but I can say that the "XPages Mobile Controls" are the most horridly evil controls out there. They're Horcruxes. They're the fires from Mordor. They're VX nerve gas. They are a plague. If it was possible to "De-invent" something then Mobile controls would be on that list. They are evil incarnate. The Pacific Ocean was formed from the tears of XPage Developers trying to use Mobile Controls.

I recommend between the 2 you would be better off focusing on Bootstrap - the most popular css framework in the world with tons of examples and documentation and questions answered, the Mobile Controls.

There's an XPages Slack Chat available ({ Link } if you want to discuss this more with other XPages Developers.






Gravatar Image3 - @Brian, thanks for the input. I was wondering if only I was the only person experiencing this Emoticon Also I was kind of uncertain whether this is related to the "other" errors I have...

Gravatar Image4 - @David, thanks a lot for very thorough explanation! And yes, I have always thought that XPages kind of worked out of the box just by installing it. That is why I was so uncertain when things obviously looks a tad weird just by selecting the available choices in the XPages Properties. In fact, that is where I do see the "Bootstrap3" and "Bootstrap3_flat" themes in the first place. To me that looks like Bootstrap is indeed included somehow in the core product now.

Well, it is also difficult to not see your *WARNING* sign about the "Mobile Controls" and the controls therein. Perhaps that is why IBM chose to hide them too by default after installing FP8? Emoticon.

I will therefore rather try the mix-in-Bootstrap-yourself approach. I have seen some nice tutorials on how to do this somewhere too. Again, thanks a lot!

Post A Comment

:-D:-o:-p:-x:-(:-):-\:angry::cool::cry::emb::grin::huh::laugh::lips::rolleyes:;-)