Jump to content

ignace

Moderators
  • Posts

    6,457
  • Joined

  • Last visited

  • Days Won

    26

Everything posted by ignace

  1. Then how do you pay your employees? Or your aircrafts?
  2. ZF requires minimum 5.2.4. And like premiso said use either CodeIgniter or CakePHP, if you however have a good working knowledge on OO patterns and principles I would advice to use ZF and switch hosts (or upgrade).
  3. $hmm1->player-command should be: $hmm1->player->command
  4. echo date('i', $seconds), ' Minutes';
  5. <ha:group gid="66666">Hello, you are part of group 66666<ha:else>you are NOT part of group 66666</ha:else></ha:group> <xsl:choose> <xsl:when test="$group = 66666"> <xsl:value-of select="group"/> </xsl:when> <xsl:otherwise> <xsl:value-of select="group/else"/> </xsl:otherwise> </xsl:choose>
  6. I have been attending gigs for a long while, have played guitar for longer than you have been alive and am fairly versed in production techniques after playing in bands and producing music for more than 15 years. These guys can't hold a note, it really is that simple. Ive seen better performances at my local pup. How's your band called? Or what are the names of some of your albums?
  7. SELECT .. FROM surveys_users_answers JOIN surveys_users USING user_id WHERE question_label = '$qlabel' AND answer_label = '$alabel' For multiple correct answers: SELECT .. FROM surveys_users_answers JOIN surveys_users USING user_id WHERE question_label = '$qlabel' AND answer_label IN ('$alabel', ..)
  8. I don't think SE use a traditional DB like MySQL maybe something like NoSQL?
  9. 1. I doubt you'll generate a HUGE profit, I hope you'll have something left after you paid all your expenses. 2. We don't have to help you, this forum is on a voluntary basis. If you want help-on-demand, pay someone.
  10. Use the a-flag to append lines. $file = fopen('file.txt', 'a+'); fwrite($file, 'hello'); fwrite($file, ' world'); echo fread($file);// hello world fclose($file);
  11. $root = $dom->createElement('countries'); foreach ($countries as $countryCode => $fullName) { $country = $dom->createElement('country', $fullName); $country->setAttribute('code', $countryCode); $root->addElement($country); } Generates: <countries> <country code="AF">Afghanistan</country> <country code="AX">Aland Islands</country> .. </countries>
  12. If you have been to some live concerts you'll have noticed that most - if not all - can't hold a note and if they do they are play-backing. On a side note, I like the song. Already downloaded it to my iTunes, €0.99 is about what it's worth to me. All music teachers complain about the current quality the music industry delivers. But to producers et cetera it makes good money and quality became optional.
  13. It seems like you will need to adjust the code to make it work with the database.
  14. You may want to take a look at ACL where each page is a resource, the user is part of a group/role.
  15. What do you think? Where do you define $db - if anywhere?
  16. PHP is server-side. You will need AJAX to pull that one off.
  17. surveys (survey_id, survey_name, survey_description) surveys_questions (question_id, survey_id, type_id, correct_answer_id, question_label) surveys_questions_types (type_id, ..) surveys_answers (answer_id, question_id, answer_label, order) surveys_users_answers (user_id, question_label, answer_label) surveys_users_groups (group_id, group_name) surveys_users (user_id, user_name, user_password, ..) I think this should do it for you. Questions and answers can probably be edited so therefor I decided to store the question_label and the answer_label when a user answers a question. Your programming logic should know what kind of type the question was and handle it properly (ie multiple-choice stores question_label for each chosen answer)
  18. Are you sure you have InnoDB as the engine or MyISAM for your tables?
  19. Nothing wrong with that approach. Everyone has different ways of learning. I don't think one size fits all. I must disagree about traditional college though. I find programmers who learned on their own have a much deeper knowledge than kids that just graduated. Just my opinion though. - Stede College's skims over industry technologies so you have a basic working knowledge of how it operates, it knows that it can't teach you the expertise you gain through industry work. That said though, I never understood as why they never explained their decisions: When I got DB design they told me to ALWAYS use an ID, they never told me that ID was a surrogate key or what a natural key was and why I should not use it? We didn't ask as we didn't knew what to ask for? They also went over the different normal forms as defined by Codd in a single lesson, to be applied nowhere... Everyone's DB design was always fine, a few books later taught me that those DB designs were not fine and actually never even reached NF3 and contained UPDATE-anomalies. Or when you approached them with a more advanced topic (OOA&D) they told you to wait a few more semesters as it's covert somewhere in the course, and when they do decide to give you some introduction you can poke holes in their explanation. Or why allow anyone who has a very limited working knowledge on a certain subject, teach this subject? All kinds of question marks popped up above my head when the teacher wrote position: right; and when I pointed out the typo, I was told that what was on the projected image was correct?? I had to involve W3C to prove my point. On the final exam we were told that we could not edit any of the given code, that is all fine by me if it weren't that it contained some typo's. I think it would be better if teachers communicated their decisions more. PHP was taught using the global keyword as a standard... I scratch my head and wonder why? All rant, don't bother reading.. posted it because I didn't wanted to delete it all because it had IMO some good points.
  20. There can be many surveys: surveys (survey_id, ..) Each survey can have many questions: surveys_questions (question_id, survey_id, type_id, ..) Each question is of a certain type (multiple choice, single choice, open, ..). Each question can have many possible answers: surveys_answers (answer_id, question_id, ..) The user answers questions: users_surveys (user_id, question_id, answer_id) It's difficult to create a DB scheme without knowing the entire project background.
  21. 1. Post your entire code 2. You performed a JOIN, if the second table contains many records for your one user record then the data is duplicated 3. Chances are it also is duplicated for your friends, your account only shows duplicates because it probably only contains links to your friends while your friends only link to you once.
  22. Everyone thinks of the MVC as a complicated pattern while it isn't. For example, on most websites you would create a request like http://www.domain.com/about-us.php But in an entire OO application you want to map that request to an object (Controller). The FrontController does the actual mapping and the Controller makes sure that the request returns in a response (View) and that the communication (client & server) has some means to be stored (Model). It took some time before I really understood MVC.
  23. How do you mean visual? InnoDB does this automatically when a parent reference has been updated or deleted in which - in the case of CASCADE - updates all child's or deletes all child's.
  24. quizzes_results (user_id, quiz_id, question_id, answer_id) -- where answer_id is the chosen answer
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.