-
Posts
6,808 -
Joined
-
Last visited
-
Days Won
159
Everything posted by Soma
-
There's a permission for allowing editor to use the translator in PW 2.73. I could need this but it doesn't work. It shows the "Language" in the menu but when opening the page it says no entries to show. Anybody has some experience using the lang-edit permission for editor?
- 2 replies
-
- editor
- translation
-
(and 1 more)
Tagged with:
-
Some basics when working in OO software. If you print_r() a object (ie page or field), PHP will traverse the object (try to) and load all its references recursively. It unfolds the object which isn't really present in the original object and only loaded or accesses it if you would do call stuff on this object. This doesn't mean the object contains all the stuff you see printed at that time before you call print_r(). Edit: Oh a page field contains only a reference (by the id) to the page and loads the page object and not even its content unless you call it (except autojoin fields).
-
It's also perfect for xml, json, [insert any datatype] .... .
-
No it's not supported as the Module just renders the page structure. But it can be manipulated/faked in some ways with JS. And that's what I do if it's needed, cause it's a usability feature and something that doesn't really belong there, in the nature of a menu UL structure and the source. So I think it's ok to do that client side. Some example to do it. The "has_children" and "parent" come from the module and need to be removed to avoid false styling/information. $navigation = $('.wrapper .navigation'); // generate "overview links“ for each submenu $navigation.find('li:has(ul)').each(function() { $this = $(this); var classes = $this.attr('class'); var $link = $this.find('>a'); var href = $link.attr('href'); var $item = $('<li class="' + classes + '"><a href="' + href + '">' + $link.text() + '</a></li>'); $item.removeClass("has_children"); $item.removeClass("parent"); $this.find('>ul').prepend($item); }); Edit: this is recursive over all levels. So all li's that has a UL. If you only want for the first level you'd adapt the find() to find(">li:has(ul)").
-
So i think thats the problem when enabling pageFilesecure. The files suddenly cant be accessed even if published and should be accessible for a guest user cause the pages under admin are protected. Im not sure how MM works. But maybe giving guest access to MM templates in admin could solve that but not sure what the consequences are.
-
Not true, any logged in user that has edit/view access can view a unpublished page not only superusers. Add a page and upload a image. The image is in assets folder now and anyone can view that file in browser if you have the path. Even if you trash the page or unpublish page. This is where pageFilesecure comes in to avoid that.
-
Yes I tested and it's about the same ratio except all a little lower. Like 20ms - 26ms Rendertime, TTFB 130ms - 170ms
-
Testing this a little further. Stock Install, Debug off. Default Advanced Profile. MAMP PHP 5.6.10 / OPC off PW2 Boottime: ~120ms PW3 Boottime: ~80ms PW2 Rendertime Home: ~30ms (start of init, end of _main.php) PW3 Rendertime Home: ~36ms (start of init, end of _main.php) PW2 TTFB Chrome: ~170ms PW3 TTFB Chrome: ~240ms Not sure why the TTFB is so much higher.
-
My test are also a clean installs 2.73 and 3.0.42 (default profile, no changes, except File Compiler disabled) locally on same Server/MYSQL/PHP without any cache. The difference is there around 30% slower measured in Chrome TTFB refreshing a couple times to get a average. Not sure how your test results are the other way around.
-
Yep same server.
-
I can confirm this even without testing. I noticed that ProcessWIre is getting slower and slower each iteration. Even 2.73 was slower than all the previous. But seeing what all gets added to PW of course the overhead grows. Also PW is very heavy on the server side and especially DB side and it can get somewhat slow really fast and produces tons of queries. We have very big and complex sites that suffer from some sort of performance issues due to so many table joins and not well indexed tables (said our hoster). We also are currently letting them investigate and may have some details soon. I just did a quick install of 2.73 and 3 master, and can confirm the ~30% slower.
-
Where comes the this from? Is this a class? Complete code? Usually it's because of the scope. Inside function you don't have this. Try this somewhere before ajax(): var that = this; then in the callback functions: that._Pagelist.set()
-
I don't know how your menu dropdown logic works but you have 'has_children_class' => 'dropdown', That adds to the <li classs="..."> and you have 'inner_tpl' => '<ul class="dropdown">||</ul>',
-
I just updated the Captain Hook cheatseheet to latest version 3.x now there's a master and dev version. Thanks to @owzim for providing a cli script to parse the repos automaticly and generate a array to use. It helps a lot to update. https://somatonic.github.io/Captain-Hook/index.html
- 52 replies
-
- 14
-
-
There's various ways to do it. Simplest maybe to ignore certain templates use the selector option. ie "template!=blog".
-
The class is on the li if you don't change the options to not do it. You currently add the active class ot the a element yourself in the options. The list tpl misses the %s which will get replaced with the state classes. It should be default 'list_tpl' => '<li%s>||</li>', And default is this 'item_current_tpl' => '<a href="{url}">{title}</a>',
-
@diogo No never experienced that. I can bootstrap normally. What version are you using?
-
Thanks for reporting. I think it's kind of a mess The newest dev2 version doesn't have hooks (ready()) as to let the internal url for a page untouched. Therefor the replacing href urls on the render output and adding a request logic to redirect to the multisite url was necessary. Unfortunately this leads to problems to the setup you have. It currently assuming the multi domains are setup all in the root. I'm not seeing through all this as it gets kinda complex and not sure how the login can be changed to achieve what setup you have.
-
Moved to "Dev Talk" as it's not PW related.
-
I think that should still work. A domain as root (just no config for it) and other domains on the parent root. But then links won't get parsed correctly, as it doesn't "know" the main domain.
-
No, the new versions does only support to have all domains in the root.
-
That's why the settings are in config.php https://github.com/somatonic/Multisite/tree/dev2#add-multisitedomains You'd have a config already for both so it's just a matter of having different domain and the root in PW stays the same.
-
Wanted to mention that there's a new dev version https://github.com/somatonic/Multisite/tree/dev2 that we are testing and using right now. It was tested and works with multilanguage and PW3 various features.
-
That plugin for c5 seems to do exactly same approach and share same issues. It mentioned as for simple use cases. Only difference is that their plugin costs 80 bugs.
-
I have no idea to be honest. I would also remove the autoload config since it a process module that shouldn't be autoload as it's loaded when the admin page is loaded. Also would add the other module infos as needed like summary. Otherwise I never had any problem with this. I would recommend giving all the infos about your setup and versions. And try the ProcessHello I linked to, if that installs ok. Otherwise you may have some other related problem with your install.