-
Posts
2,776 -
Joined
-
Last visited
-
Days Won
40
Everything posted by Macrura
-
i need the actual HTML output, not the visible output (you can copy from the source code view)
-
this thread was helpful in setting up the ical and google calendar feeds. i changed the module a bit to get it to support the time start and end of events, otherwise your events will always appear to be all day, if you use this module. It's a bit hackish, in that it determines whether to use the all-day style, or the actual time style by checking if the time is set to midnight, which it would be if you were not specifying a time; though this could be a problem if you had an event that started at midnight. it might work to have a separate checkbox to indicate "all day" and then use that to conditionally output the date with or without time, if you wanted it more foolproof; here are the relevant changes: $start = $event->getUnformatted($this->itemStartDateField); if( date('His', $start) == "000000" ) { $vevent->setProperty('dtstart', $this->ical_date($event->getUnformatted($this->itemStartDateField)),array("VALUE" => "DATE")); } else { $vevent->setProperty('dtstart', $this->ical_date($event->getUnformatted($this->itemStartDateField))); } if($event->get($this->itemEndDateField)) { $end = $event->getUnformatted($this->itemEndDateField); if( date('His', $end) == "000000" ) { $vevent->setProperty('dtend', $this->ical_date($event->getUnformatted($this->itemEndDateField)),array("VALUE" => "DATE")); } else { $vevent->setProperty('dtend', $this->ical_date($event->getUnformatted($this->itemEndDateField))); } } since this module also includes the full iCalcreator library, it could be extended to support repeating events and other cool things.. might experiment with it this summer; They mention processwire, this module, also, on the main page http://kigkonsult.se/iCalcreator/index.php Another thing that came up was the existence of special characters in the titles of the events. The title field needed to be decoded or you end up with &\; in your feed: $summary = html_entity_decode($event->get($this->itemSummaryField), ENT_QUOTES); $vevent->setProperty('summary',$summary); //$vevent->setProperty('summary',$event->get($this->itemSummaryField));
-
@TDG welcome to the PW forum! can you post your generating and output code? (and for reference here is the tutorial page you are referring to).
-
Hi- this is a very basic version, i can provide more details later, but in short you first define today as a timestamp and then add your selector. $today = date(); $events = wire('pages')->get("/events/")->children("event_start_date > $today, sort=event_start_date");
-
Module FrontendUser: login, logout and register users / members
Macrura replied to pwFoo's topic in Modules/Plugins
@pwFoo - thanks for the reply & info. i'll see if i can make it work, and carry on testing the various features. in terms of sanitizing/processing additional custom fields on a registration form, any tips on how and where in the process to do that? thanks again -
why can't you use your own markup?
-
Module FrontendUser: login, logout and register users / members
Macrura replied to pwFoo's topic in Modules/Plugins
I'm getting this error when trying to use the register form Error: Exception: Method FrontendUser::attr does not exist or is not callable in this context (in /Volumes/Docs/MAMP/htdocs/processwire_xys/wire/core/Wire.php line 350) not sure what the issue could be; tried various things - has anyone got a registration form working with FU yet, and if so could you post steps? TIA .. also - i noticed you are maybe using using $sanitizer->username() but it seems to be deprecated in favor of pageName (?) http://cheatsheet.processwire.com/sanitizer/properties-and-methods/sanitizer-username-value/ -
maybe something like this? if($page->city) { $setCity = $page->city; $cityURL = $sanitizer->pageName($page->city); echo " <span class='topNav'> <a class='' href='/gyms' title='Gyms'> <i class='fa fa-chevron-left'></i></span> All Gyms</a> <span class='topNav'> <a class='' href='/gyms/{$cityURL}-gyms/' title='{$setCity} Gyms'> <i class='fa fa-chevron-left'></i></span> $setCity Gyms</a> <span class='topNav'> <strong> <i class='fa fa-chevron-right'></i></span> {$page->title} </strong> "; $randomGym = $pages->find("template=listing-gym, city=$setCity")->getRandom(); if($randomGym->id) echo " <a title='{$randomGym->title}' href='{$randomGym->url}'><i class='fa fa-random'></i> Random Gym</a>\n"; }
-
@mattcohen - there probably is, but i think more info is needed, such as what the relation is between the $page->city property and the resultant breadcrumb.
-
wow just in time
-
Possible to register and login simultaneously
Macrura replied to onjegolders's topic in General Support
@Can, have you considered trying this module: https://processwire.com/talk/topic/9811-frontenduser-login-logout-and-register-users-members/?p=95245 it has some interesting features; not sure about auto login feature as is discussed here though. -
Module FrontendUser: login, logout and register users / members
Macrura replied to pwFoo's topic in Modules/Plugins
this seems to be working for me: // Create form field $last_name = $modules->get('InputfieldText'); $last_name->label = 'Last Name'; $last_name->attr('id+name', 'last_name'); $last_name->required = 1; -
Module FrontendUser: login, logout and register users / members
Macrura replied to pwFoo's topic in Modules/Plugins
yep, tried changing everything, isset and nothing works.. WSOD all the way. Maybe you can setup a temp account on lightning.pw so that your module can be tested with some more widely used version of php? -
Module FrontendUser: login, logout and register users / members
Macrura replied to pwFoo's topic in Modules/Plugins
I'm not running 5.3 on any of my new/development sites, its all 5.4; we just released a module (AceExtended) that is for 5.4+; i think it's fine, just put that in the requirements and don't use any> 5.4 features? -
Module FrontendUser: login, logout and register users / members
Macrura replied to pwFoo's topic in Modules/Plugins
it was actually the same line; i can check more, but all i did was replace that line and then got the same exact error on the same line, but line 65, because of the added 2 lines -
Module FrontendUser: login, logout and register users / members
Macrura replied to pwFoo's topic in Modules/Plugins
that didn't solve it... Compile Error: Can't use method return value in write context -
Module FrontendUser: login, logout and register users / members
Macrura replied to pwFoo's topic in Modules/Plugins
I'm testing the latest version, but: Apache/2.2.23 (Unix) mod_ssl/2.2.23 OpenSSL/0.9.8r DAV/2 PHP/5.4.10 Compile Error: Can't use method return value in write context (line 63 of /Volumes/Docs/MAMP/htdocs/pwire_test05/site/modules/FrontendUser/FrontendUser/FrontendUserRegisterEmailValidation.module) -
got it now- that is super cool and useful!!
-
pretty interesting - what would be a good use case for this method, as opposed to making the field itself an AceExtended field? I might be being thick, but am not getting that...
-
Which fieldtype should i use for Bootstrap Lists?
Macrura replied to GeraldSchmidt's topic in Getting Started
In terms of how to output a list, this mostly depends on what the list items are; And since you will seem to need optional links with data attributes, PageTable is probably the the best way.. other options might include: Profields Table Repeater and if they are items that you want to reuse across different pages, then regular page field with the module that adrian posted would be best. -
Ok thanks - in order to see the summary, you'll need to view source, or use the chrome dev tools and inspect element, then navigate to the head, to see your summary meta tag. Meta tags are not visible when viewing web pages.
-
when you say viewing, what do you mean?
-
want to say many thanks to @thetuningspoon for putting this together, and doing all the work of submitting to the directory. It's surely a useful module (use it almost every site), and we hope that all y'all will like it..