?
avatar smanzi
smanzi
23 Nov 2014

With 3.4.0 Alpha when "Install from Web" is set to be the first tab of "Extension Manager" (which is the default), just a "Loading..." message is displayed.

Moving the "Tab Position" to "Last" (in the plugin management) solves the issue: the JED content is displayed

This has been first raised by Omar (omar@intelliplans.com) and confirmed by Brian Teeman.

avatar smanzi smanzi - open - 23 Nov 2014
avatar brianteeman brianteeman - change - 23 Nov 2014
Status New Confirmed
avatar dgt41
dgt41 - comment - 23 Nov 2014

This seems to be the tabs js here.
Go to the install from URL (last tab)
Clear the local storage
Navigate elsewhere and then return to http://localhost/administrator/index.php?option=com_installer
JS error
Clear your browsers console
Go to the install from URL (last tab)
Navigate elsewhere and then return to http://localhost/administrator/index.php?option=com_installer
No error!

This must be due to changes for the sidebar because in my console I get:

undefined is not a function (evaluating 'value.removeClass('active')’)
avatar smanzi
smanzi - comment - 23 Nov 2014

What I get when accessing the first tab is: TypeError: value.removeClass is not a function

avatar dgt41
dgt41 - comment - 23 Nov 2014

Try to test this
Go to /plugins/installer/webinstaller/webinstaller.php
replace lines 125-127 with:

jQuery('#myTabTabs li').parent().find(‘li').removeClass("active”);
avatar dgt41
dgt41 - comment - 23 Nov 2014

@smanzi Can you make a PR with that?

avatar smanzi
smanzi - comment - 23 Nov 2014

Yep... but this is not in Joomla!! This is pulled when one accept to have the web installer...

avatar dgt41
dgt41 - comment - 23 Nov 2014

Sorry forgot to tell you that it has to be against https://github.com/joomla-extensions/install-from-web-client

avatar smanzi
smanzi - comment - 23 Nov 2014

... and your fix does break the whole thing here: no more tabs in Extension Manager!

avatar smanzi
smanzi - comment - 23 Nov 2014

If you have working code, send me the whole file via email, I'll take care of the rest...

avatar dgt41
dgt41 - comment - 23 Nov 2014

are you on Skype?

avatar smanzi
smanzi - comment - 23 Nov 2014

yes, wait

avatar dgt41
dgt41 - comment - 23 Nov 2014

Delete this 3 lines and place the code above!

avatar smanzi
smanzi - comment - 23 Nov 2014

PR on its way... (after testing that it does not break 3.3.6...)

avatar smanzi
smanzi - comment - 24 Nov 2014

Someone please help: the code available at https://github.com/joomla-extensions/install-from-web-client is version 1.1.0, while the version pulled by joomla 3.4.0 Alpha when one accept to install "Install from Web" is version 1.0.5

  • Is there a mistake in what 3.4.0 pulls?
  • where is the repo for 1.0.5?
avatar dgt41
dgt41 - comment - 24 Nov 2014

@mbabker any idea why we have older version shipping with 3.4? The repo seems to have 1.1.0 as current...

avatar mbabker
mbabker - comment - 24 Nov 2014

The update server that gets read is still showing 1.0.5 as the latest version, so that's what Joomla is picking up. See http://appscdn.joomla.org/webapps/jedapps/webinstaller.xml

So if they have tagged a new release, that XML file needs updating.

avatar dgt41
dgt41 - comment - 24 Nov 2014

There are 0 tag releases in that repo. You know who’s in charge for this?

avatar mbabker
mbabker - comment - 24 Nov 2014

@beat I believe this is your team?

avatar smanzi
smanzi - comment - 24 Nov 2014

I have a PR (code by @dgt41) ready, but that repo with 1.1.0 in it has a lot of stuff that doesn't apply (even jQuery.js, tu support Joomla! 2.5) in it...

avatar smanzi
smanzi - comment - 24 Nov 2014

OK, PR is joomla-extensions/install-from-web-client#6 but as I said I'm unsure if the repo is the good one.

Code working on 3.4.0 Alpha
To be tested with older revs...

avatar dgt41
dgt41 - comment - 24 Nov 2014

@smanzi just in case someone doesn’t like the change made here this is also working:

            jQuery('#myTabTabs ul>li').each(function(index, value){
                value.removeClass('active');
            });
avatar smanzi
smanzi - comment - 24 Nov 2014

@dgt41 Pushed!

avatar infograf768
infograf768 - comment - 24 Nov 2014

and tested OK here.

avatar brianteeman
brianteeman - comment - 24 Nov 2014

@test latest version works for me - what has to be done now for that version to be the one that is installed @beat

This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/5180.

avatar Kubik-Rubik
Kubik-Rubik - comment - 24 Nov 2014

@dgt41 Good solution, tested successfully!

This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/5180.

avatar beat
beat - comment - 26 Nov 2014

@mbabker + @brianteeman Thanks for the pings and sorry for the little delay in replying, was drawn under water of work last days.

Started the AppStore team on that PR joomla-extensions/install-from-web-client#6

@dgt41 Thanks for the fixing PR proposal: At first glance and before deeper review, wondering why making the jquery css selector more selective solves the issue, but maybe you can reply directly on the PR 6 linked above ? Are you sure that this would not be a workaround for the real bug that seems at very first glance to be in the tabs handler of Joomla 3.4 (and thus a B/C) ? (not wanting to push any fault nor work, but just want to understand why that javascript fatal error is triggered by (at first glance) just adding a class to the dom ?)

avatar brianteeman
brianteeman - comment - 27 Nov 2014

closing this here as it is being handled at http://joomla-extensions/install-from-web-client#6

This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/5180.

avatar jissues-bot jissues-bot - close - 27 Nov 2014
avatar jissues-bot
jissues-bot - comment - 27 Nov 2014
avatar brianteeman brianteeman - change - 27 Nov 2014
Status Confirmed Closed
avatar jissues-bot jissues-bot - change - 27 Nov 2014
Status Confirmed Closed
Closed_Date 0000-00-00 00:00:00 2014-11-27 21:22:57
avatar beat
beat - comment - 27 Nov 2014

@brianteeman This is a bug of Joomla 3.4. The workaround proposal at http://joomla-extensions/install-from-web-client#6 is just a workaround hiding this Joomla bug. Think this one should not be closed (even if the workaround is being code-reviewed by AppStore Team and could be included in the next update).

avatar brianteeman brianteeman - change - 27 Nov 2014
Status Closed Confirmed
avatar brianteeman
brianteeman - comment - 27 Nov 2014

OK I am reopening but this needs to be solved by someone ad I dont care who that it is but its a showstopper. Raising priority

This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/5180.

avatar jissues-bot
jissues-bot - comment - 27 Nov 2014
avatar jissues-bot jissues-bot - reopen - 27 Nov 2014
avatar brianteeman brianteeman - change - 27 Nov 2014
Priority Medium Urgent
avatar Bakual
Bakual - comment - 27 Nov 2014

I would love to have a look but can't reproduce it on my testing servers with current staging. Tried with Chrome and IE11 and on two different servers (Linux and Windows).

avatar dgt41
dgt41 - comment - 27 Nov 2014

@beat I come to a conclusion after testing many different things here that the problem here is not the extra selector that I put on the script but the fact that sidebar is also using local storage and somehow this conflicts with the tabs. If someone can verify this maybe we can fix it in the root e.g. core.js.
Clear your local storage data
Enable debug and comment out lines 229, 248, 263 in media/system/core-uncompressed.js
The problem should not exist!

avatar dgt41
dgt41 - comment - 27 Nov 2014

@beat @Bakual and anyone that follows this

I found a solution that doesn’t require any changes in webinstaller, only a minor in core.js (the sidebar stuff)
Instead of

        // Load the value from localStorage
        if (typeof(Storage) !== "undefined")
        {
            var $visible = localStorage.getItem(context);
        }

we can safely use this:

        // Load the value from localStorage
        if (!!localStorage.getItem)
        {
            var $visible = localStorage.getItem(context);
        }

In all three different places the code uses typeof(Storage) !== “undefined”

Can someone confirm that?

avatar smanzi
smanzi - comment - 27 Nov 2014

@dgt41 I was willing to give your solution a try, but... I don't have the issue anymore!
I've tried uninstalling and reinsatalling "Install from Web" a couple of times, but... no way!
Are you still on the originally released alpha or do you have the latest "staging" code?
I've updated to the latest staging this morning (for other reasons)...

avatar dgt41
dgt41 - comment - 27 Nov 2014

No I am on alpha...

avatar dgt41
dgt41 - comment - 27 Nov 2014

Actually I have also the staging but you are right only 3.4Alpha has the problem

avatar smanzi
smanzi - comment - 27 Nov 2014

I think something changed: I can't swear on that, but I've seen a correction this morning that COULD be related...
do you have the link for downloading the original alpha at hand?

avatar dgt41
dgt41 - comment - 27 Nov 2014
avatar smanzi
smanzi - comment - 27 Nov 2014

silly me! hold on, I download, compare and let you know...

avatar smanzi
smanzi - comment - 27 Nov 2014

hhhmmm... can't find the diff that jumped to my eye this morning: it was the concatenation of two strings, something that went from:

$result = $string1 . '_' . $string2;

to

$result = $string1 . '.' . $string2;

... or vice-versa...

avatar dgt41
dgt41 - comment - 27 Nov 2014

You mean this ?

avatar smanzi
smanzi - comment - 27 Nov 2014

YES!

avatar smanzi
smanzi - comment - 27 Nov 2014

anything to do with this? I was surprised because I couldn't relate it to any recently view PR...

avatar dgt41
dgt41 - comment - 27 Nov 2014

And we have a winner here!
Congrats @smanzi
The problem here is not sidebar’s js or web installer js it was a conflict with this #5205, and since this is already merged in the staging I'll say to close this one!

avatar smanzi
smanzi - comment - 27 Nov 2014

:sunglasses:

... pure luck! (...or nose!)

avatar dgt41
dgt41 - comment - 27 Nov 2014

avatar smanzi
smanzi - comment - 27 Nov 2014

should I close this?

avatar dgt41
dgt41 - comment - 27 Nov 2014

YES

avatar smanzi
smanzi - comment - 27 Nov 2014

... and I'll also close the PR for "Install for Web"!

avatar smanzi smanzi - close - 27 Nov 2014
avatar smanzi smanzi - change - 27 Nov 2014
Status Confirmed Closed
Closed_Date 2014-11-27 21:22:57 2014-11-27 22:54:31
avatar brianteeman
brianteeman - comment - 27 Nov 2014

Sorry it is not fixed for me.
I redownloaded the current staging and installed the plugin.It just sits
their saying loading
However as soon as you leave the tab and return to it then it magically has
appeared
See https://www.dropbox.com/s/r0e69j7vhnuspcf/tab.mp4?dl=0

On 27 November 2014 at 22:51, Dimitris Grammatiko notifications@github.com
wrote:

avatar smanzi
smanzi - comment - 27 Nov 2014

oops... Strange? Have you tried uninstalling "Install from Web" and the install it back again?

avatar brianteeman brianteeman - change - 27 Nov 2014
Status Closed Confirmed
avatar jissues-bot jissues-bot - change - 27 Nov 2014
Status Closed New
avatar jissues-bot jissues-bot - reopen - 27 Nov 2014
avatar jissues-bot
jissues-bot - comment - 27 Nov 2014
avatar brianteeman
brianteeman - comment - 27 Nov 2014

That was on a CLEAN intall

This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/5180.

avatar smanzi
smanzi - comment - 27 Nov 2014

OK... Don't know what to say....

avatar dgt41
dgt41 - comment - 27 Nov 2014

@brianteeman can you please try my solution on core.js few comments above?

avatar brianteeman
brianteeman - comment - 27 Nov 2014

no change - sorry - and bedtime for me

This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/5180.

avatar smanzi
smanzi - comment - 27 Nov 2014

@dgt41 I can confirm Brian issue: same s**t on fresh install...
I'm going to try your solution...

avatar dgt41
dgt41 - comment - 27 Nov 2014

@smanzi Please make sure to replace all three instances of if (typeof(Storage) !== "undefined”)
with if (!!localStorage.getItem)
I tested and it even works on IE8!

avatar smanzi
smanzi - comment - 27 Nov 2014

f**k, it is minified... can you send me your copy by Skype? Opening now...

avatar dgt41
dgt41 - comment - 27 Nov 2014

just copy the uncompressed from core-uncompressed.js and then make the changes...

avatar brianteeman
brianteeman - comment - 27 Nov 2014

no change for me - you have to click off the tab for it to work - that was
in a new browser with empty cache

On 27 November 2014 at 23:19, Dimitris Grammatiko notifications@github.com
wrote:

@smanzi https://github.com/smanzi Please make sure to replace all three
instances of if (typeof(Storage) !== "undefined”)
with if (!!localStorage.getItem)
I tested and it even works on IE8!


Reply to this email directly or view it on GitHub
#5180 (comment).

Brian Teeman
Co-founder Joomla! and OpenSourceMatters Inc.
http://brian.teeman.net/

avatar smanzi
smanzi - comment - 27 Nov 2014

@dgt41 OK, and... HAPPY BIRTHDAY!!! :birthday:

avatar dgt41
dgt41 - comment - 27 Nov 2014

Thanks Sergio! But my solution is not actually a solution. Back to zero here!

avatar smanzi
smanzi - comment - 27 Nov 2014

Confirmed: it is not.... Installed from scratch (but with your core.js) and I still have the issue... WTF!, but WHY it had disappeared, before???

avatar smanzi
smanzi - comment - 27 Nov 2014

2 errors in console:

Empty string passed to getElementById(). jquery.min.js:2
TypeError: value.removeClass is not a function
avatar smanzi
smanzi - comment - 27 Nov 2014

Anyway, the behavior is now different: when I first opened this issue the "Install from Web" tab HAD to be put last to see it working. Now it is enough to click on another tab and the go back to it and it will work.

avatar dgt41
dgt41 - comment - 28 Nov 2014

OK Had enough here
Lets simplify this to one line

jQuery('#myTabTabs').find('li').removeClass("active”);

AND call it a day or keep on searching why the current jQuery lines are not behaving sensible!

avatar smanzi
smanzi - comment - 28 Nov 2014

Do you want me to change that in joomla-extensions/install-from-web-client#6 ?

... and agree: had enough of this!

avatar smanzi
smanzi - comment - 28 Nov 2014

... and shouldn't it be each() instead of find() ?

avatar dgt41
dgt41 - comment - 28 Nov 2014

One line is better than three and also indexing a list of maximum 5 elements is not gonna give efficiency or performance boost.

avatar smanzi
smanzi - comment - 28 Nov 2014

OK: going to change, then!

avatar dgt41
dgt41 - comment - 28 Nov 2014

And by the way the current code that web installer is using is miracle that is working so far. Take a look here

avatar smanzi
smanzi - comment - 28 Nov 2014

... isn't li missing in your JSFiddle jQuery() script?

avatar dgt41
dgt41 - comment - 28 Nov 2014

You can add it and still get the error! WE are looking that something else is wrong when in the first place the actual code here is not functional!

avatar smanzi
smanzi - comment - 28 Nov 2014

Confirmed! And your code run smoothly...

avatar smanzi
smanzi - comment - 28 Nov 2014

TypeError: value.removeClass is not a function ... I've seen that before... :stuck_out_tongue_winking_eye:

avatar dgt41
dgt41 - comment - 28 Nov 2014

The old code could also work

jQuery('#myTabTabs li').each(function(index, value){
                jQuery(value).removeClass('active');
            });

demo: http://jsfiddle.net/13ppwk5t/3/

avatar smanzi
smanzi - comment - 28 Nov 2014

it "runs", but it doesn't remove the "active" class...

avatar dgt41
dgt41 - comment - 28 Nov 2014

Sorry Sergio I posted the wrong link. updated!

avatar smanzi
smanzi - comment - 28 Nov 2014

At this point I'm wondering if removing "active" is needed at all...

avatar dgt41
dgt41 - comment - 28 Nov 2014

I’ll dream about it…

avatar smanzi
smanzi - comment - 28 Nov 2014

ahahahhahah! I hope you'll have better dreams!!!

avatar smanzi
smanzi - comment - 29 Dec 2014

This has been solved. Closing issue.

avatar zero-24 zero-24 - close - 29 Dec 2014
avatar smanzi smanzi - close - 29 Dec 2014
avatar smanzi smanzi - change - 29 Dec 2014
Status New Closed
Closed_Date 2014-11-27 22:54:31 2014-12-29 17:13:10
avatar zero-24 zero-24 - change - 7 Jul 2015
Labels Added: ?

Add a Comment

Login with GitHub to post a comment