Jump to content

Pete

Administrators
  • Posts

    4,035
  • Joined

  • Last visited

  • Days Won

    66

Everything posted by Pete

  1. Okay, just for poops and giggles I decided that since I have two hard drives in my laptop I'd install XAMPP on the other hard drive and test this issue once again. Resizing now works fine Thing is, I could have sworn I tried this already! Oh well, I need to do some testing this evening, but if I track down what the exact cause is I'll let you know - I am wondering if it's because my main hard drive is an SSD and it's trying to write and then overwrite the same file so fast it's failing there. It makes some sense in my head anyway.
  2. And on a similar topic, if you ever do need remote access to client's machines then I can't fault this bit of software for its simplicity: http://www.teamviewer.com/en/index.aspx It passed the "mum test". She installed it fine and I was fixing her PC in no time
  3. Hi folks As I had to reinstall my laptop last month, I was about to install a piece of software that I've used before to batch-resize photos which is useful when creating websites for clients where they're supplying huge photos (anything of a few MB or more is a pain in large quantities as I'm sure you'll agree). Before getting to installing it today though, I thought "there must be a tool that monitors a folder and any images you put in there get resized automatically..." - and guess what, I found one: http://www.dropresize.com/ Now obviously this might be a little over the top for someone who knows their way around a computer fairly well, but I liked the idea of something that sits in your system tray for clients to be able to use when uploading their own photos to a site. If you think about it, once it's set up all the instructions you have to give them are: "copy all your photos to this folder before uploading them to the website". Provided you've got the software set up correctly on their machine, that's all there is to it (and even if you're working with a client remotely, installation instructions wouldn't be too difficult to write!). All they've got to do is remember to run the program when they start Windows, but you could even just add it to their Startup folder. EDIT: Just noticed that once you set some options, they're saved as an XML file so you can even tweak that and supply it to your clients along with the .exe file for hassle-free setup. Neat - two files, no installer and you're done! EDIT2: Ah, nuts. You have to be careful though as it also enlarges images that are smaller than the specified dimensions. So, only useful for photos at the moment (was hoping to use it to convert a site with various image sizes, so will have to be careful or find another script).
  4. Looks good - my only comment would be that the brightness on the fields in contrast to the dark surroundings is a bit too much, but then I'm not sure how easy it would be to change the colour of TinyMCE which I guess is where the main problem would be.
  5. Wow, that is good news - finally IE is catching up with the last few things that were holding it back. It would still be nice though if IE ever displayed exactly the same as all other browsers out of the box. I can rely on all the others to output my designs correctly, but even IE9 has its quirks so hopefully IE10 will be the end of such quirks and IE will no longer be the outcast
  6. Pete

    Hijackers

    Wow - that's a lot of junk accounts. Might be worth coding a simple Q&A challenge question into the registration form if there's an easy way to do that (or a mod for SMF already). I used on on one site and it cut spam registrations down to one or two a week
  7. Probably the easiest way to handle this currently is have a multi-line input field (textarea) and you can already tell the system how to display this in your templates, with a bulleted list already an option (I think). That way they just add one new item per line and the field automatically turns that into a list in your template
  8. Just a quick note that might be of some use to somebody, I'm also looking at a publish_date field for a project for things like news articles and other pages as well as an unpublish_date field (think pages that are very time-sensitive and don't apply after a given date) - just a few other scenarios worth considering there. Are these two things something that might make it into the core further down the line ryan or is this something that would be best suited to a module? I'm only thinking the core as they're fields that appear in quite a lot of other systems, though there's certainly no reason why they couldn't be included in a module instead.
  9. Cheers Ryan Hopefully I'll have something to show you in the coming weeks in terms of the website I'm working on - it's a personal project that's travel/accomodation based. It's not intended to make money to start with, but it will be an excellent showcase piece to show other clients and could make money further down the line. I imagine your Tripsite and villa website work makes it much easier to sell an idea (and this CMS) if you've already got an example or two to hand! There are other projects I've got in mind, but I'd like to get this one done first as for one thing it's something I've been meaning to do for years and, as mentioned, would make a good showcase. I'm all for collaboration - I do love working on larger websites as the additional challenges are usually fun and always give you a good feeling when you overcome them. That said, I don't mind working on smaller sites however they can often be very time-consuming and the time-to-profit ratio can sometimes get you down if you're charging a lump sum rather than an hourly rate. I like to be able to give clients an overall cost before starting work, but sometimes it doesn't work out so well... I'll leave it at that but I'm sure we've all built enough websites for folks to get what I mean I think overall I like working on larger projects because you don't have to chop and change too much - you can work on one project for a good length of time with the same set of people and give it your full attention. At the other end of the scale I worked at a company once in a web team and they were juggling 20 websites at once and working on each one for an hour a day and alternating it throughout the week so they could show the clients a bit of progress each week - I don't agree with that personally - it was chaotic at best. Thanks for the pseudocode - I think it will come in handy on the site I've mentioned here as well as my gaming one with a few modifications
  10. Only problem (well, maybe not only ) is that you're then putting resizing code into the more generic fileupload js, and also when you resize an image this way it seems to be a PNG and so would need processing further on the server to get it into the correct format (thinking the PHP code for that pretty much already exists in PW though if you can force a resize to the same size and just a different file extension). Anyway, not as easy as I first thought
  11. Just a quick one, I was having a read of things you can do with HTML5 and one of them suggests you can resize images before they're uploaded: http://hacks.mozilla.org/2010/02/an-html5-offline-image-editor-and-uploader-application/ Is this really possible? If so, it's awesome and I would like to know if it's possible to include this in your code Antti if an image field has width and/or height dimensions set? One of my biggest gripes is that often you'll hand a website over to the webmaster and they won;t know about resizing images before they're uploaded so, especially as digital cameras are getting better and better, you'll frequently get images of 5mb at something silly like 3000 pixels wide being uploaded If it's possible to do this, it would be amazing. It would also solve my issue with Windows not wanting to play nice and resize images in PW as this would happen before uploading, but that's just a nice side-effect EDIT: Potentially more useful reference for this: http://webreflection.blogspot.com/2010/12/100-client-side-image-resizing.html EDIT2: The possibilities here seem limitless - you can even perform cropping on the client side before uploading, but I'd settle for resizing before upload for now purely because of the speed benefits - especially when uploading multiple images
  12. This is a continuation of something that was being discussed in the second part of ryan's post here: http://processwire.com/talk/index.php/topic,414.msg3192.html#msg3192 The reason I was interested in this is because I've had a scenario in my head for a while. I'm intending to build an accomodation directory website (being intentionally vague here) and there will hopefully be the opportunity to build some individual websites for the individual accomodation (for the sake of argument let's assume hotels, but it's not). The way I therefore see site cloning being useful for that is if the owner is allowed to update content themselves on the directory website and then this information automatically (via cloning, probably not instantly) gets updated on the specific hotel website. So whilst I'm being vague about a website I'm intending to build, this is one scenario that could be a real selling point to customers. I'll also have the luxury of having websites hosted on the same server, at least to start with, so that would probably make things even easier. I think I'd definitely look into the web service approach as well though as that would make it easier if it took off. Something unrelated that's been bugging me for a while Ryan - on the villa website you've created, how did you determine which photos would go across the top and which ones down the side? Also some are square in two columns and others are wider covering both columns - surely that's all automatic but I can't get my head around how it's been done. No worries if it's a trade secret
  13. I was wondering about this too, but on the odd occasion I've thought about it I just created another field to be honest. I wouldn't mind an "override label/description" on a per-template basis for fields though as you've got it on your list already
  14. @ryan - slightly off-topic here, but can you roughly describe the scenario where you need to sync pages across multiple sites? I'm also intrigued as to how that would be acccomplished.
  15. Cheers for that ryan - I totally agree with all of that Whenever I build a site for a client, aside from telling them what platform it's on (and leaving copyright notices in-tact) I actually put the cost of the CMS down on the invoice as FREE and more recently the name of the CMS as well. Sometimes it's a good selling point too - "if I had to build this system from scratch the website would be £xxxx more costly" Either way, they've got the name of the CMS on a piece of paper they're not going to throw away. That selling point doesn't work when the client things your "cheap" quote is still to expensive of course, but you can't win every time! I personally think it's important in relation to how open source software is usually licensed to show the client that the software is totally free and it's actually the setting up, development and templating that is being charged for. It's still all skilled work that you're charging for at the end of the day, but the CMS is giving you a massive help in developing the site quicker, causing developers and users less headaches and keeping costs down.
  16. Hehe, well I figured it was safe to do so as he's also installed your theme to have a look at and put a link up on the site
  17. Aha, well in this case you'd just copy the templates-admin folder into your /site directory and upgrades are fine - if PW finds a templates-admin folder in the /site directory, it doesn't use the one in the /wire directory, so you can upgrade without breaking your templates. You would still have to check that an update doesn't introduce new features though I'll admit, but the theoretical scenario in question would probably only involve changing CSS, a few images and the footer so I imagine for the most part upgrading would be as simple as it is with a default installation. Remember, I'm not actually considering the second option myself - just asking the question about white-labelling in case it comes up in the future. The first option, removing the PW logo from the top, is something I'm interested in doing though. EDIT: In fact, Apeisa has already done what I'm asking with regards to removing the logo from the top in his admin theme, so I guess that's okay: http://processwire.com/talk/index.php/topic,252.0.html
  18. If you're syncing a page so that one you've created in one language is then copied to another I would say that it's status should be unpublished by default - I'd personally want to finish translating a page in that case before I publish it. Something that could be useful even in a version 1 would be the option to exclude copying pages with a certain template. One site I'm working on will have everything translated to different languages as the company does work in a few different places in Europe, but the news won't be relevant in different areas so I wouldn't want to sync news articles in that case. I imagine, though I obviously can't think of every scenario, that this would be a very useful feature. The only problem I can see is if you accidentally exclude a template for a page with children using a different template - what happens then? Does it just not copy the children or could it run the risk of not working at all and throwing an error? So... maybe this idea is not as simple as it first sounded
  19. I thought I'd ask a question about copyright, and whilst I'm at it thought I might as well ask a less popular question about whitelabelling software Am I right in assuming that when altering the admin templates, we can do pretty much anything we like aside from removing the copyright in the footer? So I can take off the Processwire logo at the top and put in the logo for the company whose website it runs if requested to do so by a client? And now on to the less popular question - is a white label version allowed? As in, without the copyright in the footer, but obviously leaving all copyright in the files themselves? I've personally not had this request crop up yet, but I have heard of companies wanting to take any branding off CMS admin templates before and stick their own logo at the top - purely to use it on their own site from what I gather and not to redistribute as "their own" work. What's your stance on this ryan? Most folks don't allow this but I thought it was worth asking whilst I was asking about the templates. Another CMS I've worked with actually made money working with honest*1 companies this way by selling a license to allow removal from the admin templates. Again, we're talking the templates and not touching the copyright in the code itself. *1By "honest", I think that what they were doing was removing branding and replacing it with links to their internal support department's contact pages in some cases, though I have no doubt that a useful side-effect of this for them is that people would then assume that they've built the software in-house. You'd have to hope they were being honest with their users and management as well and giving credit to the actual authors when asked who built the software.
  20. I use IPB purely because I've used it since version 1, back when it was a bit simpler (and free). It's probably a bit overkill for a lot of sites, but they've been trying to streamline it a bit in 3.2 and you can turn a lot of extra stuff off. it's a very solid product anyway and I like the new, more streamlined default skin as well as built in anti-spam in the new version (they have a central server a bit like the StopForumSpam website). I guess I've just used it so much that setting it up, configuring it and maintaining it doesn't bother me, but to a newcomer it's so big in the admin area I imagine it can be a bit daunting. In terms of free forum software, I've used MYBB - very good product and feature set, and the code was easy enough to manipulate on one site I used to have so that I could do integration like I'm doing here without the need for a third-party set of classes (pretty sure I was able to initialise an instance of MYBB inside my custom CMS at the time so could probably do it again with ProcessWire if the need ever arises again. No worries on the skin issue Ryan - that's just me fiddling with the stylesheet
  21. This is just something I'm doing for one of my sites that's possibly too complicated to release as a module as it requires a third-party module that I've had to squash bugs in myself (), but it is a bit nifty even if I do say so myself. Basically what I've done (or rather re-done as I lost the original code when my hard drive died) is written a module to use my forums as comments for news articles that are written in PW. I'll give you the link first and explain it all later: http://screencast.com/t/TvCg6lHUZ1L So, I created a new page in ProcessWire using the News template. My module knows that anything using the News template that's under the News page will create a topic in a specific forum. Upon first save it creates the topic and puts in some text that links to the news article page on the PW site (when I get the right link... seem to have linked the forum topic to itself there in the vid ). At first, the forum post is "Queued" - as in hidden from non-forum-staff - as the page is not yet published. I debated whether to copy the article content into the topic, but the point of the exercise on my site at least is that this News Desk forum is hidden away from all but site staff (it's just a container for news comment topics) - it could easily contain something more interesting like an intro with a link to the full article so people browsing your news forum click through to your news section if they see something interesting. You'll see as the page is published, the topic is made live (Queued status removed) so all can see it (but in this test case it's still just in a staff-only forum ). Moving the news page to the trash causes the forum topic to be Queued again to the public can't see it - very important I thought! Restoring the page, or in fact moving it anywhere after it's been out of the trash makes the topic visible again. Deleting the page deletes the forum topic as well. That's it so far and it suits my immediate needs Something that's important to note is that as I'd previously logged in to the forum software it knew to create the news post as me - I'll tie in PW and forum logins at a later date, or at the very least throw up a warning if you try and create a news page but PW detects you're not logged into the forum software - since it's only a handful of admins who will use this I'd like to do the former as I can just tell them to use the same username and password for both and create a login form that logs them in to both systems. Also, the forum software I use is IPB - www.invisionpower.com if anyone is interested, and the class that I used to talk to it is www.ipbwi.com , but as I say I had to fix a few bugs in IPBWI as IPB did a major release not so long ago that means IPBWI isn't too happy with it at present.
  22. I know what you mean - to be honest without a proper Windows server (IIS with PHP and mySQL) to test this on it could still just be an issue on my XAMPP installation/some weird permissions issue/only an issue on my machine It's only a development platform after all and not designed as a proper server platform, so yeah, not a good idea to start radically re-thinking how files are handled, especially as the way they're handled presently is perfectly good OOPHP with one class for uploads and another one for image transformations. I tested that bit of code and it didn't work unfortunately, but to be honest it's really not a big deal for me and I've wasted enough time trying to solve it now I reckon I think the solution for me is to just set the galleries up, finish the rest of the site off, upload it to the live server in a /dev folder or something and upload the gallery images then when it's on a real server. It's certainly not worth more hours of head-scratching that I could have spent on porting the rest of the site across to PW. Thanks for the assistance though ryan - much appreciated and at the very least I've learned another bit of code which I can use to track bugs in PW, not to mention I know some classes a lot better now!
  23. Cheers ryan, I'll check that out
  24. Ah, now that 4th option sounds interesting. You could have options on a page to clear a list of other pages then as you say, but another approach is from the template side of things where for each template you could say something like ANY page using this template clears all other pages using this template when saved. I guess I've got a few scenarios in my head, but we'd need to jot down all possible scenarios to get this right. Problem is when you start clearing the cache on entire sections of the site then like you say, you may as well clear the whole thing! Maybe a better way would be to have a per page or per template option to stop a page and it's children, or evey page using a template from being cleared from the cache and approach it from that angle? Clear the cache for everything but the pages/templates you specify when a page is saved? Might be less hassle, I don't know - might also be less intuitive but I was thinking that you probably know of sections/pages that, once they're up on the site, will rarely/never change or certainly that they shouldn't have an impact elsewhere.
  25. Are you then going to run into issues elsewhere though as other pages could also potentially be using data from that page? I guess if you put a note next to that option explaining any potential issues then that would work. What would be great in theory is if there was some way to track wherever a $pages->find call (or other such bits of code) is made in a template file that returns in it's results the page you're saving, as well as any pages that use InputPageSelect (and other such field types) and clear the cache for those pages as well - so basically any page that makes use of the data in the page you're saving should have it's cache cleared. Unfortunately that's impossible in practice for the template file side of things (should be do-able for fields) unless you to a preg_match call on every template... ...maybe that wouldn't be so hard to do actually...? It would require looking for any code inside PHP tags that's selecting pages to list and working out which ones relate to the current page you're saving. Actually no, I think that would get quite messy and depending on the number of templates could take a bit of time. It also wouldn't be fool-proof - the minute you start putting common template bits into other files that you might include that PW doesn't know about (think header.inc, but yourname.inc <- PW wouldn't know that even existed). So yeah, ignore my train of thought
×
×
  • Create New...