hotwebmatter
  • Member for 5 years, 4 months
  • Last seen this week
1 answers
3 votes
2k views
can't get the site to run
Accepted answer
23 votes

CS50 course materials will tell you that the permissions need to be set as follows: chmod 711 for directories chmod 644 for images, HTML, CSS, JavaScript chmod 600 for PHP files. In general, this is ...

View answer
2 answers
2 votes
596 views
Problem Set 8 Permissions
Accepted answer
6 votes

According to this post on the CS50 Reddit, the permissions have changed since a recent update50, and the documentation has not been updated to reflect the changes. In my experience, you'll need a ...

View answer
1 answers
2 votes
212 views
Memory leak in Pset4
Accepted answer
5 votes

Actually, your apparent problem is that you are running valgrind against a different executable binary, also called resize. ~/workspace/ $ which resize /usr/bin/resize ~/workspace/ $ whatis resize ...

View answer
1 answers
1 votes
122 views
PSET 6 Keeps Stopping Server
Accepted answer
5 votes

The Stopping server message comes from the stop() function defined here: /** * Stop server, deallocating any resources. */ void stop(void) { // preserve errno across this function's library ...

View answer
1 answers
1 votes
150 views
PSET7: web server permissions problem
Accepted answer
4 votes

403 Forbidden / permissions / chmod: the Definitive Guide TL;DR: PHP files and config.json need to be set to chmod 640 despite what it says in the Problem Specification. Hope this helps!

View answer
3 answers
8 votes
574 views
pset7 error 403, forbidden, (even after going over the instructions over and over)
4 votes

Permissions have changed due to a recent update, but the problem specification has not been edited to reflect this. PHP files and config.json now need to be set chmod 640, even though the problem ...

View answer
1 answers
2 votes
711 views
pset8 can't access ide50-username.cs50.io
Accepted answer
4 votes

UPDATE: I have verified that chmod 640 is still required for PHP files, even with version 62 of ide50. The quickest way to get all of the PHP files set from 600 to 640 is to execute the following ...

View answer
2 answers
2 votes
701 views
Pset4 recover, comparing hex in if statements
Accepted answer
3 votes

@Blauelf is correct: you can't count on char to be an unsigned 8-bit int. However, you can use a typedef to make certain that a BYTE is really a byte. Look at these type definitions, borrowed from ...

View answer
1 answers
1 votes
220 views
PSET7-quote.php Not doing displaying quote
Accepted answer
3 votes

You definitely don't need to do this: redirect("/../views/quote_template.php"); ... after you have used the render() function. EDIT: For quote.php, you should be doing something like this (in ...

View answer
1 answers
1 votes
492 views
phpMyAdmin: "mysql extension missing" error
3 votes

We all know that phpMyAdmin can be flaky sometimes. Unfortunately, I can't tell you how to fix it -- but I can tell you how to use mysql50 shell from the command line. Try stuff like this: mysql50 ...

View answer
2 answers
1 votes
621 views
Pset8 search.php permission issues, warnings & fatal error - fail to open CS50.php
Accepted answer
3 votes

@Vitale: I feel your pain! Permission errors can be really frustrating. You are impatient to get back to work, and in your haste, you reach for chmod -R 777 *, the biggest sledgehammer in your toolkit....

View answer
2 answers
3 votes
2k views
Issues with the CS50 IDE
Accepted answer
3 votes

There is definitely a problem with permissions for apache50 in version 59 of ide50. Hopefully, the CS50 folks will fix this in the next version. Meanwhile, the apache50 log files are accessible at /...

View answer
2 answers
1 votes
99 views
Alternative to multiple if statements?
Accepted answer
2 votes

You can refactor your code to use only one if statement! Think about the number of MIME types you have to check for, and the number of matching file extensions. Since there are the same number of ...

View answer
2 answers
1 votes
273 views
PSET3 Game of Fifteen move() Problem
Accepted answer
2 votes

@M.Kleiven's tips are interesting, but I just looked at my solution, and I did not need to use pointers to check if a tile is outside the board. Here's what I did, in pseudo-code: // initialize board ...

View answer
1 answers
0 votes
157 views
How to stop server?
Accepted answer
2 votes

The error message: server: no process found should be self-explanatory. You're trying to kill a process that is not running. That's because the Apache2 server daemon process is not called server. ...

View answer
1 answers
1 votes
219 views
Is pset8 really very difficult
Accepted answer
2 votes

Congratulations on finishing Problem Set 7! :) Problem Set 8 is a lot to learn all at once, but don't quit. As with other Problem Sets, just break this one down into small steps and tackle each one ...

