Welcome, Guest
Username: Password: Remember me

TOPIC: [FIXED] Use of undefined constant DS

[FIXED] Use of undefined constant DS 14 Jun 2013 07:27 #7471

  • liubov
  • liubov's Avatar
  • Offline
  • Elite Member
  • (=) 10 mn and it's ready!
  • Posts: 279
  • Thank you received: 36
  • Karma: 22
Hi Joce,

I am preparing the FrontEnd Interface (J3.0) to present the datas of my Project. (don't worry, I am in Projet mode ;p)

I got an error when creating a New Menu Item in the Menu Manager.

First, Warning :
Notice: Use of undefined constant DS - assumed 'DS' in D:\wamp\www\joomla3.1\administrator\components\com_xxxxxx\models\fields\modal\systeme.php on line 28

Second, Error due to the unknown DS constant :
Fatal error: require_once() [function.require]: Failed opening required 'D:\wamp\www\joomla3.1\administrator\components\com_xxxxxxx\models\fields\modalDSitem.php' (include_path='.;C:\php\pear') in D:\wamp\www\joomla3.1\administrator\components\com_xxxxxxx\models\fields\modal\systeme.php on line

Could you check this point?
Last Edit: 14 Jun 2013 07:44 by liubov.
The administrator has disabled public write access.
The following user(s) said Thank You: admin

Re: Use of undefined constant DS 15 Jun 2013 08:17 #7475

  • admin
  • admin's Avatar
  • Offline
  • Administrator
  • Chef
  • Posts: 3711
  • Thank you received: 987
  • Karma: 140
Yes, maybe a bug here.

I may rewrite some parts about the modals and pickable fields.

In facts, when a menu item is created, your component is not fully loaded. (The loader is not called)
Only the pickables fields are loaded.

The solution, you can define DS = DIRECTORY_SEPARATOR in the header of :
models/fields/modal/item.php (base class for pickables fields)

Good catch, must sort it out...
Coding is now a piece of cake
The administrator has disabled public write access.

Re: Use of undefined constant DS 15 Jun 2013 09:36 #7477

  • liubov
  • liubov's Avatar
  • Offline
  • Elite Member
  • (=) 10 mn and it's ready!
  • Posts: 279
  • Thank you received: 36
  • Karma: 22
OK,

yes, of course, it's what I've done to create the Item Menu, without error ...

Hoo, The 15th is today !!! Lot of work for you !

Good luck.
The administrator has disabled public write access.

Re: Use of undefined constant DS 15 Jun 2013 11:46 #7478

  • admin
  • admin's Avatar
  • Offline
  • Administrator
  • Chef
  • Posts: 3711
  • Thank you received: 987
  • Karma: 140
I will migrate in thoses few days, not all at once.

Today (now), I am migrating and processing the last clone.
Means that you will now work in the new website (still .net)
.pro will still be available for the forum, but not for the builder.

Still are some issues, but this will always continue all the way long.
Now it is the time for changes...
Coding is now a piece of cake
The administrator has disabled public write access.

Re: Use of undefined constant DS 18 Jun 2013 16:15 #7561

  • admin
  • admin's Avatar
  • Offline
  • Administrator
  • Chef
  • Posts: 3711
  • Thank you received: 987
  • Karma: 140
Fixed.

Now, the loader is instancied when you try to reach a field. Modal picker, or simple field.

So, from the menu item, your component loader is called.
With the loader, the classes are not all loaded in memory, only registered.

It means that if you need one of your component class, the loader knows where to find the file. In this case, only the used PHP classes are loaded in memory.
Coding is now a piece of cake
The administrator has disabled public write access.

Re: Use of undefined constant DS 19 Jun 2013 03:29 #7570

  • liubov
  • liubov's Avatar
  • Offline
  • Elite Member
  • (=) 10 mn and it's ready!
  • Posts: 279
  • Thank you received: 36
  • Karma: 22
I have to make fews changes...
I will check this with the next component update...

thank you.
The administrator has disabled public write access.
Time to create page: 0.084 seconds

Get Started