Differ then few days ago, when I set the text in a field on the footer (i.e. $w( ‘#textGroup’ ).text =“foo” ) in one page, I see the new value of it in other pages as expected, BUT in code it returns its initial value as set in the editor, and ignore the new value set on the other page.
This happen only on live site and not in preview.
This was not the situation few days ego.
Did WIX changed something?
Nimrod
Please post the URL of your site, and explain exactly where the problem is (page, code, etc).
The editor URL of the site is:
https://editor.wix.com/html/editor/web/renderer/edit/1c5b841a-4018-46cd-a7bf-e898d6a8f3ae?metaSiteId=14eb7614-d1cb-464b-97b6-9352b3038e50&editorSessionId=f619bef8-9598-4524-bc9e-658efe20545b
In page home at onReady I set the text of field on the footer (line in red):
$w.onReady(function () {
let session = $w('#textSession').text;
///reset next session
console.log("session: " + session);
switch (session) {
case '0': ///first time here. we will show welcomes and goToSim(1, g) on "buttonSimulationA_click"
$w('#boxLogin').show();
$w('#textSession').text = '1';
setPath('park');
In page chair at onReady I read it
$w.onReady(function () {
//TODO: write your page related code here...
//setBarrier();///must run before buildSVG, now alwayes return Barriers1
//setTarget();///must run before buildSVG, now alwayes return POLY_PARK
//setPath('park');/// target & barriers intilized when swiching pages!
//buildSVG();
//console.log("onReady in chair: " + $w('#textSession').text);
$w('#boxExplainChair1').show();
$w('#boxTryTitle').show();
let groupType = $w('#textGroup').text;
console.log( "onready1: " + $w('#textGroup').text);//////
let session = parseInt($w('#textSession').text,10);
console.log( "onready2: " + $w('#textSession').text);//////
console.log( "onready session: " + session);//////
if (groupType.charAt((session-1)+2) === 'S') {
On preview it return the text (as on the screen).
On live it return the original text set on the field in the editor (new behavior)
If you want to run it you can use user number 20702
So I gotta be honest. I’m running this site but don’t see what’s not working - or what’s working. Just not sure what I’m looking for.
if you look on the log in console you can see that you get different results on preview and live in the logs I set in the above snippets .
The result is that after you end the first 3 steps (trial session) you get instruction about ב instead of א and if you continue you will end after 1 session instead of two (as planned for the students).