Jump to content

computermax2328

Members
  • Posts

    281
  • Joined

  • Last visited

Everything posted by computermax2328

  1. What you could do instead of adding a new column or a new table is have a column called "account type" or "account" for short. Make the data for each user either a 1 or a 2. If a user is a 1 they are a regular user, if a user is a 2 they are a premium user. That way you can just update their information when they become premium.
  2. I had to do an UPDATE not an insert. I ended up with UPDATE and INNER JOIN. Thanks anyway,
  3. Hey Guys, I am having a hard time figuring out this mysql query. So I have two tables like this. schools ---------------------------- school | town | county | full years ---------------------------- dis | location I need to insert `full` into `locations` where `school` equals `district`. Make sense? Hints would be preferred rather than answers.
  4. Well I mean a good backend interface is what I am looking for. Any other suggestions for a better backend interface? Usability, simplicity and mobility are a plus!
  5. $query = "SELECT * FROM `comic_db`.`comic_db` WHERE `comic_name`='$data'"; Take out the first comic_db and the period.
  6. That is what I thought. Would I have to use the WordPress php code or can I just use my own queries? Is this a best practice? If not what is?
  7. I think that I am having a hard time understanding the folder structure of a WordPress template. For example, I have your website home page that I would like to look different then my posts or inside pages. The content is different as well as the look and style. Maybe I am researching for the wrong word or phrase? Like a multi-layout theme. Sorry if I am conveying this poorly. I am doing multiple things at once right now.
  8. In the past I have messed around with WordPress templates and their CSS modifications. I started to dabble in template creation and I was wondering if I could use WordPress strictly for content creation and management? Instead of creating a template with header.php and sidebar.php and all that crap, can I just query the WordPress database? Mainly, I just don't want to have to upload a template. Any articles on this if possible? I Googled around in my spare time, but no in depth research. Thanks
  9. What are all of these h4s and the one h1 wrapped in? It looks like they have an element around them. That needs to be relative or have no margin.
  10. To find a solution we would have to see the CSS. Immediately, just by looking at the thumbnail it obviously seems to be a margin or padding problem. You can also set the div that all of these headers are in to position: relative. That could help.
  11. I always just name the file like this. Can't manipulate that.
  12. You need to clean up your code. First off, when you echo everything inside the echo is in double quotes and all of the quotes inside of the double quote are single quotes. Does that make sense? So like this. echo "<div class='content-cotainer1'>" Second you need to close your quote in your else statement. You have echo ' but you never close it. I think you want to close it here. <div class="updateerrorcell"> Then you open another PHP statement here. <?php if($success["success"]) print "<div class="valid">" . $success["success"] . "</div>"; ?> get rid of the <?php in front of the if. There is not need for it. If you can't get it to work, let me know and I will help you.
  13. You added a second mysql_query in there. Do this... $sqlinsert = "INSERT INTO reviews (`SHOWTITLE`, `SHOWREVIEW`) VALUES('$showtitle', '$showreview')"; $query = mysql_query($sqlinsert); if (!query) { echo "error inserting new record" . mysql_error(); }
  14. Well while I look at it again, did you close this if statement like I told you to before?? if (!mysql_query($sqlinsert)) { die('error inserting new record'); } You need that closing bracket on this one
  15. Are you still getting the index error? The index error means that there is nothing in the query to insert.
  16. You are missing the point. It doesnt have to do with the code right now. The form that you are submitting the information from either doesn't have any information in it or it is the wrong form. Put information in the form and hit submit.
  17. Ooo lol! It means that those two values don't have anything in them, so it can't insert anything. Put something in the input.
  18. Ok, I can help explain this to you. So you have a query variable $sqlinsert, which is good. You if not statement is wrong though. It should something like this. $sqlinsert = "INSERT INTO reviews (`SHOWTITLE`, `SHOWREVIEW`) VALUES('$showtitle', '$showreview')"; $query = mysql_query($sqlinsert); if (!query) { echo "error inserting new record" . mysql_error(); } I also added some backticks `` to your query for your column names. If there are any errors in your query now it will tell you.
  19. You actually have to query the database... $query = mysql_query($sqlinsert, $dbConn); if (!$query) { die('error inserting new record'); } ALSO, close your if bracket. You close your if isset, but not your if not query.
  20. The mysql_query() function goes mysql_query($string, $connection). It seems you have it backwards.
  21. You need to name a column in your query... mysql_query("INSERT INTO appointments(column1, column2) VALUES ('', '$adate')"); I am not sure why you have an empty value that you are inserting into your database. I would drop that and column2 if they are unnecessary. Reference is below. http://stackoverflow.com/questions/15011108/php-foreach-loop-inserting-into-database
×
×
  • 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.