Drag and Drop not working in OFA when modulename contains hyphens

dbs

[url="https://onkel-franky.de"]https://onkel-franky.de[/url]

dbs

QuoteAt least in PHP are hyphens in variable names not allowed
Therefore the info.php rename whitespaces and hyphens to underscore. But something work not right in my test.
Maybe the installer can't do it right in the zip.
[url="https://onkel-franky.de"]https://onkel-franky.de[/url]

DarkViper

it's a rule and not a bug.
Quote from: https://secure.php.net/manual/en/language.variables.basics.phpVariable names follow the same rules as other labels in PHP. A valid variable name starts with a letter or underscore, followed by any number of letters, numbers, or underscores. As a regular expression, it would be expressed thus: '[a-zA-Z_\x7f-\xff][a-zA-Z0-9_\x7f-\xff]*'
Unfortunately, I do not know OFA to the last detail but only from a short review of the code. Especially not the JS parts.
However, I have seen that in different places the module name is also used as a variable name. As well as table names and field names in the database.
At least in PHP are hyphens in variable names not allowed (see Quote). Likewise, mySql can cause problems in strict mode. Also, I can vaguely remember that JS has several problems here too.
The simplest and most important solution is not to use hyphens in module names. There are absolutely no factual reasons for their use.

Manuela
[url=http://www.youtube.com/watch?v=tmzDAz6ZvFQ]Der blaue Planet[/url] - er ist nicht unser Eigentum - wir haben ihn nur von unseren Nachkommen geliehen[br]
[i]"You have to take the men as they are... but you can not leave them like that !" :-P [/i]
[i]Das tägliche Stoßgebet: [b]Oh Herr, wirf Hirn vom Himmel ![/b][/i]

astricia

And some other strange behaviour:

When I have two sections of the same OFA module - and I call them via SectionPicker on another page - then the first one will be in the correct order, the second one will be in reversed order! Why is that???

Noch mal auf Deutsch, weil es vielleicht sonst zu kompliziert ist: Ich habe zwei Abschnitte des gleichen OFA-Moduls auf verschiedenen Seiten. Auf einer Übersichtsseite rufe ich diese beiden Abschnitte mit dem SectionPicker auf. Der erste Abschnitt wird genauso dargestellt wie auf der Original-Seite. Aber beim zweiten Abschnitt ist die Reihenfolge vertauscht - das letzte Element steht oben, und das erste unten. Wieso???

LG,
Astrid

dbs

Dietmar will have a look. But today some problems with internet (Unitymedia).
[url="https://onkel-franky.de"]https://onkel-franky.de[/url]

astricia

Hmm... in the info.php it says, that hyphens and underscores are allowed. And I could install it. And it seemed to work fine. Until I tried to change the order of some fields....

dbs

Can't install a module with modulname and directoryname "one-for-all".
Invalid chars.
[url="https://onkel-franky.de"]https://onkel-franky.de[/url]

astricia

Just noticed this bug - when the name for an OneForAll-module contains a hyphen (-), the Drag and Drop function for Fields and Entries does not work .... ! Anybody can confirm?

Astrid