Jump to content

digitex

Members
  • Posts

    228
  • Joined

  • Last visited

  • Days Won

    1

Everything posted by digitex

  1. God you guys are awesome. Thanks. The generosity of everyone who offers insight and helpful tips on this forum is humbling. You guys make me look good to my clients. They think I know what I'm doing. I have a template news-list that displays the headlines and dates of each article with a link to go to the page (it's the page that shows up when you click the News and events button in the navigation and a template called news-item which is the template every article uses. So Ryan's approach would work perfectly as I can simply exclude every page using the news-item template. Works! Just tried it. On to the next thing.
  2. Thanks Jasper. That's the kind of thing I'd like to do but for some reason I can't make it work. I'm using Ryan's excellent listChildrenTree function: function listChildrenTree($children) { echo "<ul>\n"; foreach($children as $child) { echo "<li><a href='{$child->url}'>{$child->title}</a> "; if($child->numChildren) listChildrenTree($child->children); echo "</li>\n"; } echo "</ul>"; } listChildrenTree($pages->get('/')->children); And when I add in your addition it doesn't do anything. If I keep working with processwire i hope I'll eventually be able to figure this stuff out myself but I'm not there yet.
  3. I have a similar problem in that I have a navigation menu featuring a javascript dropdown. Some of the top level pages in the navigation I want to have their children display in the drop down while some I don't. There's a news and events page for example that if all it's children were displayed in the drop down would make for a loooonng menu. I used Pete's solution by making the pages hidden and including hidden pages in the list on the news and events page BUT... The whole point of a CMS is to allow people who have no real expertise to edit and add new content and to expect them to remember to mark each new page they create as hidden is asking a lot and I anticipate a big mess that I'll have to clean up. A solution would be to have a way to mark a template as hidden so that all pages created using that template will by default be hidden but that's not possible either. Having a checkmark field to determine if a page is to be included in drop down navigation is probably a good solution but also requires the user to remember to mark it. Is there an easier way? Can I add in something to the effect of: if the page is a child of news and events then exclude it? I don't know how you would code that.
  4. Got it. The big problem, it turns out, is in the php tags. You can't use em. This was not in the manual or online help it was in a forum when I did a search for php tags in smarty templates. Instead of <?php ?> you use {php} {/php} Weird. But working. Thanks again Ryan. As always. Hopefully I can make this thing work finally.
  5. No it's correct. I wish it was that simple to fix. Any php in the template causes a fatal error but when I removed all the php code I still got the notices but the page loaded. Smarty is configured to allow i.e. execute php tags in the templates so it should work but it doesn't.
  6. OK. This is a mouthful. I turned on debug and reloaded the page. The volume of notices exceeds the 20000 character limit of the forum so I'll post in 3 sections. There's one fatal error which is probably the important one, at the end.
  7. I'll turn on debug and report back but I can answer your second question right now. Simply including the index.php works if you want to call it that. In other words, the booking system works like it should with no errors.
  8. I was just looking to find out if any conflicts have ever been reported but if details will help: The error is: Unable to complete this request due to an error. Error has been logged. The error log has nothing in it. I expect that's because ProcessWire is not handling the web request but for whatever reason there is no error logged. The only code I've tried is directly from the page http://processwire.com/api/include/ just to see if I could get it to do anything. The smarty-app is Easy Estate Rental.
  9. Hi Ryan et al. I'm still at it trying to work out the problems I detailed in http://processwire.com/talk/index.php/topic,490.0.html Now I have a new one. I am trying to bootstrap pw into a booking system I found that uses the Smarty template system. They're html based templates so I expected they would be able to work with processwire since the smarty class can be configured to execute <?php ?> tags placed in the template files, which I did. I also managed to successfully include the pw index.php but I get an error. The error is a processwire error so I know it's "working" but I don't know if the problem is some conflict with the other app or just the way I'm using the pw API inside the smarty templates. The bootstrap how to ( http://processwire.com/api/include/ ) is a little vague (to me) on the ins and outs of accessing the API, are there any other examples I could look at? Has anyone encountered a conflict when bootstrapping pw into another script?
  10. Wayne declined. He said he might be able to do it if it was based in Wordpress but he didn't know processwire. Oh well. I decided to go the bootstrap way. I found a booking system that uses the Smarty template system. It's very robust, far more so than I need or want but with the templates, which are html files I can include or exclude what I want. Now of course I have a new problem. I think it needs a new thread. Thanks for the help Martin and Ryan.
  11. Thanks Martin. I have been thinking of this problem in terms of integrating it into processwire in order to make use of the current templates I built for displaying search results. In order to do that I think I would need a custom fieldtype to store dates, fees and the booked/not booked toggle. It seems, as you and Ryan have both suggested, I need to think instead of a completely separate system that I can include on the availability page. It would solve the problem of user/owner login and editing but would mean I need to rethink the search unless I can get processwire to handle the search with an independent booking system. I will contact Wayne and reference your name by way of introduction if you don't mind.
  12. I've never before run into a situation in which I couldn't figure out the problem. Without delving into PHP and learning to program I doubt I have the skills to do what I need here even if the deadline wasn't looming. So I feel bad from that point of view. Can't help it. I doubt a little cottage rental website in Ontario Canada is competition to your clients but I respect your ethical integrity in not wishing to violate your commitment to them Ryan. Thanks for your help on this. Anyone else who might be interested, please post or PM me and I'll give you details for you to quote. This is a serious offer and time is becoming more of an issue. Thanks in advance.
  13. I've completely failed. I have to stress I'm not a programmer, just a frontend developer. I can do enough PHP to configure the scripts and apps that others create and have been able to make processwire do some cool things but creating a custom fieldtype to allow property owners to maintain their own availability is way beyond me. I've been looking at different ways to do what I need for a month in between completing other work and I've gotten nowhere. I believe that if I can do a custom fieldtypemulti as Ryan suggests and populate it via a form that owners can access through a login that I'll be most of the way there but I need some kind of help. I don't even know where to begin.
  14. All's well Ryan. I initially followed the upgrade instructions detailed in thread: http://processwire.com/talk/index.php/topic,58.0.html which you've now updated. I got an error so went to this thread: http://processwire.com/talk/index.php/topic,383.0.html since the error I got was identical and that's how I was lead here and where I learned of upgrade.php which is no longer available. Now that you've updated the info on topic,58.0 there should be no further confusion for anyone. Thanks for your diligence.
  15. OK WTH? I have pw 2.0 and it's been suggested I upgrade to 2.1 so I follow the instructions to replace /wire/, index.php and htaccess and now I get a blank screen with an error message. Then I see there's an upgrade.php so I try to download it and I get a 404 error page not found. I've already replaced the files so how do I get things running again? I can't use the new upgrade module because the site is not working now so do I have to return to pw 2.0? Can I do that just by replacing the .htaccess, index and wire directory with the original ones from the zip? ----------------------- edit ----------------------- OK. I replaced the current files and directories with the originals and the site is back up and working. I would suggest that it might not be a bad idea to update all of the forum threads dealing with upgrading with current info. Doing a search on the forum for "upgrade" yields many threads and posts with clearly outdated info. Anyone new to processwire interested in upgrading will definitely be lead down the wrong path unless posts are updated with links to current instructions. I was. I'm now going to go dl and install the upgrade module.
  16. Thanks for the reply Ryan. I am completely out of my comfort zone here. The idea about making the editable content a form is a good one. i will try to get that going. As for the search, I think I understand what you're saying and I will see if I can get my frontal lobes around it. Not sure how to go about building a custom fieldtype but will look where you suggest and see what I can make of it. Thanks again.
  17. Sorry, couldn't come up with a more descriptive subject. I have built most of a site with processwire and I'm thrilled by the power of it but I've encountered two issues that I can't get my head around. The site is a tourist accommodation site in which individual cottage owners list their properties for rent during tourist months. They all rent from Saturday to Saturday through the summer but start and end dates can vary. Each property owner edits and keeps track of availability on their individual sites where an availability table displays the period (e.g. September 17 to September 24) cost, deposit and whether it's booked or not. Problem 1: each member edits their own info and I figure the owner role would be the best way to allow each member to edit only their page but how to set that up? Do I have to create the user account, log in under that name, set up the page for them? I'd like to be able to set a user as owner of a page but that doesn't seem possible. Probem 2: How to set up availability? The booked or not booked is easy, a simple checkbox field would do but how can I set up a fieldset with a date range, cost, deposit cost and checkbox for if it's available and make it searchable? We need site visitors, looking for accommodation to be able to search a particular date range (September 17 to 24) and have all cottages with availability during the time period show up in search results. Of course there's also the fact that some cottage owners have multiple units available for rent. Does any of this make sense and is there a way it can be done in a way that will be somewhat user friendly to property owners that are not computer savvy? Any insight would be very appreciated.
×
×
  • Create New...