View answer
1 answers
1 votes
80 views
pset4 peek error
Accepted answer
2 votes

You're about to learn about something called endian-ness. Hope this helps!

View answer
1 answers
1 votes
226 views
pset7 register.php help
2 votes

1) What's the return type of $rows ? Is it an array or just an int ? Because SELECT LAST_INSERT_ID() will return the last inserted ID , which is going to be a number(int) rather than an array? $...

View answer
1 answers
1 votes
236 views
Pset8 map not showing
2 votes

Please check the permissions on the js directory and its contents: ls -l ~/workspace/pset8/public ls -l ~/workspace/pset8/public/js All of your JavaScript files should have these permissions: -rw-r--...

View answer
1 answers
2 votes
419 views
Hosting a site made for CS50 - final project
Accepted answer
2 votes

Broadly speaking, there are only two things you need to purchase in order to do this: Register a domain name from any reputable registrar (should be around $10 per year) Rent some kind of hosting. Be ...

View answer
3 answers
0 votes
159 views
pset7CS50 Fnance
2 votes

Zombie Question. In general, the best way to troubleshoot the "Table doesn't exist" error is to open a new Terminal tab in the CS50 IDE and execute the following commands: mysql50 shell SHOW ...

View answer
2 answers
0 votes
40 views
Matematical knowledge
Accepted answer
2 votes

To answer your direct question: No. It is not necessary to understand the RSA encryption algorithm in order to solve the Problem Set. In fact, you can make it through the entire class without needing ...

View answer
1 answers
2 votes
836 views
pset8: infowindow and $.getJSON difficulties
Accepted answer
2 votes

You are on the right track! For example, you are definitely not putting the $.getJSON statement in the right place. But that's easy to fix. Your real problem is with variable scope. One of the most ...

View answer
2 answers
1 votes
43 views
Website won't change from finance to map
Accepted answer
2 votes

If apache50 stop is not stopping the Apache2 server process, you may have a "zombie process." Luckily, it can be killed! Try executing: sudo killall -9 apache2 to terminate the process with extreme ...

View answer
3 answers
0 votes
145 views
Week 4, Section : Dynamic Memory Allocation
Accepted answer
2 votes

In addition to the points made by @MARS and @NullityNull, there are advantages and disadvantages to both methods. Allocating memory on the stack is more convenient because it automatically cleans up ...

View answer
5 answers
1 votes
685 views
Cannot get started on pset7
2 votes

Do not use chmod 777 *. That will probably help you to get your site to load, but it is bad for security, and a terrible habit to get into. It's like taking the front door of your house off of its ...

View answer
1 answers
1 votes
50 views
PSET5 : Question about structs
Accepted answer
2 votes

When you declare node* you are not declaring a variable of type struct node. Rather, you are declaring a pointer-to-node. A pointer is just a memory address. This is why, when you check the sizeof() ...

View answer
2 answers
1 votes
3k views
pset8: phpMyAdmin - Error The mysqli extension is missing - can't get more frustrated than this
Accepted answer
2 votes

We all know that phpMyAdmin can be flaky sometimes. Unfortunately, I can't tell you how to fix it -- but I can tell you how to use mysql50 shell from the command line. Try stuff like this: mysql50 ...

View answer
2 answers
1 votes
411 views
Syntax highlighting in CS50 IDE
2 votes

Don't worry -- nothing bad will happen if you rename the file. The point of naming it import rather than import.php is just to show you that this isn't a regular PHP web app file to be executed by the ...

View answer
4 answers
3 votes
2k views
Not able to access (403 Forbidden) own website: https://ide50-username.cs50.io/ (with my username)
2 votes

TL; DR: If you are having permission issues on pset7, you can fix them with the following three commands: find ~/workspace/pset7/ -type d |xargs chmod 755 find ~/workspace/pset7/ -name *.php |xargs ...

View answer
1
2 3 4 5 6