Skip to content

Fix the path for the spinning logo ajax-loader.gif#15529

Closed
dgrammatiko wants to merge 2 commits intojoomla:stagingfrom
dgrammatiko:####core_js
Closed

Fix the path for the spinning logo ajax-loader.gif#15529
dgrammatiko wants to merge 2 commits intojoomla:stagingfrom
dgrammatiko:####core_js

Conversation

@dgrammatiko
Copy link
Copy Markdown
Contributor

@dgrammatiko dgrammatiko commented Apr 25, 2017

Pull Request for Issue #15305 .

Summary of Changes

Using data attributes for passing php data to javascript is totally fine (and very welcome) but in this particular occasion we need another way, since all the front end templates either need to update to echo this data attribute (not very likely to happen) or will not work.

So lets use the language strings (since what we're passing is just a word/string)...

Testing Instructions

Create a com_content custom field and edit an article from the front end.

Expected result

Actual result

no errorSpinning logo appears correctly, no error 404 not found in the browser's console

Documentation Changes Required

Nope

@brianteeman
Copy link
Copy Markdown
Contributor

I have tested this item 🔴 unsuccessfully on 8745f48

something in this PR is killing things like patchtester


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

@ghost
Copy link
Copy Markdown

ghost commented May 13, 2017

Open without PR an Article, Tab "Content" or Tab "Fields", got in Console/JS: Use of getAttributeNode() is deprecated. Use getAttribute() instead. jquery-migrate.min.js:2:1714

System information

3.7.1-rc1
macOS Sierra, 10.12.4
Firefox 53 (64-bit)

MAMP 4.1.1

  • PHP 7.0.15
  • MySQLi 5.6.35

}

// Define the base path as a string
JText::script('JOOMLA_BASE_PATH', JURI::root(true));
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

that is sad 😄

Copy link
Copy Markdown
Member

@Fedik Fedik May 13, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

JFactory::getDocument()
  ->addScriptOptions('core.root', JUri::root(true))
  ->addScriptOptions('core.base', JUri::base(true));

or joomla.root, whatever 😉

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Fedik sure, that looks more appropriate

@AlexRed
Copy link
Copy Markdown
Contributor

AlexRed commented May 19, 2017

I can confirm the problem on Joomla! 3.7.2-Dev (nightly Build)

@brianteeman
Copy link
Copy Markdown
Contributor

after applying the patch all i get anywhere is

Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 262144 bytes) in C:\Apache24\htdocs\cms\libraries\cms\html\html.php on line 66

Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 262144 bytes) in Unknown on line 0

Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 262144 bytes) in Unknown on line 0

Warning: Unknown: Cannot call session save handler in a recursive manner in Unknown on line 0

@Fedik
Copy link
Copy Markdown
Member

Fedik commented Jun 15, 2017

@DGT41 there an alternative solution #16701

@dgrammatiko dgrammatiko deleted the ####core_js branch July 22, 2017 20:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants