Leaderboard
Popular Content
Showing content with the highest reputation on 04/23/2012 in all areas
-
My latest work, done in PW 2.1.0 www.voetvolk.be Lisbeth Gruwez|Voetvolk is a dance/performance group founded around dancer/choreographer Lisbeth Gruwez and composer/musician Maarten Van Cauwenberghe. Since its foundation in 2007, it has developed its activities as an international contemporary dance and performance company. Lisbeth Gruwez|Voetvolk functions as an autonomous and independent structure, relying on a network of co-producers and partners to realize its projects. Lisbeth Gruwez and Maarten Van Cauwenberghe are ‘Artists-in-Residence’ in the Troubleyn /Laboratorium of Jan Fabre. Sylvio2 points
-
I am using: $config->styles->removeAll(); $config->scripts->removeAll(); on each template, before anything similar to yours snippet above, formmailer!2 points
-
Works with many to many too. $prs = $pages->find("title=Zoo|Theme park|Museum"); // maybe also use the name or id $poi = $pages->find("template=poi, poi_type=$prs"); EDIT: corrected code. yours doesn't work because "get" will return only 1 page and not page array.2 points
-
I am starting an initiative for Slovak translation of ProcessWire. Any participants are welcome. https://github.com/rzelnik/ProcessWire-Slovak-Language-Pack1 point
-
Also wanted to add that using $config->styles or $config->scripts on your own site is totally optional, unless you are using some module that requires them (none of the core modules do). They were designed for use by the admin template. I rarely use them myself, but if they suit your needs on the front-end, then no harm in using them.1 point
-
For a field that can contain multiple images, the value of that field is always going to be a type of array. So you'd have to either check to see if there are any items in the array, or try to retrieve the first time like Soma did. Here's how I usually check if there are any images: if(count($page->images)) { // images here } else { // no images } When it comes to a single image field, you are dealing with just one item that is either set or it isn't (rather than an array). You only need to check if it has a value: if($page->image) { // image here } else { // no image } When you use $pages->find(), $pages->get(), $page->children(), etc., you can also find pages that have a given amount of images. So if you wanted to find pages that don't have any images, you could do this: $pages->find("images.count=0"); ...or pages that have one or more images: $pages->find("images.count>0");1 point
-
1 point
-
I have all multi-language related modules activated. I have successfully changed all fields to TextLanguage, TextareaLanguage etc. When I try to change the Title field from PageTitle to PageTitleLanguage and confirm the change, it shows this error: Recoverable Fatal Error Argument 1 passed to LanguagesPageFieldValue::__construct() must be an array, string given, called in /[path_to_pw]/wire/modules/LanguageSupport/LanguageSupportFields.module on line 301 and defined (line 33 of /[path_to_pw]/wire/modules/LanguageSupport/LanguagesPageFieldValue.php) This error message was shown because you are logged in as a Superuser. Error has been logged. How can I change the Title field to multi-lingual? UPDATE: I have compared the database dumps before the change and after the change. The only difference is this: table `fields`: < (1, 'FieldtypePageTitle', 'title', 13, 'Title', '{\"required\":1,\"textformatters\":[\"TextformatterEntities\"],\"size\":0,\"maxlength\":255}'), > (1, 'FieldtypePageTitleLanguage', 'title', 13, 'Title', '{\"required\":1}'), Reported also on Gitub: https://github.com/r...sWire/issues/98 UPDATE2: I have reproduced this error on a fresh new installation. I have found that this error doesn't occur when I create a second language before changing the title to PageTitleLanguage.1 point
-
Steve, just also noticed a horizontal scroll. I don't think I've hurt anything in doing the following... It looks as if the fix for the nav is the following two rule removals, the second addresses the horizontal scroll: #nav { position: absolute; top: 26px; left: 220px; /* width: 340px; */ font-size: 12px; } .nav { font-size: 12px; /* width: 100%; */ z-index: 100; } Cheers, -Alan1 point
-
Of coarse... I must of been over tired last night... After replacing default jquery-1.4.2.min.js with jquery.min.js it works fine! Wonder if all those versions of jQuery are different somehow. Well, the site is on its way of being all sizes of screen friendly! http://www.sebagokayakcompany.com1 point
-
This: $page->ref_page; doesn't return the id, it returns the whole page object (echoes the id though, but var_dumb shows the truth). So no need to get(id), because you already have the correct page. This is what you are looking for: $page->ref_page->title; EDIT: And if you do need the id, it can be get with this: $page->ref_page->id;1 point
-
If you first installed PW seperately on your remote server and later imported your database tables from your local dev setup, I guess the userAuthSalt strings in your local and remote config files (right at the bottom of them) differ. As the string is used to encode your password when saved in the database as well as the one entered on login, this may cause your well-known password being rejected, when the userAuthSalt was changed. EDIT: Ah, I just saw that the topic is also addressed in the thread Arjen pointed you to.1 point
-
Just wanted to say thanks to all of you for helping me out with this, it works perfectly as expected, if a user has the credentials I can send him off to another template with private information and if they don't they'll just see the normal page. The client can add all the necessary information under one entry so this is very powerful and easy at the same time!1 point
-
Do try a table repair... (could be) Adit: - or try opening a childpage and change something and save it. - or sort the last page to first place Also try trace 1 page (id) in the db table where the sort field is. Before and after you sort change one page in the admin, what happens in the db table? Does it change anything?1 point
-
<?php if ($page->photo->eq(0)) { ?> <img src="<?php echo $page->photo->eq(0)->url; ?>" alt="<?php echo $page->photo->eq(0)->description; ?>"> <?php } else { ?> <img src="<?php echo $config->urls->templates; ?>pics/nophoto.png" alt="Sorry, no picture available"> <?php } ?>1 point
-
I get a 403 (forbidden) for all of them. Seems like LiteSpeed is taking care of the security issues: - Only LiteSpeed supports .htaccess with Apache compatibility. - Only LiteSpeed has a rewrite engine compatible with Apache mod_rewrite. - Only LiteSpeed has request filtering compatible with Apache mod_security - Only LiteSpeed can work flawlessly with control panels written for Apache Source: http://www.litespeedtech.com/hosting-control-panel-litespeed-web-server-=-the-best-choice-for-web-hosting.html -Peter1 point
-
I am using the latest PW commit. I will try to send a link to exported site profile by email, hoping it will make things easier. Thanks!1 point
-
I suggest you read this thread too. Especially the part why not to use FTP, because of rights issues. Ryan outlined some alternatives which I use since then.1 point
-
Jasper - that is probably because it is kind of special case: process module that is also autoload module (because it needs to sniff the 404 visits). I will fix this soon, thanks for letting me know.1 point