Jump to content

videokid

Members
  • Posts

    154
  • Joined

  • Last visited

Everything posted by videokid

  1. Hi to keep this thread alive lol... I noticed the following // create a text input check for bots $field = $modules->get("InputfieldText"); $field->label = "Veld niet invullen"; // make it multilangual for the future $field->attr('id+name','hmntxt'); $form->append($field); // append the field to the form and then error check var_dump(trim($hmntxt)); if($hmntxt !== ''){ // attach an error to the field // and it will get displayed along the field $hmntxt->error("Opgelet, lees goed, het veld onder 'Veld niet invullen' dan ook niet invullen!"); } results in an error the dump actually works... changing the line to: $email->error("Opgelet, lees goed, het veld onder 'Veld niet invullen' dan ook niet invullen!"); also works [error line shows up under the E-Mail label Did I miss something somewhere... Oh, it's the good old 'honeypot' idea btw Grtz
  2. I've been experimenting with something similar. For now I use the prependTemplateFile and I've changed my homepage fields/template set-up. Actually my homepage is my 'settings-page'... In the _init.php I use: $sitename = $pages->get(1)->site_name; $telephone = $pages->get(1)->site_tel; $siteslogan = $pages->get(1)->site_slogan; that way I did some facebook stuff etc... image etc... if ($page->get('news_mainImage') != ''){ $thumb = $page->news_mainImage->getThumb(thumbnail); $fbImage = 'http://'.$config->httpHost; $fbImage .=$thumb; // $fbImage =$page->news_mainImage->httpUrl; doesn t work? }else{ $fbImage = 'http://'.$config->httpHost; $fbImage .= $config->urls->root; $fbImage .= 'site/templates/styles/images/logo.png'; } That way I can use whatever I want whenever I need and if I made a mistake [e.g. phonenumber has to be changed], only one field has be corrected in the back-end... <title><?php echo $page->get('pagetitle|title'); ?> :: <?php echo $sitename; ?> :: <?php echo $siteslogan; ?></title> the only thing I was wondering... since I'm using it in my "init" file, maybe I should use 'auto join' fields... but that's for later... still experimenting... Am I on the right track, or am I overdoing it? Grtz!
  3. Hi, I'm thinking of creating a website for showing movies. My idea so far was: - movies ---> All Movie Titles - program [or calendar as you like] ---> wednesday 7th of August - Movie 1 ---> Friday 9th of August - Movie 2 @ 10.00 ---> Friday 9th of August - Movie 2 @ 15.00 ---> Sunday 11th of August - Movie 1 @ 21.00 but then I was wondering, maybe inputting a whole week at once might be better... Kinda grid input calendar in the back-end from Wednesday till Thursday. Wednesday is always the first day of the latest releases, more then one movie can appear on one day but never on the same hour, and when 'latest show' is ticked somewhere [should be in the back-end], the latest movie_show_date should be updated under 'movies'. Actually that last one I something I still haven't figured out in PW... Ideas, suggestions, would be very welcome... Thx in advance!
  4. There are no 3rd party multi-language modules installed [actually pretty basic installation], I do however have a little code snippet in my _init.php file if ($modules->isInstalled('LanguageSupport')) { $lang = ($user->language->name == 'default' ? 'nl' : $user->language->name); }else{ $lang = 'nl'; } I've replaced the LanguageSupportPageNames.module with the one provided and the error seems to be gone. Hence my question somewhere if I could change the name 'default', now it makes more sense to me why it's unchangable... I wanted to make my life a bit easier on future installations and get rid of the language thingie, if I need a multi-lang website, I just install one [or more] languages and call the '$lang' when needed Again, thanks for the follow up and the quick response!
  5. Hi Ryan, I was using 2.3.0 [the stable version]. I did what you suggested, but the error remains: Recoverable Fatal Error: Argument 2 passed to LanguageSupportPageNames::getPagePath() must be an instance of Language, boolean given, called in ......\wire\modules\LanguageSupport\LanguageSupportPageNames.module on line 504 and defined (line 288 of ......\wire\modules\LanguageSupport\LanguageSupportPageNames.module) Regards!
  6. OK after writing my previous post I took a different approach... page id 1 = start I've changed the settings, instead of 'start' & 'home' I've changed it to 'nl' and 'en'. So, now I have -Start {8} |-> Films {2} |-> Camping Cosmos |-> Assault on Wall Street Nederlands /nl/films/assault-on-wall-street/ English /en/movies/assault-on-wall-street/ so the basic url structure makes way more sense. However, every link results in a 404 Page Not Found + adding new content still results in the same error report in my initial post. Thx for reading this!
  7. I just did that in my first PW installation, just to see how fast I could mess it up :-D, this installation is pretty standard and has a 'default' language, I did change it to 'Nederlands' and added a new language 'English' with the name 'en'. Yes, correct 'start' is the Dutch version for 'home', but I've read somewhere on the forum the default language doesn't need a 'prefix', so Dutch is my default language, basicly I was expecting this: www.domain.com/films/ www.domain.com/en/movies/ Thank you so far for the answers and tips!
  8. Hi Wanze, sure, but actually it's not a code-snippet. I just try to add a child-page to a page, using 'Languages Support - Page Names'. I have two languages: - default -> Nederlands [and it seems I can't change default, unless in a hacky way phpMyAdmin] - en -> English and although Dutch is default, in the 'new' field for Dutch the URL starts with: /start/films/ and for English /movies/ when hitting 'save' then the error occurs. Thank you in advance.
  9. Recoverable Fatal Error: Argument 2 passed to LanguageSupportPageNames::getPagePath() must be an instance of Language, boolean given, called in 'baseUrl'\wire\modules\LanguageSupport\LanguageSupportPageNames.module on line 324 and defined (line 183 of 'baseUrl'\wire\modules\LanguageSupport\LanguageSupportPageNames.module) I wanted to test out the mulit-lang thingie, not sure if I did something wrong here... Regards!
  10. Thx for the link! I thought so about the JS, it's certainly not a 'real world' issue, at first I was like 'huh', what was that? So I thought, let's mention it, after all the effort you did. Probably nobody will notice it, no doubt... fact remains: very nice website!
  11. Very nice! One thing I noticed, when sizing down the window [not with the min-button], then maximizing again [with max button], the nice background on the left is gone. Only happens on Chrome, not in Opera or FF. Chrome is my default browser btw. That facebook news is very nice, is that a plug-in of some kind? Regards.
  12. if($pages->get(1)->numChildren(true)) { // has children that are really visible to the user } output = 10 [total with 'hidden' pages] echo count($pages->get(1)->children); // output 5, should be 4 echo count($pages->get(1026)->children); // output 3, correct 1 is the root, AFAIK, and I have four subpages, although the number returned is '5' For all other pages that seems to work however... Not sure if I'm missing something, not so important for me ATM, just wanted to mention it...
  13. @teppo, @Ryan Just Saw Ryan's post also... well, that covers it all
  14. Indeed, nice work... Every time I think OK... now I have something solid, let's actually start building a website, I encounter something new here and I want to try it out... Anyway I can live with IE9+, less will get a warning 1 question, why the use of single and double quotations? ex <meta name='description' content='ProcessWire is an open source CMS and web application framework aimed at the needs of designers, developers and their clients. ' /> <link rel="stylesheet" href="/zurb4site/site/templates/foundation/css/foundation.css" /> <div id='topnav'> <div class='contain-to-grid'> <nav class="top-bar"> <ul class="title-area"> why not all " " or am I just being difficult? Regards!
  15. Dearly noted! That immediately opens some ideas Thanks for the info!
  16. Hi Ryan, Thank you for your time posting back. I understand the confusion, I think it was due the fact I was still thinking in my old way... Using the basic tutorial I've set up a page 'page-settings' which has a default Meta Description, so what I was trying to achieve was: if an "article" or anything else for that matter has no meta description, use default 'site-setting' description. In my case $sitedesc = $pages->get(1014)->site_meta_description; So actually, it's not the homepage MetaDescription. That's why I was thinking, instead of using that, just load 'site_meta_description' with "autojoin" or _init.php, unless I misunderstand the purpose... It's in my nature to over complicate easy things... That said, I also found this thread, maybe that's a better/alternate solution: http://processwire.com/talk/topic/4004-meta-descriptions-and-selecting-the-first-n-characters/ In the end I might up using your example, much appreciated. Oh I've already found the multi-language board and I've been reading a lot. I've already tried out the LanguageSupportPageNames. By reading the idea and purpose, that was the reason I've installed PW in the first place. In the end I might up using something like: if ($modules->isInstalled('LanguageSupport')) {$lang = $user->language;} else {$lang = 'nl';} I've been reading a zillion forum posts by now, and somewhere I saw something like 'this must be the friendliest forum ever' and I second that! Greetings!
  17. Well, I think I have the basic hang of it and I've started Just for 'best practice'... I have a site_desc and site_keywords and pretty obvious I'd like to see them appear... However I'd like to use different keywords, and meta description on different pages [ex article short description]. So, should I use 'Autojoin' or should I use the 'init.php'? On top of that, if let's say $page desc is empty --> use $site_desc as default... The language thing is also puzzeling me... default can't be changed. However I'd like to have a standard $lang [ex en, fr, de etc...] in my header when changing the site to mulitlangual. if the Languages Support module is not installed, could it' be that $lang = $user->language; is not working? Thx so far!
  18. Thanks Pete, I will... and I am
  19. No, no hurry at the moment, still in learning process... Seems you're pretty busy. I do appreciate the offer already! With gratitude
  20. Hello Ryan, You are absolutely right, ... although I'm not looking for a large E-Mail solution... more like a convenient automatic 'send out' system for [very] small businesses. Latest news/blog items/products last month etc... Nothing too fancy and well thought out on a small base... I'm using something now and the system sends out 300 mails per hour in bachtes of 5 to about 1500 subscribers. No doubt for large distributions I'm number one to offer a third party solution, especially as you say... not getting black-listed. I've been digging out the forum also and found this one too http://processwire.com/talk/topic/659-newsletter-system-with-pw/ I'll try it out on a later stadium, I'm trying out my first PW installation and using the Basic Website Tutorial.
  21. Thx Teppo for your answer, but a template engine is not really required... It's been a [long] while, but I think I can handle php-templating. However, thx for mentioning the links... who knows... habbits die hard sometimes... I've been searching the modules section, but I can't find a 'newsletter'-system of any kind... correct? The more I've been reading up on these fora, the more and more interesting ProcessWire looks... Regards
  22. Hello Totoff, thanks for the link, anything I can pick-up to understand this system fairly fast is welcome.
  23. Hi Diogo, most of the links you provided, I've seen already, and I know my question was a bit long... but I like to cover enough, and it's always nice to have a second opinion here and there... E-Commerce solution... shopify or any other online application is not an option [that was by request... :-/] Maybe I should contact the author of the module... The other thing I couldn't find so far is an automated newsletter... with interval options, e.g. every two weeks, every month. I'm using something similar now, and it sends out the last posts of the last month [if there are any]... I'm still digging and reading a lot... So far I'm used to the smarty template system and Twig... so I'll have to adapt and figure out things, but of course a learning curve is normal... Anyway, so far I really appreciate your input and my thanks for that. ... back to reading... Kind regards
  24. I hope this is the right topic, if not, I apologize upfront I'd like to set-up a products website with different categories [or sublevels, as you want] where people can comment on the actual product. I'd like the comment to be stored in the database and also be shared on the users facebook wall [of course if he/she's logged in into facebook]. Some of the products are eligible to be sold, so some kind 'add-to-cart' should be possible. I noticed some kind of system here, but if I understand correctly, it's not ready for public use. A contact page with forms, automatically saved in the database, which can be followed up, altered by a third person. Also, some, if approved, to be published on the website. A kind of group/permission system where users can be divided, and a payable option, after payment db-update where the person who has payed has access to some content of: a- pieces of the producs b- a whole part of the website this in an automatic way, not manually change the user's permission level. Multilangual is a must.... the same product in different available languages [one 'add new', or one edit] and the url should look like something similar to this: www.domain.com/en/products/producttitle www.domain.com/fr/produits/produit and www.domain.com/en/products/brand/producttitle and/or www.domain.com/en/products/brand/category/producttitle I think I have most things covered here... maybe more will come.... At first this would run on a shared hosting [$price ], at least for a year, depending on how successful this would become. Is ProcessWire not too heavy? Any input would be appreciated and I'll carefully read everything to come. Kind regards
×
×
  • Create New...