Jump to content

falkencreative

Advanced Member
  • Posts

    4,419
  • Joined

  • Last visited

  • Days Won

    27

Everything posted by falkencreative

  1. Some yes, but mostly no. Yes: A class itself is not an object. It's the structure for an object. For it to become an object, it needs to be instantiated with the "new" function: $stefan = new person(); No: Basically everything else. Whether you are accessing an object's properties directly (example: "$stefan->name;"), or using a getter method (example: "$stefan->get_name()"), either way, you are accessing an object that has been created. It is technically possible to access properties/methods without instantiating them in an object using the "static" keyword (http://php.net/manual/en/language.oop5.static.php), but that isn't really within the scope of your comment above. --- Basically, the point is this. Say you create an object, and it has a property that holds a value. The object itself should be in control of the value of all of its properties, and it should have the option of rejecting outside changes if necessary. You shouldn't make it possible for outside code to change the value of a property without the object knowing about it. This is especially important if the object is expecting a property to hold a specific value -- if an outside source changes it, it may lead to bugs in your code due to incorrect expectations on the value of the property. By using setters/getters, you are keeping the control within the object itself. For example, say in a setter method, you could set up restrictions so that certain values could not be passed in. For example, take the Person class that was created in the example on killerphp.com. I think we can safely assume that if someone is a person, they have a name. So, in the setter method for the object, you could include code that would reject any attempt to clear the person's name: function set_name($new_name) { if ($new_name != '') { $this->name = $new_name; } } This way, the object itself has control over its properties, and it's properties can't be unexpectedly changed, or changed in a way that wouldn't make sense. Hopefully that makes sense?
  2. See step 12. Talking about accessing properties directly: "Though doable, it is considered bad practice to do it because it can lead to trouble down the road. You should use getter methods instead - more on that later." Using setter/getter methods is considered better practice than accessing properties directly, since you want to ensure that any changes/access to those properties are handled within the object itself, not through an outside source.
  3. Realistically, I don't think it fits a need for most people. When I want to search, I'm looking for something that's quick, easy to use, and gets me the content I want to see -- the results. Searching three search engines at once seems a bit unnecessary to me, and it isn't something I'd personally ever see myself using. When using the site, I feel a bit overloaded by the search results (not your fault, but three different search engine's results seems like too many choices.) I don't know if all of your users would be like me, but I can't see it as a site that anyone would use regularly, unless they specifically needed to do that.
  4. It really depends on the client. I think the larger the client, the more likely they will want (and be willing to pay for) a copywriter. I have had at least one project where the client just couldn't come up with the content, and where (though we ended on good terms) the project didn't complete because of that. For the most part, at least with the clients I work with, it's usually clear that the client has more experience in their particular industry than I do, and thus they are more suited to writing most of the content.
  5. I haven't personally worked with oDesk, but as a full time freelance designer/developer... I think you'd approach this the same way you'd approach any other potential project. -- You'd send a response outlining your experience, providing sample projects you've worked on in the past, and explaining how your skills fit with the goals the client is trying to accomplish. What websites have you done or experiences do you have that would allow the client to feel comfortable working with you? -- You present yourself as a professional in any client communication. That means being polite, friendly, and showing you will provide good customer service to the best of your ability. I think this also extends to your portfolio website, your official proposal -- anything physical or digital you send the client. They should all be well designed, consistent, and look like you know what you are doing. -- If you don't have a portfolio website you can link to, I wouldn't apply on oDesk until you do. With clients you work with face to face, it's possible they can overlook a lack of previous work if they are impressed with how you present yourself. But if you are working with clients only online, having a professional looking portfolio site that presents work you've done in the past and information about you helps potential clients be comfortable trusting you. -- I wouldn't apply to any jobs that are outside your experience range, where you have no idea how you will accomplish something. It's OK to push your knowledge a little... for example, say a project requires Wordpress knowledge, which you have, but requires you to perform something Wordpress related that you've never done, that may be fine for you to apply for. But don't take on projects where you aren't confident that you will be able to complete what the client is asking for. That's just asking for unhappy clients and long term issues. -- If you don't have any/very little professional experience, I really wouldn't start with oDesk. I'd start by finding people you can work with locally, connections you make in your everyday life, through friends or family members. Build up some experience and professional knowledge before you start applying to places online.
  6. This really depends on the client and what they are expecting, and partially on your usual web design process. My process usually follows something like this: -- Discussions with the client on the scope of the work, provide them with a proposal, then eventually a signed contract -- Discussions with the client on the content that will be included in the site, followed by the design phase, where I present them with design samples and we work together until they are satisfied -- After the design phase, I usually move into HTML/CSS/Javascript production of the mockups -- In most cases, I take those coded mockups and integrate them into a CMS (usually Wordpress) -- Once the main development is complete, I'll receive the content from the client, edit and format as necessary, then enter it into the site -- Once the site is ready to go, I'll work with the client to perform any edits and get their final approval, then launch the site At least in my process, the client usually provides the final content about midway through the project, once the design/development phases are basically complete, and I handle everything else.
  7. I think you might be confused about that. Can you point to the spot in the article where it says it has been depreciated?
  8. You're getting errors because that's not the right form. A valid break tag looks like this: <br> <br /> As far as I can tell, when using HTML5, "<br>" is the right way to do it.
  9. I'm assuming it's "great code" in the sense that he's thanking me for the code that I provided in my tutorial, which this is based on.
  10. What does this code do currently? What do you want it to do? How is it not working?
  11. Searching for "sort array of arrays php" may help. Here are a couple results: http://php.net/manual/en/array.sorting.php http://php.net/manual/en/function.array-multisort.php http://www.the-art-of-web.com/php/sortarray/#.Ufbx3WRgarg
  12. @JeffH13 - Basically, you'd need to add two radio buttons or a select element at the end of the form, giving you the option of either choice. Then, in your PHP code, when the form submits and get processed, you'd check the value of the option and perform the correct action based on the value. Should be relatively straight-forward.
  13. If you want to use auto_increment, you need to change to an int based ID. There's no way around that.
  14. If you are going to use the auto_increment feature, you need to use an INT. It can't be a VARCHAR. I don't know how you've built your application, but if you want to use auto_increment, you'll have to change the database, and potentially how your application works.
  15. That's a slideshow, and it looks like that functionality is built into SmugMug already. http://help.smugmug.com/customer/portal/articles/93315
  16. I think you're looking for the MySQL "like" command, which you can learn about here: http://www.tutorialspoint.com/mysql/mysql-like-clause.htm (or similar - do a Google search). It will allow you to run searches are partial strings rather than searching for an exact match.
  17. A jquery file is just a Javascript file. It will open in any standard text editor, like any other web file (HTML, CSS, JS, etc.). But jQuery adds interactivity and Javascript functionality -- jquery shouldn't control the layout.
  18. Killersites does offer an interactive learning experience as well: http://killersitesuniversity.com/ Also, my impression is that Treehouse is aimed more at beginners (http://teamtreehouse.com/) though it costs more per month.
  19. I like how they repeatedly mention the high price... yet the new machine actually hasn't been officially released yet or been given a price.
  20. Personally, I would approach this from a different angle. Rather than storing the image directly in the database, which is going to significantly increase your database size over time, I would suggest simply storing the image in a specific location (say, and "uploads" folder) and simply saving the path to the image in the database. I personally haven't ever used blobs for image storing -- this is the way I usually approach it. That said, you might look here for help with the blob issue: http://www.phpro.org/tutorials/Storing-Images-in-MySQL-with-PHP.html. I believe you can ignore the PDO portions -- as long as you can access the database and retrieve the data, exactly how you do that (MySQL, MySQLi, PDO, etc.) doesn't specifically matter.
  21. By mobile design do you mean responsive web design? Building websites that adapt to the device? Or mobile design as in design for iOS or Android? Pretty much all of the same tools apply -- Adobe Photoshop and Illustrator. For interface design, you're going to need a pixel-based tool (Photoshop, the GIMP, etc.). For icon design, you'd likely want a vector tool (Illustrator, etc.), to create icons that scale to different sizes easily, then do a touchup once they are at their final size in Photoshop or similar.
  22. Sounds like those should all be things you can do either via the Joomla admin interface, or potentially via FTP (if the date is hard coded into the template files, for example).
  23. Not off the top of my head unfortunately. I'm sure you can find some by doing a web search or two.
  24. Correct. You'd need to reset it back to one after it hits three and you add the closing </tr>.
×
×
  • Create New...