I've been learning Degrafa recently, and I have noticed that there is not much consistency amongst examples posted on the web. Is there a place where I can find degrafa best practices (esp. for skinning)? or can anyone suggest examples that use best practices?
This is not really an answer, just a comment, I'm afraid :)
I think one of the challenges is that we (the Degrafa team) continue to develop Degrafa and therefore continue to introduce new (and easier) ways to do things - so some of the older samples are out of date and need to be refreshed. We will be refreshing a number of the older samples on the Degrafa site soon.
We'd love it if the user community starting making more examples as well - I know some people have and that there are a number of discrete examples and tutorials around but it takes a bit of googlehunting to find them and there is not a definitive guide somewhere. I can let you know that at least a couple of people (Jason Hawryluk and Josh McDonald) are working on full theme style skinning examples that will be able to be used as skinning templates to guide people for their own skinning, so this type of thing will be available in time - but I can't say when.
I realise that's not particularly helpful, but if you have specific questions about particular approaches to doing something then please consider posting the questions on the degrafa google group (in addition to posting here as well if you want) as it may get more visibility from current degrafa users, and it will be easier for us to incorporate the solution into a future sample/tutorial, or a collection of best practices.
-Degrafa
Related
i am a hobby programmer with very little experience in web programming, i devote an average f 20-30 hours a week, but with summers coming i have some free time to experiment and learn. could anyone please tell me, whether a framework like (Kohana/cakePHP/CI) should be used or directly a CMS tool like drupal/joomla should be used to make a website something like stackoverflow, on a smaller scale though.
Thanks for your help.
It depends on what you want to learn. Depends on your goal.
Is it webdevelopment you wish to learn? CSS? Webdesign? Programming? Building sites?
If your goal is the site itself, I would suggest to start high up in the stack: use a ready-to-go CMS, such as Drupal, that gets you going fast. And that offers a (production ready) result in a few hours. Your downside will be freedom: sure Drupal can do a lot, so can Wordpress. But unless you move down in the stack (develop addons and such) you will have to do with what you are offered: ready made components that work according to the authors wish. Possibly not your wish.
If your goal is to learn webdevelopment in a more general way, you should start lower down in the stack. Ruby on Rails or Django are probably the best options. Simply because of their vast resource on newbie documentation. You will learn programming along the way there too. Within a few days you will have built a site according to your exact wishes (obviously, your milage may vary, depending on the wishes:)).
If your goal is development of software, Python and Ruby are most probably a good start too: both are cross-platform, have good newbie resources and offer great documentation. Both are really well (opinions may differ on this) abstraction and object orientation. They will form you into a good programmer, simply by their nature.
There's a Stackoverflow clone called Qwench that is free.
(search stackoverflow for open source stackoverflow clones)
and one built on drupal http://drupal.org/project/arrayshift
Wordpress can act very much like Stackoverflow with a proper template. See here: http://p2theme.com/ (demo here: http://p2demo.wordpress.com/). Actually you can than start editing the theme (.php files) and make it behave more and more like Stackoverflow (with reputation system etc. which should be easy to implement). This way you won't be reinventing the wheel and have a good headstart.
I personally use CodeIgniter and love it. I would recommend it to any novice looking to further their knowledge of object oriented programming, and any veterans looking to get their projects off the ground quicker. I am not going to go into great detail here, because I know Kohana and CakePHP are similar, and its mostly opinion. CI does have great documentation though.
I think learning the most common CMS is going to be hugely beneficial to you, tons of sites and companies use WP/Drupal/Joomla/Etc and it really can't hurt to understand them. These projects are very large, so you don't necessarily need to know their internal operations 100%, but you should know enough to be able to install, customize and get a site up and running fairly quickly.
Everyone has their favorites, but I invite you to try them all and see what moves you. It will NEVER hurt to learn something and not use it, especially with some extra time.
There are times to use a packaged CMS and hopefully be able to theme/customize it to what you need quickly...then there are times you will want to code a special case by hand using a framework.
Just understand the depth of the project you want to undertake, because starting from scratch is fun and rewarding, but once you get neck deep in code and get stuck its easy to lose motivation all together.
I would suggest learning the basics of HTML before diving in to using a content management system. The importance of understanding the basic building blocks of websites can't be overstated.
There are loads of resources online to learning about HTML - once you've got some experience with that, you can look at CSS, Javascript, and server-side scripting languages. Knowing the basics will help with using any content management system.
Joomla / Drupal are a good place to start with content management systems, as is Wordpress, but you'd be much better off learning how it works underneath (at least to the most basic extent) before diving in to anything else.
If you're already a programmer you won't find it too hard, but it's definitely worth doing.
I've got what i think it a useful idea for CSS development but I'm unsure where to make my suggestion or to whom it should be directed.
Is there a universal inbox for CSS improvement suggestions at the W3C? I know it will take forever to get suggestions drafted, tested and put into the CSS specs but there is no time like the present...
The W3C has a Participation FAQ that you might be interested in, but if your idea is development-related, does it really need to be a part of the specification? Or is it the sort of thing that developers of popular (CSS-related, web development) tools could simply add support for?
Rather than going directly to the W3C, I'd suggest first trying to get some more exposure for your idea. Write up a blog post describing it, submit it to some popular sites like A List Apart, Hacker News, or Reddit -- basically, get as many eyes on your idea as you can.
If your suggestion really is a good one, it'll help to gain momentum by getting a lot of attention. Or, if it's a bad idea, you'll quickly find out by having people "review" it. You'll likely get some good suggestions to improve the idea, and you'll definitely spend your time better getting peer feedback than somehow trying to singlehandedly champion it to the W3C.
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 9 years ago.
I'm just starting to learn Drupal, and I am really liking it.
What are the most common pitfalls for a beginner? How can they be avoided?
First of all you should be clear with yourself on what you are trying to learn:
Theming?
Site building?
Developing new modules/functionality?
Of course the boundaries of each of those areas are not sharp, but the patterns that you will follow to learn about drupal will be quite different. Here's my opinion:
General pitfall (applies to all areas)
The single most recurrent mistake beginners do is to be in a hurry. In a world of books with titles like "learn to master C++ in 24 hours or less" people approaches drupal believing that they can get away with a couple of days of playing around with somebody's else code. If they do not understand at first sight how things work in Drupal they switch to rant mode and begin to post on blogs and forums on how much drupal is stupidly complicated.
So: be prepared to invest time and energy to embrace the high level of complexity (which is something different than complication) of Drupal. Be prepared to actually study how things work rather than skim over help requests on forums and mailing lists. If you are still not convinced. Here it comes some good reading.
If you are learning about theming
Pitfall: learning by trying to hack a previously existing theme.
A better way: first off, give at least a good in-depth look at the Drupal theming guide. It's dry and it's boring but it gives you a good overview of the flow of the theming engine. Then download and install the zen theme and start you theme by using the starter kit that is included. I recommend - if you use Drupal 6 - to use the version 2 of the theme, although in beta, as it has a much more logical organisation of its internal files, at least IMO.
If you are learning about building sites
Pitfall: getting overwhelmed by the amount of available modules and missing out on the big ones.
A better way: read some of the case studies that have been presented over the years on drupal.org. You will get a pretty nice idea of what are common patterns in implementing functionality by means of contributed modules. Explore and understand the core components of drupal well. They are the basis for everything else, so you will definitively need to know how the mechanism of nodes and revision works, what is the functioning of the taxonomy, how the permission/roles system work, what are the differences between nodes and blocks etc... Do not miss out on CCK and Views, which - although they are (until now) contributed modules, are a component of 99% of the drupal sites "out there".
If you are learning about writing your own modules
Pitfall: trying to put together a functionality by mean of assembling PHP and jQuery snippets of code retrieved here and there on the web.
A better way of doing: if you want to be good at drupal you can't afford to go by the just in time learning paradigma, you have to go for the old-school just in case one. You really need to have a general overall understanding of all the components of the system (amongst others: form API, menu system, hook logic, js in Drupal, node processing, theming engine, localisation, caching...). Drupal is somehow a framework, and if you do not know well the ecosystem in which you are planting your code, chances are you will spent lot of time in producing an horrible code that will soon or later fail in doing what it is supposed to. Above all you will take a lot of time to code something that possibly would have taken a fraction of the time to be realised "the drupal way".
My opinion about possible tools for learning to code well in drupal
http://drupal.org - Is packed with useful information, but it is so messy and the ratio signal/noise is so low that I would discourage to use the site as your main source of information.
Books - IMO if you are new to Drupal it might be worth to invest on a couple of books. Books provide that logical structure and learning sequence that you can't have by jumping from one site to the other, following a screencast here and a how-to there. My top three: Module development is a book very well written, with a smart progression of topics, it actually guides you to writing a few modules with increasing complexity. It is a good reading to quickly get an idea of how drupal works. Pro Drupal Develpment is the book for Drupal. It is quite dry and - although it has examples of code all along - I like it more as a study-book / reference text. Be sure to get the second edition as the first one deals with Drupal 5, which is going to be obsolete soon. The only noticeable shortcoming of Pro Drupal Development is javascript (introduced in a very hasty way). JS and Drupal is a wide topic, and for that purpose I like Drupal 6 Javascript and jQuery better as the first book I mentioned, this book is also project-based (i.e. You learn things in relation to the needs to implement a project).
Other websites - They are an invaluable source of information and examples. It is the perfect place to search when you have a general understanding on how to realise things, but too little experience in a specific domain to be autonomous (and everybody, no matter how experienced, have some domains in which they are not "pro"). Some good websites have been already mentioned by others. My all-time favourite is lullabot but drupal dojo and learn by the drop are also very good.
Community - This is a huge asset of drupal. The community is very big and very helpful and you are likely to all the time find somebody wishing to help. The IRC channel is a good place to start.
Meetings - Every 6 months the Drupal community meets for a few days (once in North America and once in Europe) to exchange expertise and information. Although travelling to DrupalCon can be (too) expensive for doing it, since a couple of meetings the community got organised to post all the videos of all the sessions held. They are an excellent resource too.
Hope this helps to get you going, and best luck with your learning! :)
For Drupal beginners, and "especially" if, like me, one has a firm grasp of MVC or MVP concepts, I would recommend buying or borrowing "Pro Drupal 7 Development", Third Edition.
As for pitfalls:
Learn the menu (routing) system
Embrace the Form API
While some have embraced Zen, I have personally embraced Omega
As one stated earlier, Views are your friend. Model and create as many "Content Types" as needed, then use Views to display them.
CTools is great, Views is the best sauce on planet Drupal, but tread lightly around the Panels and Page Manager interface. :)
I hope that helps.
Learn to theme using the Zen theme or something like it as a base
Theme fields, not pages
Views are your friend
ImageCache rocks
You could - a lot of people started with the Garland theme that comes with Drupal and got stuck because it has logic in the middle (big no-no in a theme) and renamed its parts confusingly. Zen is documented.
Here's a podcast at Lullabot about it:
http://www.lullabot.com/audiocast/podcast-74-drupal-design-round-table
One common pitfall is not to do enough research on the different modules available for each task or function that you are trying to accomplish. It is very easy to install a module in Drupal and start working with it without fully understanding the nuances of that module. It might seem as though the module is working as expected. However, halfway though your project you might find that that a particular module has a limitation or issue that cannot be overcome without major custom code. Another module might have been just as appropriate for the project but also met your additional requirement. A good example of this is deciding how to setup your user permissions. There are many modules that help enhance Drupal's out of the box permissions system but each one works differently and has a specific feature set. Do you need special login screens for different users, workflow requirements, etc? Also included in this is a proper evaluation of whether you should use a module that does not quite meet your needs or write your own instead. Without fully understanding the limitations of the module as related to your specific requirements you could go down a path where you would spend a lot of time trying to fit the module into your needs instead of just quickly building one from scratch that exactly matches your requirements.
I have been seeing some Flex Frameworks, but would like to ask to the programmers and Architects down here on which has suited best in your application.
Cairngorm
Pure MVC
Mate Framework
Custom One.
After using, in turn, all three of frameworks you listed, I can easily conclude that Mate is by far the superior framework. Of course, that's only my opinion and determining what makes a framework superior differs depending on your requirements.
To me, Mate's most appealing feature is how well it separates the different tiers of your application. After becoming familiar with it, I could never go back to using a framework that makes extensive use of global-state "Singletons" (Cairngorm, PureMVC).
However, Mate can probably be a bit difficult getting started with as the documentation is still a bit lacking and outdated, making it hard to know where to find the newest information. Some of the best practices and approaches that have been ironed out are to be found in the Mate forums, requiring some digging through posts. One of the most active users on that forum, Theo, has written a very good summary on the benefits of Mate in the following post:
Flex MVC Frameworks
PureMVC.... I like to have control and not relying on data binding... also since its been ported in different languages it has more value in my book than just a Flex only framework. Overall any MVC architecture is a plus in my book and it comes down to personal coding style/preference.
Cairngorm, and when I can't use Cairngorm (say, when using Flash CS3), I will simulate it (and it is really easy to duplicate conceptually). It is easy to set up, stupid simple, lightweight, and fast. If done correctly, it also forces a VERY clear separation of form and content. It fits in brilliantly with the native Flex classes and exploints data binding to the fullest. Of course, this might have something to do with the fact that it is the standard which Adobe explicitly endorses. Further, it is by far the most popular, which means if you need other people to be brought in and work on your projects, it will be far easier to find people who know Cairngorm than people who know the alternatives.
I find PureMVC incredibly bloated, non-ActionScript intuitive, and generally useless unless you work in a 99% Java company that does a very small amount of work with Flex and you want to have both use the same system.
I don't know anything about the rest.
Besides stackoverflow, what are the best sites to showcase my development skills?
For those sites that are specific to a particular set of skills, I am a ASP.Net developer and I use c# primarily.
Edit:
Something to send potential employers, and something that they would find easily during a Google search of me.
If you have a blog, that would be an awesome resource for your future employers to know more about you and your work.
Also, if you're looking for a job, there are many cool sites where you can show not only your coding skills (TopCoder, GitHub) but also what you think (Twitter), and maybe what your teammates think about you (LinkedIn).
Again, with a blog you could keep all this links together in one place.
SourceForge
Codeproject
Codeplex
There are many others as well.
A web page, of course. get a github account. Pick up silverlight and make a cool game perhaps?
Perhaps you may publish some of your projects in www.codeproject.com. If you have chosen a right project I think it can show your talent
Next time you take on a project that you don't mind being public, document your way through the project on a blog. It would give employers a chance to see your work patterns.
Also, win a couple TopCoder competitions. That might help
http://www.planetsourcecode.com used to be great but when I looked at it just now it seems like it has gone to the dogs.
http://www.codeproject.com is pretty poorly organised (in terms of site design) but if you want to draw attention to yourself it's pretty easy to find topics on there which aren't covered and could use a tutorial/example.
Consider contributing to existing established open-source projects on sites like SourceForge and CodePlex rather than starting your own. One which comes to mind that I looked at recently is http://anmar.eu.org/projects/sharpwebmail/ - it's a great project but sorely in need of a visual overhaul, which means more than just some updated JPEGs. Oxite was falling behind its roadmap targets from memory if you want another example of a good project to contribute to.
what about publishing a good nice opensource 'product' at google code, freshmeat or sourceforge?